KashierDevelopersKashier Developers

Update a customer

curl -X PUT "https://test-api.kashier.io/v2/customers/string" \  -H "Content-Type: application/json" \  -d '{    "name": "John Doe",    "phoneNumber": "1123456789",    "emailAddress": "[email protected]",    "customFields": [      {        "name": "custom-key-1",        "value": "custom-value-1"      }    ],    "preferredCommunicationChannel": "sms"  }'
{  "body": {    "message": "Customer updated successfully",    "body": {      "_id": "67ba05fd87c9970012389429",      "name": "John Doe",      "phoneNumber": "1123456789",      "emailAddress": "[email protected]",      "customerId": "C-XXXXXXXXXXXXX",      "merchantId": "MID-XXXXX-XXX",      "customFields": [        {          "name": "custom-key-1",          "value": "custom-value-1"        }      ],      "createdAt": "2025-02-22 17:14:37.203000+00:00",      "updatedAt": "2025-02-26 09:55:34.630000+00:00"    }  },  "message": "success"}

Updates a customer profile. Send the fields you want the customer to end up with — customFields replaces the existing array rather than merging into it.

Authorization

secretKey
Authorization<token>

Merchant secret key used to identify the merchant, obtained from Kashier's dashboard. Pass the raw secret key value in the Authorization header (NOT a "Bearer" token).

In: header

Path Parameters

id*string

The customer's record id.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

PUT
/v2/customers/{id}