Light Mode
Create Option Template
POST
/products/options/templatesLast modified: 4 days ago
This endpoint allows you create a new option template.
Request
Query Params
with
enum<string>
optional
Use with=details
to fetch list of product option templates with details
object.
Allowed value:
details
Example:
details
Body Params application/json
No schema defined
Example
{
"name": "image url",
"display_type": "image",
"translations": {
"en": {
"name": "color"
},
"fr": {
"name": "couleur"
}
},
"details": [
{
"name": "profile pic",
"is_default": true,
"display_value": "fb.com",
"translations": {
"en": {
"name": "pic"
},
"fr": {
"name": "pic"
}
}
}
]
}
Request samples
Responses
Success(200)
With Details(200)
Validation(422)
Unauthorized(401)
HTTP Code: 200
Content Type : JSONapplication/json
Data Schema
No schema defined
Example
{
"status": 201,
"success": true,
"data": [
{
"id": 1473353380,
"name": "اللون",
"type": "radio",
"display_type": "color",
"translations": [
{
"id": 1473353380,
"name": "color",
"locale": "en"
},
{
"id": 566146469,
"name": "color",
"locale": "fr"
}
]
}
]
}
Last modified: 4 days ago