Customers

Read Customer

GET
/customers/{id}.json

Retrieves the Customer properties by Advanced Billing-generated Customer ID.

Authorization

BasicAuth
AuthorizationBasic <token>

The username is a Maxio Chargify API key. The password is x.

In: header

Path Parameters

id*integer

The Advanced Billing id of the customer

Response Body

application/json

curl -X GET "https://example.com/customers/0.json"
{  "customer": {    "first_name": "Jane",    "last_name": "Doe",    "email": "jane@example.com",    "cc_emails": "joe@example.com",    "organization": "ABC, Inc.",    "reference": "1234567890",    "id": 88833369,    "created_at": "2025-05-08T11:39:18-04:00",    "updated_at": "2025-05-08T11:39:18-04:00",    "address": "123 Main Street",    "address_2": "Unit 10",    "city": "Anytown",    "state": "MA",    "state_name": "Massachusetts",    "zip": "02120",    "country": "US",    "country_name": "United States",    "phone": "555-555-1212",    "verified": false,    "portal_customer_created_at": null,    "portal_invite_last_sent_at": null,    "portal_invite_last_accepted_at": null,    "tax_exempt": false,    "surcharging": false,    "vat_number": null,    "parent_id": null,    "locale": "es-MX",    "salesforce_id": null,    "default_auto_renewal_profile_id": null  }}

Create Customer POST

Creates a new customer; can also be created alongside a new subscription. The only validation restriction is that you can only create one customer for a given reference value. If provided, the `reference` value must be unique. It represents a unique identifier for the customer from your own app, i.e. the customer’s ID. This allows you to retrieve a given customer via a piece of shared information. Alternatively, you can choose to leave `reference` blank, and store the system-assigned unique ID for the customer, which is in the `id` attribute. For more information, see [Customer Details](https://maxio.zendesk.com/hc/en-us/articles/24252190590093-Customer-Details). ## Required Country Format Format the country attribute of the customer using the ISO Standard Country codes. Countries should be formatted as two characters. For more information, see [ISO 3166-1](http://en.wikipedia.org/wiki/ISO_3166-1#Current_codes). ## Required State Format Format the state attribute of the customer using the ISO Standard State codes. + US States (two characters): see [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2:US). + States Outside the US (two to three characters): To find the correct state codes outside the US, go to [ISO 3166-1](http://en.wikipedia.org/wiki/ISO_3166-1#Current_codes) and click on the link in the “ISO 3166-2 codes” column next to the country you wish to populate. ## Locale You can attribute a language/region to the customer to deliver invoices in any required language. For more information, see [Customer Locale](https://maxio.zendesk.com/hc/en-us/articles/24286672013709-Customer-Locale). ## Tax and Business Identifiers Send `entity_identifier_kind` and `entity_identifier_value` together to store the customer's tax or business identifier, such as an EU VAT number, a French SIREN, or a LEI. A customer holds one identifier at a time. The `vat_eu` and `national_tax` kinds also require `vat_country`. An unsupported kind, a missing or mismatched `vat_country`, or a `gln`, `duns`, or `lei` value in the wrong format returns `422`. Always send the kind. `entity_identifier_value` on its own is stored as a `company_reg` when no `vat_country` is present, and returns `422` naming `entity_identifier_kind` when one is. A blank pair is ignored rather than rejected, so a `vat_number` sent alongside it still takes effect. The legacy `vat_number` and `vat_country` pair still works on its own. When neither entity identifier field is sent, Advanced Billing derives the kind from `vat_country`: an EU member state code or `GB` gives `vat_eu`, one of the national tax country codes gives `national_tax`, and a blank or unrecognized country gives `company_reg`. The response reports the stored identifier in `entity_identifier_kind` and `entity_identifier_value`, and repeats its value in `vat_number`.

Delete Customer DELETE

Deletes the customer.