> For the complete Lynkow documentation index in agent-friendly format, see [llms.txt](/llms.txt).

# Create an address for the current customer

**Published**: 2026-11-30
**Category**: Commerce

## `POST /customers/me/addresses`

**Create an address for the current customer**

Saves a new address for the signed-in customer. `isDefaultShipping: true`
or `isDefaultBilling: true` makes it the default in place of the current
one. A customer who already has 20 addresses gets 422
`CUSTOMER_ADDRESSES_LIMIT_REACHED`.

### Request Body

Content-Type: `application/json`

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `addressName` | string \| null | No | Label of the address, such as Home or Office |
| `firstName` | string | Yes | Required. Given name; on an address, the recipient's. 1-120 characters |
| `lastName` | string | Yes | Required. Family name; on an address, the recipient's. 1-120 characters |
| `company` | string \| null | No | Company name on the address |
| `address1` | string | Yes | Required. 1-255 characters |
| `address2` | string \| null | No | Second address line, such as an apartment or suite |
| `city` | string | Yes | Required. 1-120 characters |
| `postalCode` | string | Yes | Required. 1-32 characters |
| `province` | string \| null | No | State, province or region of the address |
| `countryCode` | string | Yes | Required. ISO 3166-1 alpha-2 country code |
| `phone` | string \| null | No | Phone number, stored as entered: no format is checked |
| `isDefaultShipping` | boolean | No | Whether this is the customer's default shipping address. `true` removes that default from their other addresses |
| `isDefaultBilling` | boolean | No | Whether this is the customer's default billing address. `true` removes that default from their other addresses |
| `metadata` | object | No | Custom key-value metadata |


### Responses

| Status | Description |
| --- | --- |
| `201` | Successful response |
| `401` | Missing or invalid storefront publishable key or customer session token |
| `402` | The site subscription does not currently permit this operation |
| `403` | The storefront key origin is not allowed |
| `404` | Site, resource, or commerce feature not found |
| `422` | Validation error |


> **Notes:** Returns 401 `CUSTOMER_AUTH_REQUIRED` without a valid session token, and
> 409 `RESOURCE_CONFLICT` when another address became the default concurrently.
> Limit: 10 per 15 minutes per site and client.

### SDK

```typescript
import { createClient } from 'lynkow'

const lynkow = createClient({
  siteId: process.env.LYNKOW_SITE_ID!,
  publishableKey: process.env.LYNKOW_PK,
})

const address = await lynkow.customers.addresses.create({
  firstName: 'Alice',
  lastName: 'Martin',
  address1: '12 rue de la Paix',
  city: 'Paris',
  postalCode: '75002',
  countryCode: 'FR',
  isDefaultShipping: true,
})
```

### Examples

```curl
curl -X POST "https://api.lynkow.com/storefront/{siteId}/customers/me/addresses" \
  -H "X-Lynkow-Pk: lkw_pk_..." \
  -H "Authorization: Bearer <customer-session-token>" \
  -H "Content-Type: application/json" \
  -d '{ "firstName": "Anna", "lastName": "Cooper", "address1": "1 Main Street", "city": "Madrid", "postalCode": "28001", "countryCode": "ES" }'
```

---