patch https://api.splio.com/loyalty/v1/rewards/
Edit the data of an existing reward. All new granted rewards will inherit of the updated data.
Error cases
Reward external_id does not exist (404)
{
"status": 404,
"errors": [
{
"error_key": "id",
"error": "wrong_value",
"error_description": "Record not found for id my_test_reward."
}
]
}
Malformatted value - ex: boolean as string (400)
Generic error for all fields and custom fields values types
{
"status": 400,
"errors": [
{
"error_key": "name",
"error": "wrong_type",
"error_description": "This value should be of type string."
}
]
}
{
"error_key": "",
"error": "wrong_field_type",
"error_description": "something went wrong"
}
Edit non-existing or non-editable field (400)
Wording will mention field does not exist for the PATCH method
{
"status": 400,
"errors": [
{
"error_key": "external_id",
"error": "unknown_field",
"error_description": "The field \"external_id\" does not exist."
}
]
}