Update account details
Overview
Updates billing contact details and returns the full account response. Send every profile field. first_name, last_name, address1, city, postcode, country and phone_number need values. Send empty strings to clear company_name, address2, state or tax_id. Use a two-letter country code and a phone number starting with + and the country code. Other fields are ignored. Contact support to change the account email. Returns 400 with an explanation if billing rejects the change.
Permissions
Requires the account permission account.update (Change the account).
Authorization
Your API key, sent as a bearer token. Create one in the control panel under API Keys, give it only the permissions the integration needs, and copy it when it is created. It cannot be shown again. Each key is restricted to one owned team. The key determines the team for every request.
Send it as Bearer <token>.
Body
application/jsonThe account holder's first name.
1 to 64 characters
Must match ^[^\p{C}]*$
The account holder's last name.
1 to 64 characters
Must match ^[^\p{C}]*$
The company name for billing, or null or an empty string to clear it.
At most 128 characters
Must match ^[^\p{C}]*$
The first line of the billing address.
1 to 255 characters
Must match ^[^\p{C}]*$
The second line of the billing address, or null or an empty string to clear it.
At most 255 characters
Must match ^[^\p{C}]*$
The city for the billing address.
1 to 128 characters
Must match ^[^\p{C}]*$
The billing state, province, or region, or null or an empty string to clear it.
At most 128 characters
Must match ^[^\p{C}]*$
The postal code for the billing address.
1 to 32 characters
Must match ^[^\p{C}]*$
The ISO 3166-1 alpha-2 country code.
Exactly 2 characters
The phone number, including its country calling code.
4 to 32 characters
Must match ^\+[1-9][\d\s().-]*\d$
The tax identification number, or null or an empty string to clear it.
At most 64 characters
Must match ^[^\p{C}]*$
Response 200
application/jsonThe record, as a JSON object. There is no envelope.
The name and address used for billing. Missing values are null, not empty strings.
Show child attributesHide child attributes
The account holder's first name, or null when it is not provided.
The account holder's last name, or null when it is not provided.
The company name used for billing, or null when it is not provided.
The first line of the billing address, or null when it is not provided.
The second line of the billing address, or null when it is not provided.
The billing address city, or null when it is not provided.
The billing address state, province, or region, or null when it is not provided.
The billing address postal code, or null when it is not provided.
An ISO 3166-1 alpha-2 code, or null where the stored value is not one.
The country display name, or null when the stored country code is not recognized.
The billing contact phone number, or null when it is not provided.
The tax identification number, or null when it is not provided.
The current outstanding balance, including partial payments. Amounts include currency symbols and digit separators. Display these strings directly; do not parse them as numbers.
Show child attributesHide child attributes
The total unpaid balance, formatted for display, or null when unavailable.
The overdue balance, formatted for display, or null when unavailable.
The available account credit, formatted for display, or null when unavailable.
The number of invoices with an outstanding balance.
The number of overdue invoices.
Whether the account has an unpaid balance.
Whether the account has an overdue balance.
The three-letter billing currency code, or null when it is not known.
The currency the account is billed in, or null when it is not known.
The account email address. It cannot be changed through this endpoint.
Whether the email address is verified. Null means the billing record does not provide this information; it does not mean false.
A link to the external account portal, or null if no portal is configured.
Errors
- 400
- The account's billing record could not be reached, this installation has none behind it, or the change was refused with a reason of its own. The message says which.
- 401
- The key was missing, malformed, revoked, or belongs to an account that no longer exists.
- 403
- Access denied. Check the key's team, permissions and allowed IP addresses. Some actions, such as managing API keys, require a browser session. The response message explains the reason.
- 422
- A field is missing or invalid, or the resource cannot accept this change in its current state. Check
messagefor details. Field validation also includes anerrorsobject keyed by field name. - 429
- Too many requests. The
Retry-Afterheader says how many seconds to wait. Limits are per account, so several keys on one account share them.
Still stuck? Contact our team
View as Markdown