Link customers
Create or update an account with your ownaccountId and the customers to add:
Response
null clears the name), adds customers with addCustomerIds and takes them out with removeCustomerIds. Adding a customer already in the account, or removing one that isn’t, changes nothing. A customer in another account moves over with move: true.
Read an account
- Get an account by its ID, with its
customerIds. - Get a customer’s account with
GET /v1/accounts?customerId=. - Get a customer and list customers include
accountId.
Remove and delete
Removing an account’s last customer keeps the account, empty, since you own its ID. Delete it to unlink every customer in it; nothing else about them changes.Rules
- Display only. Check, track, attach and invoices read each customer on its own.
- One account per customer. Adding a customer that’s in another account is
409 customer_in_other_account, naming that account inaccountId, unless the request sendsmove: true. - All or nothing. Every change in a request is made together or not at all, and a refused request creates no account.
- Up to 100 IDs in each of
addCustomerIdsandremoveCustomerIds, and a customer in one list only (400 invalid_request). - Known customers. An unknown customer in
addCustomerIdsis404 customer_not_found; a customer in no account reads as404 account_not_found. - Permissions. Reading accounts needs the Customers permission at Read; changing them needs it at Write.
Related
- Creating customers: the customers accounts group.
- Entities: users and workspaces inside one customer, sharing its balance.