API reference

Entities

Register and manage companies (entities) that will send invoices. Each entity is owned by a user of your application. By default an entity is owned by the application owner — i.e. you create it for yourself — but you can attribute it to any user you created by passing their user_id, letting your users own their own entities. Requires an access token.

POST/oauth/entitiesAccess token

Create an entity

Register a company. TRN must be exactly 15 characters and unique. Omit user_id and the entity is owned by the application owner (the default — you create the entity for yourself). To create the entity on behalf of one of your users, set user_id to that user's id (from POST /oauth/users); it must belong to this same application.

Request body example
{
  "company_name": "ABC Corporation",
  "trn": "123456442311611",
  "country": "United Arab Emirates",
  "state": "Dubai",
  "city": "Dubai",
  "area": "Downtown",
  "postal_code": "12345",
  "mobile": "+971501234567",
  "landline": "+97143210000",
  "email": "info@abccorp.com",
  "email_notifications_enabled": true,
  "user_id": ""
}
GET/oauth/entitiesAccess token

List entities

Return entities created by your application. Pass user_id to return only the entities owned by a specific user.

GET/oauth/entities/{entity_id}Access token

Get an entity

Fetch a single entity created by your application.

PATCH/oauth/entities/{entity_id}Access token

Update an entity

Update one or more fields of an entity.

Request body example
{
  "city": "Abu Dhabi",
  "email": "billing@abccorp.com"
}
DELETE/oauth/entities/{entity_id}Access token

Delete an entity

Soft-delete an entity created by your application.