Customers

Create a customer

<a href="https://www.checkout.com/docs/payments/store-and-manage-credentials" target="_blank">Store a customer's details in a customer object to reuse in future payments</a>. When creating a customer, you can link payment instruments – the customer id returned can be passed as a source when making a payment. <br/><br> NOTE: Specify a default instrument, otherwise the instruments array will not be saved on creation.

post/customers

Request

Request body

emailstring email required

The customer's email address

namestring

The customer's name

metadataobject

Allows you to store additional information about a customer. You can include a maximum of 20 key-value pairs. Each key and value can be up to 100 characters long.

defaultstring

The ID of the instrument you want to set as this customer's default instrument

Example request

{
  "email": "brucewayne@gmail.com",
  "name": "Bruce Wayne",
  "phone": {
    "country_code": "+1",
    "number": "415 555 2671"
  },
  "metadata": {
    "coupon_code": "NY2018",
    "partner_id": 123989
  },
  "default": "src_wmlfc3zyhqzehihu7giusaaawu"
}

Response

Customer created successfully

idstring required

The customer's unique identifier

Example response

{
  "id": "cus_y3oqhf46pyzuxjbcn2giaqnb44"
}

Changes

No recorded changes to this operation across all 1 revision of this API.