> This page is for version Preview (default).
> For other versions, use one of these documentation indexes:
> - Preview (default): https://docs.preview.paid.ai/preview/llms.txt
> - Current: https://docs.preview.paid.ai/current/llms.txt

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.preview.paid.ai/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.preview.paid.ai/_mcp/server.

# Create a customer

> Make your first calls to the Paid API: create a company you bill, find it by your own ID, and keep its details current.

In this quickstart you record a company you bill as a customer in Paid, in a sandbox organization, where nothing is ever charged. Every invoice, event and order in Paid belongs to a customer, so they are the first thing an integration sets up.

Litware runs an AI support agent and has just signed Northwind Traders. By the end, Litware will have:

1. Northwind Traders as a **customer**, named by Litware's own ID
2. a way to look it up, change its details, and page through every customer on the account

## Before you start

* [Set up your account](/get-started/set-up-your-account): a sandbox organization and an API key starting `paid_sk_test_`, exported as `PAID_API_KEY`.
* [Make your first request](/get-started/first-request): check that the key works.
* Have `curl` to hand. Paid's SDKs don't support `api.paid.ai/v1` yet, so the steps below call it over HTTP.

## 1. Create a customer

Customers are in the `customers=v1` beta: send `Paid-Beta: customers=v1` with each customer request.

[Create a customer](../../api-reference/customers/customers/create) for Northwind Traders with its billing details, which Paid shows on invoices and uses for tax. `externalId` is Litware's own ID for the company, from its CRM. Every write also sends an `Idempotency-Key`, so retrying it after a timeout can never create two customers. Save the request body from the **API** tab below as `northwind.json`, then send it:

```bash
curl https://api.paid.ai/v1/customers \
  -H "Authorization: Bearer $PAID_API_KEY" \
  -H "Paid-Version: 2026-11-01" \
  -H "Paid-Beta: customers=v1" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d @northwind.json
```

From here on, each step shows only the method, path and body. Send the same headers with each one.

#### API

**`POST /v1/customers`**

```json title="POST /v1/customers"
{
  "externalId": "northwind",
  "name": "Northwind Traders",
  "legalName": "Northwind Traders Ltd",
  "email": "billing@northwind.example",
  "currency": "usd",
  "address": {
    "line1": "1 Harbour Street",
    "city": "London",
    "postalCode": "E1 8AA",
    "country": "GB"
  },
  "taxIds": [{ "type": "gbVat", "value": "GB123456789" }]
}
```

**`Response`**

```json title="Response"
{
  "id": "cus_8HqL2xT",
  "object": "customer",
  "livemode": false,
  "externalId": "northwind",
  "name": "Northwind Traders",
  "legalName": "Northwind Traders Ltd",
  "email": "billing@northwind.example",
  "phone": null,
  "website": null,
  "address": {
    "line1": "1 Harbour Street",
    "line2": null,
    "city": "London",
    "state": null,
    "postalCode": "E1 8AA",
    "country": "GB"
  },
  "taxIds": [{ "type": "gbVat", "value": "GB123456789" }],
  "taxExemptStatus": "none",
  "currency": "usd",
  "status": "active",
  "churnedAt": null,
  "parent": null,
  "segments": [],
  "metadata": {},
  "createdAt": "2026-11-01T09:00:00Z",
  "updatedAt": "2026-11-01T09:00:00Z",
  "archivedAt": null
}
```

#### Dashboard

> **Draft**
>
> These steps describe the planned v1 dashboard and will change before release.

1. Go to **Operate > Customers** and click **Create customer**.
2. Enter the name **Northwind Traders**, the legal name **Northwind Traders Ltd**, and the external ID `northwind`.
3. Choose the currency **USD**, and enter the billing email, address and VAT number.
4. Click **Create customer**.

`livemode` is `false` because the customer is in a sandbox organization. Store the `cus_` ID where you can: it never changes. `externalId` is unique on your account, so creating a second customer with `northwind` returns `409` `resource_exists`.

## 2. Look a customer up

Anywhere the API asks for a customer, it takes Paid's `cus_` ID or your `externalId`, so a service that only knows Litware's CRM ID never needs to store Paid's. [Retrieve the customer](../../api-reference/customers/customers/retrieve) by its `externalId`:

```bash
curl https://api.paid.ai/v1/customers/northwind \
  -H "Authorization: Bearer $PAID_API_KEY" \
  -H "Paid-Version: 2026-11-01" \
  -H "Paid-Beta: customers=v1"
```

The response is the same customer object the create returned.

## 3. Keep its details current

When Northwind changes its billing contact, [update the customer](../../api-reference/customers/customers/update). Send only the fields that change:

**`PATCH /v1/customers/northwind`**

```json title="PATCH /v1/customers/northwind"
{
  "email": "finance@northwind.example",
  "metadata": { "crmOwner": "dana" }
}
```

The response is the whole customer with the new `email`. `metadata` holds your own key-value pairs; Paid stores them and never acts on them.

## 4. List your customers

[List customers](../../api-reference/customers/customers/list) to sync them with your CRM. Lists return the newest customers first, a page at a time, and filters narrow them, such as `email`:

```bash
curl -G https://api.paid.ai/v1/customers \
  -H "Authorization: Bearer $PAID_API_KEY" \
  -H "Paid-Version: 2026-11-01" \
  -H "Paid-Beta: customers=v1" \
  --data-urlencode "limit=100"
```

The response is a list object with the customers in `data`. When `hasMore` is `true`, send its `nextCursor` as `cursor` to get the next page. Read [Pagination](../../api-reference/pagination) for a loop that reads every page.

## 5. Archive a customer

When a company stops being your customer, [archive it](../../api-reference/customers/customers/archive). The request has no body:

**`POST /v1/customers/northwind/archive`**

```text title="POST /v1/customers/northwind/archive"
```

An archived customer stays readable and on its invoices, and keeps its `externalId` reserved, but can't be put on new orders. Lists leave it out unless you pass `includeArchived=true`. Archiving fails while the customer still has an active order.

## Next steps

* [Customers](/customers/customers): what a customer represents, identifying customers, and draft customers.
* [Customers API Reference](../../api-reference/customers/customers/create): every field and filter.
* [Versioning](/developers/api/versioning): how `Paid-Version` works, and how to upgrade.
* [Idempotency](../../api-reference/idempotency): retry writes safely.
* [Errors](/developers/api/errors): every error code and what to do about it.