Vatly
Api Reference

Customers

On this page, we'll dive into the different customer endpoints you can use to manage your Vatly customers programmatically.

The Customer API Resource

Below you'll find all properties for the Vatly Customer API resource.

Properties

NameTypeDescription
idstringUnique identifier for the customer (starts with cus_).
resourcestringThe resource type. Always customer.
testmodebooleanWhether this resource is in test mode.
emailstringThe email address for the customer.
createdAtstringWhen this customer was created (ISO 8601 format).
metadataobject | nullArbitrary key-value metadata for your application. Up to 50 keys, with key names up to 40 characters and values up to 500 characters.
linksobjectHATEOAS links to related resources. Contains self link.

List all customers

GET /v1/customers

This endpoint allows you to retrieve a paginated list of all your customers. By default, a maximum of ten customers are shown per page.

Optional attributes

NameTypeDescription
limitintegerThe number of customers to return (default: 10, max: 100).
startingAfterstringA cursor for use in pagination. Returns results after this customer ID.
endingBeforestringA cursor for use in pagination. Returns results before this customer ID.
curl -G https://api.vatly.com/v1/customers \
  -H "Authorization: Bearer live_your_api_key_here" \
  -d limit=10

Create a customer

POST /v1/customers

This endpoint allows you to add a new customer to Vatly. To add a customer, you must provide their email address.

Required attributes

NameTypeDescription
emailstringThe email address for the customer.

Optional attributes

NameTypeDescription
metadataobjectArbitrary key-value metadata for your application.
curl https://api.vatly.com/v1/customers \
  -H "Authorization: Bearer live_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"email": "john@example.com"}'

Retrieve a customer

GET /v1/customers/:id

This endpoint allows you to retrieve a customer by providing their Vatly id. Refer to the list at the top of this page to see which properties are included with customer objects.

curl https://api.vatly.com/v1/customers/cus_abc123def456 \
  -H "Authorization: Bearer live_your_api_key_here"
Copyright © 2026