Skip to main content
PATCH
/
merchant
/
customer
/
edit
{
  "success": false,
  "error": {
    "status": 404,
    "code": "CUSTOMER_NOT_FOUND",
    "message": "Customer not found"
  },
  "data": null
}
Edit customer information.
customerId
string
required
Customer ID to edit
email
string
Updated email address
metadata
object
Updated customer metadata
success
boolean
Indicates if the request was successful
data
object
Updated customer data

Example Request

curl -X PATCH https://api.transaction.gg/merchant/customer/edit \
  -H "Authorization: Bearer jwt_token" \
  -H "Content-Type: application/json" \
  -d '{
    "customerId": "cus_V6n6SN2KnsIFCuQU",
    "email": "[email protected]",
    "metadata": {
      "name": "Jane Doe"
    }
  }'

Example Response

{
  "success": true,
  "data": {
    "id": "cus_V6n6SN2KnsIFCuQU",
    "email": "[email protected]",
    "metadata": {
      "name": "Jane Doe"
    },
    "updatedAt": "2024-01-01T00:00:00Z"
  }
}

Error Responses

{
  "success": false,
  "error": {
    "status": 404,
    "code": "CUSTOMER_NOT_FOUND",
    "message": "Customer not found"
  },
  "data": null
}