Replace a variation axis
PUT/v2/experiences/{experienceId}/retail-attributes/{attributeId}
Requires your API key in the X-API-Key header.
Replaces the axis's name, sort order and values. Same rules as the PATCH operation.
curl -X PUT "https://api.turneo.co/v2/experiences/8e7d6c5b-4a39-4281-90ef-1a2b3c4d5e6f/retail-attributes/2b3c4d5e-6f7a-4b8c-9d0e-1f2a3b4c5d6e" \
-H "X-API-Key: <your-api-key>" \
-H "Content-Type: application/json" \
-d '{
"name": "Sunset Kayak Tour",
"sortOrder": 0,
"values": [
{
"id": "9a8b7c6d-5e4f-4a3b-8c1d-0e9f8a7b6c5d",
"label": "Sunset Kayak Tour",
"sortOrder": 0
}
]
}'Path parameters
experienceIdstring (uuid)requiredUUID of the retail product.
- Example:
8e7d6c5b-4a39-4281-90ef-1a2b3c4d5e6f
attributeIdstring (uuid)requiredUUID of the variation axis.
- Example:
2b3c4d5e-6f7a-4b8c-9d0e-1f2a3b4c5d6e
Request bodyapplication/json, required
namestring or map of stringMultilingual text field. Stored as an object keyed by language code (
en,de,it,es,fr,hr,sl,pt,zh,zh-hant,ja,ko,ru; machine translations are stored under<lang>_autokeys internally). On read it is returned as a single string resolved for the requestedlanguage(falling back to English when the object is not consistently translated), or as the full per-language object whenshowTranslations=trueis passed. On write, either a plain string (stored as English) or a partial per-language object is accepted.Accepted shapes
Either string
Or map of string
sortOrderintegerPosition of the axis among the product's axes. Defaults to 0.
- Example:
0
valuesobject[]The axis's values.
Child fields
idstring (uuid)UUID of an existing value of this axis (or of one removed earlier, which brings it back). Omit to create a new value.
- Example:
9a8b7c6d-5e4f-4a3b-8c1d-0e9f8a7b6c5d
labelstring or map of stringMultilingual text field. Stored as an object keyed by language code (
en,de,it,es,fr,hr,sl,pt,zh,zh-hant,ja,ko,ru; machine translations are stored under<lang>_autokeys internally). On read it is returned as a single string resolved for the requestedlanguage(falling back to English when the object is not consistently translated), or as the full per-language object whenshowTranslations=trueis passed. On write, either a plain string (stored as English) or a partial per-language object is accepted.Accepted shapes
Either string
Or map of string
sortOrderintegerPosition of the value within the axis. Defaults to 0.
- Example:
0
Responses
200object
The updated axis.
idstring (uuid)Axis UUID.
- Example:
2b3c4d5e-6f7a-4b8c-9d0e-1f2a3b4c5d6e
namestring or map of stringMultilingual text field. Stored as an object keyed by language code (
en,de,it,es,fr,hr,sl,pt,zh,zh-hant,ja,ko,ru; machine translations are stored under<lang>_autokeys internally). On read it is returned as a single string resolved for the requestedlanguage(falling back to English when the object is not consistently translated), or as the full per-language object whenshowTranslations=trueis passed. On write, either a plain string (stored as English) or a partial per-language object is accepted.Accepted shapes
Either string
Or map of string
sortOrderintegerPosition of the axis among the product's axes.
- Example:
0
valuesobject[]The axis's values, in
sortOrder.Child fields
idstring (uuid)Value UUID. SKUs list the values they are made of in
attributeValueIds.- Example:
9a8b7c6d-5e4f-4a3b-8c1d-0e9f8a7b6c5d
labelstring or map of stringMultilingual text field. Stored as an object keyed by language code (
en,de,it,es,fr,hr,sl,pt,zh,zh-hant,ja,ko,ru; machine translations are stored under<lang>_autokeys internally). On read it is returned as a single string resolved for the requestedlanguage(falling back to English when the object is not consistently translated), or as the full per-language object whenshowTranslations=trueis passed. On write, either a plain string (stored as English) or a partial per-language object is accepted.Accepted shapes
Either string
Or map of string
sortOrderintegerPosition of the value within its axis.
- Example:
0
{
"id": "2b3c4d5e-6f7a-4b8c-9d0e-1f2a3b4c5d6e",
"name": "Sunset Kayak Tour",
"sortOrder": 0,
"values": [
{
"id": "9a8b7c6d-5e4f-4a3b-8c1d-0e9f8a7b6c5d",
"label": "Sunset Kayak Tour",
"sortOrder": 0
}
]
}Errors
- 400
Validation failed. Inspect
errors[].fieldanderrors[].code.- 401
Missing or invalid
X-API-Keyheader.- 403
The API key is valid but not allowed to perform this action on this resource.
- 404
The resource does not exist or belongs to another partner (existence is not leaked across partners).
Error body
typestringError class.
- Allowed values:
validation_errorclient_errorserver_error- Example:
validation_error
errorsobject[]Child fields
codestringMachine-readable error code.
- Example:
required
fieldstringnullableOffending field, or null/'general' for non-field errors.
- Example:
startTime
messagestringHuman-readable message.
- Example:
This field is required.
{
"type": "validation_error",
"errors": [
{
"code": "required",
"field": "startTime",
"message": "This field is required."
}
]
}