REST API
You can use REST API to create Avatar Images on any platform, Web, mobile, or server.
Sketch Image method
Creates a single static Avatar Image. Only preset pose can be used.
URL
POST https://api.render-it.m2s.team/services/sketch/image
Header parameters
Key | Description | Example |
---|---|---|
authorization | Enter the API Key token created in Render-it Sketch. Bearer authentication is used. | Bearer {API_KEY_TOKEN} |
content-type | Specifies the format for HTTP Body. It only accepts application/json. | application/json |
Query parameters
Key | Description | Required | Default Value | ETC |
---|---|---|---|---|
quality | Code to determine Avatar Image quality. | Yes | Enum [SW160, SW240, SW320, SW480, SW640, SW960, SW1280, SW1600, SW1920, SW2560, SW3200, SW3840] | |
redirect | If true, redirects to the created Avatar Image URL. If false, returns the Avatar Image URL. | No | true |
Body parameters
Key | Description | Limitations |
---|---|---|
pose | Preset pose ID to use for creating Avatar Image | |
targets[i].avatar | Preset Avatar ID to be used when creating Avatar Image | Minimum of 1, maximum of 8 |
targets[i].override | Minimum of 1, maximum of 8 | |
targets[i].override.properties[j].value | Unique code of the item to be applied to the avatar image. Only items in the user's preset list are available. | |
targets[i].override.properties[j].name | Defines which items to customize for the avatar image | Item categorization list |
Example
curl -i -X POST \
-H "Authorization:Bearer {API_KEY_TOKEN}" \
-H "Content-Type:application/json" \
-d \
'{
"pose": "PO_2",
"targets": [
{
"avatar": "AVT_M_1",
"override": {
"properties": [
{
"value": "HRM_1",
"name": "Hair"
},
{
"value": "TOPS_1",
"name": "ClothesTop"
}
]
}
}
]
}' \
'https://api.render-it.m2s.team/services/sketch/image?quality=SW640'
Item categorization list
- Dress:
"ClothesDress"
- Top:
"ClothesTop"
- Outer:
"ClothesTop"
- Bottom:
"ClothesBottom"
- Socks:
"ClothesSocks"
- Shoes:
"ClothesShoes"
- Hair:
"Hair"
- Headwear (accessory, cap):
"AccessoryHeadwear"
- Headwear (hair extension):
"HairExtensions"
- Accessory (nail art):
"ClothesGlove"
- Accessory (watch, bracelet):
"AccessoryBracelet"
- Accessory (bag):
"AccessoryBag"
- Accessory (mask):
"AccessoryMask"
- Accessory (wing):
"AccessoryWing"
- Accessory (glasses, sunglasses):
"ClothesGlasses"
- Accessory (necklace):
"AccessoryNecklace"
- Accessory (earring, piercing):
"AccessoryEarring"
- Accessory (anklet):
"ClothesSocks"
Errors
When creating Avatar Image, errors may occur in various situations. The user may have entered incorrect data, or it may be an ZEPETO Render-it service failure. Please refer to the table below for simple information and solutions.
Error code | Description | Solution |
---|---|---|
400 | Contains unavailable parameters | Please check if the HTTP request does not deviate from the specifications defined in the document. |
401 | Not a valid API Key Token | Please check if there is a typo in the API Key Token and whether the values match. |
403 | Blocked by Referrer | Please check if you are blocked due to Security Group. |
404 | Not a valid item value | Please check if the entered avatar , pose or item value are correct. |
408 | Failures due to network outages or delays | Please contact support team. |
415 | Invalid Content-Type header | Please check if the Content-Type of the Request header is application/json. |
429 | Exceeded allowed TPS | Please check if your TPS is over. If you need to increase the TPS further, please contact our support team. |
500 | ZEPETO Render-it service failure | Please contact support team. |