Create qr code
Body
Required
-
text
string Required The text that will be encoded in the QR code
-
size
integer the output pixel of the image generated
Minimum value is
50
, maximum value is2000
. Default value is300
. -
file_type
string Required The output file format of the generated QR code. Accepted values svg or png.
Values are
svg
orpng
. -
eye_frame_1
object The style of the top-left eye frame of the generated QR code. please refer to our documentation for available style options
-
eye_frame_2
object The style of the top-right eye frame of the generated QR code. please refer to our documentation for available style options
-
eye_frame_3
object The style of the bottom-left eye frame of the generated QR code. please refer to our documentation for available style options
-
eye_ball_1
object The style of the top-left eye ball of the generated QR code. please refer to our documentation for available style options
-
eye_ball_2
object The style of the top-right eye ball of the generated QR code. please refer to our documentation for available style options
-
eye_ball_3
object The style of the bottom-left eye ball of the generated QR code. please refer to our documentation for available style options
-
body
object The style of the body
-
image
object defines the image to be placed
-
background
object sets the background of the QR code
curl \
-X POST http://petstore.swagger.io/v2/qr-code \
-H "Content-Type: application/json" \
-d '{"text":"https://www.example.com","size":300,"file_type":"svg","eye_frame_1":{"style":"1","rotate":0,"color":"#000000"},"eye_frame_2":{"style":"1","rotate":0,"color":"#000000"},"eye_frame_3":{"style":"1","rotate":0,"color":"#000000"},"eye_ball_1":{"style":"1","rotate":0,"color":"#000000"},"eye_ball_2":{"style":"1","rotate":0,"color":"#000000"},"eye_ball_3":{"style":"1","rotate":0,"color":"#000000"},"body":{"style":"1","color":"#000000","gradient":{"gradient_type":"linear","gradient_on_eyes":false,"linear_direction":{"x1":0.0,"y1":0.0,"x2":42.0,"y2":42.0},"gradient_colors":["no default"]}},"image":{"image_id":"tobdd6to4450d5f18b00.png","image_size":0.3,"image_mode":"clean"},"background":{"color":"#ffffff"}}'
{
"text": "https://www.example.com",
"size": 300,
"file_type": "svg",
"eye_frame_1": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_frame_2": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_frame_3": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_ball_1": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_ball_2": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_ball_3": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"body": {
"style": "1",
"color": "#000000",
"gradient": {
"gradient_type": "linear",
"gradient_on_eyes": false,
"linear_direction": {
"x1": 0.0,
"y1": 0.0,
"x2": 42.0,
"y2": 42.0
},
"gradient_colors": [
"no default"
]
}
},
"image": {
"image_id": "tobdd6to4450d5f18b00.png",
"image_size": 0.3,
"image_mode": "clean"
},
"background": {
"color": "#ffffff"
}
}
{
"text": "https://www.example.com",
"size": 300,
"file_type": "svg",
"eye_frame_1": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_frame_2": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_frame_3": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_ball_1": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_ball_2": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"eye_ball_3": {
"style": "1",
"rotate": 0,
"color": "#000000"
},
"body": {
"style": "1",
"color": "#000000",
"gradient": {
"gradient_type": "linear",
"gradient_on_eyes": false,
"linear_direction": {
"x1": 0.0,
"y1": 0.0,
"x2": 42.0,
"y2": 42.0
},
"gradient_colors": [
"no default"
]
}
},
"image": {
"image_id": "tobdd6to4450d5f18b00.png",
"image_size": 0.3,
"image_mode": "clean"
},
"background": {
"color": "#ffffff"
}
}