Companies API
A company groups the contacts of one client, supplier or partner. A company’s name is unique in your organization, whatever its letter case and the spaces around it. A contact names its company by name, and saving a contact with a name no company has adds that company.
The company object
Section titled “The company object”| Field | Type | Meaning |
|---|---|---|
id |
UUID | The company’s identifier. |
name |
string | Its name. |
taxId, street, postalCode, city |
string or null | Its tax ID and address. |
country |
string or null | A two-letter country code, such as PL. |
email, phone, website |
string or null | How to reach it. |
notes |
string or null | Notes on the company. |
contactCount |
integer | How many contacts name it. |
customFields |
object | The values of your custom fields that are not sensitive, by key. |
sensitiveCustomFields |
array of strings | The keys of the sensitive custom fields that hold a value; the values come from their own endpoint. |
createdAt, updatedAt |
time | When it was created and last changed. |
List companies
Section titled “List companies”GET/v1/companies
Key permission: get_companies
| Parameter | Meaning |
|---|---|
page, perPage |
Paging. |
search[name], search[taxId], search[city] |
Text to look for, in any letter case. Any other text field of the object can be searched the same way. |
filter[...] |
Filters on the object’s fields. |
sort |
A field to sort by, such as name, -city or -createdAt. |
Returns 200 OK with items and meta.
curl -g 'https://api.doxtly.com/v1/companies?search[name]=logistics&sort=name' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET"{ "items": [ { "id": "01a1ccda-2de3-734a-8d42-c39268868bf8", "name": "Atlas Logistics Group", "taxId": "IE 3348172QH", "street": "2 Grand Canal Square", "postalCode": "D02 A342", "city": "Dublin", "country": "IE", "email": "finance@atlas-logistics.example", "phone": "+353 1 437 0915", "website": "https://atlas-logistics.example", "notes": null, "contactCount": 1, "customFields": { "accountManager": "Helena Brandt", "creditLimit": "35000", "renewalDate": "2027-09-30" }, "sensitiveCustomFields": [], "createdAt": "2026-11-12T00:03:33+01:00", "updatedAt": "2026-11-12T00:03:33+01:00" }, { "id": "01a1ccda-2a5a-7eb8-bb24-d04f9fa1605c", "name": "Harbourline Logistics Ltd", "taxId": "GB 284 7712 06", "street": "14 Wapping Lane", "postalCode": "E1W 2RN", "city": "London", "country": "GB", "email": "office@harbourline.example", "phone": "+44 20 7946 0321", "website": "https://harbourline.example", "notes": "Framework agreement since 2024. Invoices to accounts payable, PO on every invoice.", "contactCount": 3, "customFields": { "accountManager": "Piotr Nowak", "creditLimit": "40000", "renewalDate": "2027-03-31", "purchaseOrderRef": "HL-PO-2026-118" }, "sensitiveCustomFields": [], "createdAt": "2026-11-12T00:03:32+01:00", "updatedAt": "2026-11-12T00:04:01+01:00" } ], "meta": { "total": 2, "page": 1, "perPage": 20, "totalPages": 1, "hasMore": false, "hasPrevious": false }}Create a company
Section titled “Create a company”POST/v1/companies
Key permission: create_company
| Field | Type | Required | Rules |
|---|---|---|---|
name |
string | Yes | Up to 200 characters, unique in your organization. |
taxId |
string | No | Up to 50 characters. |
street |
string | No | Up to 255 characters. |
postalCode |
string | No | Up to 20 characters. |
city |
string | No | Up to 100 characters. |
country |
string | No | An ISO 3166 two-letter code, stored in capitals. |
email |
string | No | A valid address, up to 255 characters. |
phone |
string | No | Up to 50 characters. |
website |
string | No | An http or https address with a domain, up to 255 characters; https:// is added when there is no scheme. |
notes |
string | No | Up to 2000 characters. |
customFields |
object | No | Values of your custom fields by key. A sensitive field also needs read_sensitive_custom_fields. |
Returns 201 Created with the company. 422 when the name is taken or a field is wrong; 403 when a sensitive custom field is given without read_sensitive_custom_fields; 409 when another company or contact holds the value of a unique custom field.
curl -X POST 'https://api.doxtly.com/v1/companies' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' \ -d '{"name":"Kestrel Analytics sp. z o.o.","taxId":"PL5261040828","street":"ul. Prosta 51","postalCode":"00-838","city":"Warszawa","country":"pl","email":"office@kestrel-analytics.example","website":"kestrel-analytics.example","customFields":{"accountManager":"Piotr Nowak","creditLimit":20000}}'{ "id": "01a1ce96-64d7-7225-a82d-dec4454f6aef", "name": "Kestrel Analytics sp. z o.o.", "taxId": "PL5261040828", "street": "ul. Prosta 51", "postalCode": "00-838", "city": "Warszawa", "country": "PL", "email": "office@kestrel-analytics.example", "phone": null, "website": "https://kestrel-analytics.example", "notes": null, "contactCount": 0, "customFields": { "accountManager": "Piotr Nowak", "creditLimit": "20000" }, "sensitiveCustomFields": [], "createdAt": "2026-11-12T08:08:45+01:00", "updatedAt": "2026-11-12T08:08:45+01:00"}Get a company
Section titled “Get a company”GET/v1/companies/{id}
Key permission: read_company. Returns 200 OK with the company. An id that isn’t one of your companies answers 404, here and in the calls below.
curl 'https://api.doxtly.com/v1/companies/01a1ccda-2ad5-70dd-aa62-48bede3a76f7' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET"{ "id": "01a1ccda-2ad5-70dd-aa62-48bede3a76f7", "name": "Nordvik Marine AS", "taxId": "NO 918 452 337 MVA", "street": "Bryggen 21", "postalCode": "5003", "city": "Bergen", "country": "NO", "email": "post@nordvik-marine.example", "phone": "+47 55 30 41 10", "website": "https://nordvik-marine.example", "notes": null, "contactCount": 2, "customFields": { "accountManager": "Emily Carter", "creditLimit": "25000", "renewalDate": "2027-01-15" }, "sensitiveCustomFields": [], "createdAt": "2026-11-12T00:03:32+01:00", "updatedAt": "2026-11-12T00:03:32+01:00"}Update a company
Section titled “Update a company”PATCH/v1/companies/{id}
Key permission: update_company. Takes the fields of Create; a field left out stays as it is, and an empty one is taken away. Returns 200 OK with the company. The errors are those of Create, and 422 also when the name is emptied.
curl -X PATCH 'https://api.doxtly.com/v1/companies/01a1ce96-64d7-7225-a82d-dec4454f6aef' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' \ -d '{"phone":"+48 22 640 18 20","notes":"Framework agreement from January 2027."}'{ "id": "01a1ce96-64d7-7225-a82d-dec4454f6aef", "name": "Kestrel Analytics sp. z o.o.", "taxId": "PL5261040828", "street": "ul. Prosta 51", "postalCode": "00-838", "city": "Warszawa", "country": "PL", "email": "office@kestrel-analytics.example", "phone": "+48 22 640 18 20", "website": "https://kestrel-analytics.example", "notes": "Framework agreement from January 2027.", "contactCount": 0, "customFields": { "accountManager": "Piotr Nowak", "creditLimit": "20000" }, "sensitiveCustomFields": [], "createdAt": "2026-11-12T08:08:45+01:00", "updatedAt": "2026-11-12T08:08:45+01:00"}Delete a company
Section titled “Delete a company”DELETE/v1/companies/{id}
Key permission: delete_company. Returns 204 No Content. Its contacts stay, without a company. While a workflow’s step names the company, it answers 409 with code used_by_workflows and workflows (their id and name): change them first.
curl -X DELETE 'https://api.doxtly.com/v1/companies/01a1ce96-64d7-7225-a82d-dec4454f6aef' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET"List a company’s documents
Section titled “List a company’s documents”GET/v1/companies/{id}/documents
Key permission: get_company_documents. Returns 200 OK with the packages any of the company’s contacts is a party to or views, each once: id, title, derivedStatus, completionPercentage, createdAt, completedAt and contacts, with each contact’s id, fullName, partyIndicators and isViewer. Each also has contract, where a contract stands, and change, {kind, number, contract: {id, title, number}} for a change of a contract (see Contracts), each null otherwise. It is paged as the list, and takes the sorting and search[title] of the packages list; the list’s filter parameters don’t apply here. A key also needs one of the operations that view documents, such as get_document_packages, to see any: without one the list is empty.
curl 'https://api.doxtly.com/v1/companies/01a1ccda-2ad5-70dd-aa62-48bede3a76f7/documents?perPage=2' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET"{ "items": [ { "id": "01a1ccdd-25af-704e-9e29-6ff7c1559c96", "title": "Engagement letter - Nordvik Marine", "derivedStatus": "in_progress", "completionPercentage": 0, "contacts": [ { "id": "01a1ccda-3248-7d84-a227-57c7eef2b550", "fullName": "Lars Eriksen", "partyIndicators": [], "isViewer": true }, { "id": "01a1ccda-31be-7e48-8ee3-b69d1cd816b8", "fullName": "Ingrid Halvorsen", "partyIndicators": [ "CLIENT" ], "isViewer": false } ], "createdAt": "2026-11-12T00:06:47+01:00", "completedAt": null, "contract": null, "change": null }, { "id": "01a1cd4e-2b57-77c3-8b8c-5a90de5ead28", "title": "Engagement letter - Nordvik Marine (fleet safety)", "derivedStatus": "pending", "completionPercentage": 0, "contacts": [ { "id": "01a1ccda-31be-7e48-8ee3-b69d1cd816b8", "fullName": "Ingrid Halvorsen", "partyIndicators": [ "CLIENT" ], "isViewer": false } ], "createdAt": "2026-11-12T02:10:14+01:00", "completedAt": null, "contract": null, "change": null } ], "meta": { "total": 3, "page": 1, "perPage": 2, "totalPages": 2, "hasMore": true, "hasPrevious": false }}