Skip to main content
PUT
/
v1
/
customers
/
{identifier}
Update a customer
curl --request PUT \
  --url https://api.mageloyalty.com/v1/customers/{identifier} \
  --header 'Authorization: <api-key>'
Update editable fields on a customer. The identifier can be a Shopify customer ID or email. Supports both JSON:API and flat request body formats.

Request body

FieldTypeDescription
date_of_birthstring | nullISO 8601 date. Pass null to clear.
is_excludedbooleanWhether the customer is excluded from the loyalty program
anniversary_datestring | nullISO 8601 date. Pass null to clear.
JSON:API format:
{
  "data": {
    "attributes": {
      "date_of_birth": "1990-05-15T00:00:00.000Z",
      "is_excluded": false,
      "anniversary_date": "2023-03-10T09:00:00.000Z"
    }
  }
}
Flat format:
{
  "date_of_birth": "1990-05-15T00:00:00.000Z",
  "is_excluded": false,
  "anniversary_date": "2023-03-10T09:00:00.000Z"
}

Response

Returns the updated customer object.

Errors

StatusScenario
400Invalid request body
404Customer not found