Delete product field options
delete/api/v1/products/fields/{fieldId}/optionsDeletes one or more options from the specified field in the product module.
Code snippet
curl -X 'DELETE' \
'https://{yourdomain}/api/v1/products/fields/{fieldId}/options' \
-H 'accept: text/plain; x-api-version=1.0' \
-H 'x-api-key: {your API key}' \
-H 'Content-Type: application/json-patch+json; x-api-version=1.0' \
-d '{
"data": {
"optionIds": [101, 102, 103]
}
}'
Path parameters
| fieldIdintegerRequired | The unique identifier of the field from which the specified options will be deleted. |
Request body
| optionIdsarrayRequired | A list of unique identifiers representing the field options to be deleted. Each value in the array corresponds to an existing option ID associated with the field. |
Example response
200 OK
{
"message": "Field option(s) deleted successfully."
}