Update a client company
curl --request PATCH \ --url https://example.com/api/v1/clients/example \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "additionalDomains": [ "example" ], "address": "example", "billingEmails": [ "hello@example.com" ], "companyName": "example", "currency": "example", "isActive": true, "mcpEnabled": true, "name": "example", "paymentReminderSchedule": { "daysAfterDue": 1, "maxCount": 1, "repeatEveryDays": 1 }, "paymentRemindersPaused": true, "paymentTerms": { "kind": "NET_DAYS", "value": 1 }, "phone": "example", "platform": "example", "prefix": "example", "statusId": "example", "stripeCustomerId": "example", "tagIds": [ "example" ], "taxId": "example", "weeklyHoursBalance": true }'Partially updates a client company. Requires the clients.edit permission. companyName, taxId and phone are left untouched when omitted and cleared by null or an empty string – companyName is the legal name printed on invoices, estimates and the portal, distinct from the internal working label name. prefix is the company’s order code prefix (2 to 10 letters or digits, stored uppercase, unique within the workspace), which new order codes for the company will start with: omit it to leave it untouched, send null or an empty string to clear it; changing it never rewrites the codes of existing orders, and a malformed or already-used prefix is refused before any other field is written (422 or 409, with error.fieldErrors.prefix). tagIds is a full-replacement field: omit it to leave tags untouched, send [] to clear every tag. billingEmails is a full-replacement field: the addresses (up to 5, stored lowercase, repeats collapse) that every invoice email and payment reminder of the company goes to besides the contact the invoice is addressed to; omit it to leave them untouched, send [] to clear them (an invoice with no reachable contact then goes to the company’s Billing contact, else its primary, else its oldest active portal contact), and an address that is not valid returns 422. paymentRemindersPaused pauses (true) or resumes (false) payment reminders for every invoice of the company, present or future; omit to leave it untouched, and repeating the current state changes nothing. paymentReminderSchedule sets the reminder schedule (days after due, repeat interval, maximum) every invoice of the company follows instead of the workspace’s – null follows the workspace schedule again, omit leaves it untouched, and the limits match the workspace’s reminder settings. A reminder dated before the day of the change (workspace time) is never sent, and a pause still wins over any schedule. paymentTerms sets the terms the company’s new invoices are due by – { kind: NET_DAYS, value: 0-365 } or { kind: DAY_OF_MONTH, value: 1-31 } (the next such day after the issue day, the month’s last day when it has none) – null follows the workspace’s payment terms again, omit leaves them untouched; invoices already issued keep their due dates. stripeCustomerId sets the company’s Stripe customer (cus_...); omit to leave it untouched, send null or an empty string to clear it, a malformed id returns 422 and one another company of the workspace already holds returns 409. The id is not returned by any read; Stripe verifies it the first time it is used. weeklyHoursBalance turns the weekly hours balance email on (true) or off (false) for the company’s Billing contacts; omit to leave it untouched, and repeating the current state changes nothing. Reads return it as weeklyHoursBalance, which is absent on a server older than the field. platform is the site platform the company runs on (a free label up to 60 characters such as WordPress or Shopify): omit to leave it untouched, send null or an empty string to clear it. additionalDomains is a full-replacement list of the company’s email domains beyond its first one (up to 20, normalized, repeats and the first domain dropped): omit to leave them untouched, send [] to clear them; a value that is not a domain, or a free email provider, returns 422 with error.fieldErrors.additionalDomains. statusId refuses Lead, Contact and Spam, which describe people, with 422 and error.fieldErrors.statusId; every other status is allowed, and so are keeping the current status and sending null. The response carries domains.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Resource identifier (CUID2).
Resource identifier (CUID2).
Request Body
Section titled “Request Body”object
Full replacement of the company’s email domains beyond its first one. Each entry is normalized like a company email domain, and blanks, repeats and the first domain itself are dropped; a free email provider returns 422. Omit to leave them untouched; send an empty array to clear them.
Full replacement of the addresses every invoice email and payment reminder of the company goes to besides the contact the invoice is addressed to, up to 5; stored lowercase, repeats collapse. Omit to leave them untouched; send an empty array to clear them, after which an invoice with no reachable contact goes to the company’s Billing contact, else its primary, else its oldest active portal contact.
Sets the schedule every invoice of the company follows for payment reminders; send null to follow the workspace schedule again. Omit to leave it untouched. A reminder dated before the day of the change is never sent, and repeating the current schedule changes nothing.
object
Days after an invoice’s due date, counted in the workspace timezone, before the first reminder.
Most reminders one invoice receives when they repeat. Stored as 1 while repeatEveryDays is 0.
Days between reminders while the invoice stays unpaid. 0 sends a single reminder.
True stops payment reminders for every invoice of the company, present or future; false resumes them. Omit to leave the switch untouched.
Sets the company’s own payment terms; send null to follow the workspace’s again, omit to leave them untouched. Applies to invoices issued from then on: renewals, sales and new invoices. Invoices already issued keep their due dates. Days are counted in the workspace timezone.
object
NET_DAYS: due value days after the issue day (0-365). DAY_OF_MONTH: due on the next day value (1-31) strictly after the issue day; a month without that day uses its last.
Omit to leave the phone untouched; send null or an empty string to clear it.
The company’s order code prefix: 2 to 10 letters or digits, stored uppercase and unique within the workspace. New order codes for the company will start with it. Omit to leave it untouched; send null or an empty string to clear it. Changing it never rewrites the codes of existing orders.
Sets the client’s status. Omit to leave it untouched; send null to clear it. A change to Lead, Contact or Spam is refused (422), since those describe people; keeping the current status or clearing it is always allowed.
The company’s customer id in the workspace’s Stripe account (cus_...), which its card payments and subscriptions use. Another company of the workspace cannot hold the same id. It is verified with Stripe the first time it is used. Omit to leave it untouched; send null or an empty string to clear it.
Full replacement of the client’s tag set. Omit the field to leave tags untouched; send an empty array to clear every tag.
Omit to leave the tax identifier untouched; send null or an empty string to clear it.
True sends the company’s Billing contacts the weekly hours balance email every Monday; false stops it. Omit to leave the switch untouched; repeating the current state changes nothing.
Responses
Section titled “Responses”The updated client company.
object
A billable client.
object
Addresses every invoice email and payment reminder of the company goes to besides the contact the invoice is addressed to, up to 5. Empty only matters for an invoice with no reachable contact, which then goes to the company’s Billing contact, else its primary, else its oldest active portal contact.
The client’s legal name, printed on invoices, estimates and the portal. name stays the internal working label the team files the client under and is never shown on a client-facing document. Null falls back to name – see clientLegalName.
Direct Access grants – a MANAGER-level grant is the client’s responsible. Present on single-client reads; omitted from list responses.
A workspace member with Direct Access to a client. A MANAGER-level grant is the client’s responsible, receiving its projects’ alerts and the daily hours report.
object
MANAGER is the resource’s responsible: it receives the resource’s alerts and hours report, in addition to Direct Access like any MEMBER.
Every email domain of the company, its first one first, then the extras in the order they were added. Present on single-client reads; omitted from list responses, and absent on a server older than this field.
The payment-reminder schedule every invoice of the company follows in place of the workspace’s. Null means the company follows the workspace schedule.
object
Days after an invoice’s due date, counted in the workspace timezone, before the first reminder.
Most reminders one invoice receives when they repeat. Stored as 1 while repeatEveryDays is 0.
Days between reminders while the invoice stays unpaid. 0 sends a single reminder.
While true, none of the company’s invoices, present or future, get payment reminders.
The terms the company’s new invoices are due by. Null means the workspace’s payment terms (net days, see GET /invoice-settings).
object
NET_DAYS: due value days after the issue day (0-365). DAY_OF_MONTH: due on the next day value (1-31) strictly after the issue day; a month without that day uses its last.
The company’s order code prefix: 2 to 10 letters or digits, uppercase, unique within the workspace. New order codes for the company start with it, like ACME-HOURS-6. Null until someone sets it.
Roles reaching the whole client, then roles limited to one of its projects (projectId set). Present on single-client reads; omitted from list responses.
A role assigned to a client, granting inherited access to its orders and projects, or to one of its projects.
object
The company project the role is limited to; null when it reaches the whole company.
The client’s status in the workspace catalog – see GET /clients/statuses. Null means unassigned.
A workspace tag attached to a client.
object
The client company’s tax identifier (VAT, EIN, RFC…). Null when unknown.
Present on single-client reads; omitted from list responses.
A team assigned to a client, granting inherited access to its orders.
object
Whether the company’s Billing contacts get the weekly hours balance email every Monday. Absent on a server older than this field.
Example
{ "data": { "directAccess": [ { "level": "MANAGER" } ], "paymentTerms": { "kind": "NET_DAYS" } }}Validation error. Parse failures include field paths and expectations.
Validation error with safe field paths and expected values; submitted values are never returned.
object
object
Stable machine-readable error code.
object
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Unauthorized.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Forbidden.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Client company not found, one or more tags not found, or the notification channel does not exist in this workspace.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Another company of the workspace carries the prefix (error.fieldErrors.prefix).
Error envelope with field-level messages.
object
object
Stable machine-readable error code.
Message per offending field; a list item is keyed <field>.<index>.<key>.
object
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Invalid input, with field-level messages.
Error envelope with field-level messages.
object
object
Stable machine-readable error code.
Message per offending field; a list item is keyed <field>.<index>.<key>.
object
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Rate limit exceeded. Wait for Retry-After before retrying.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Headers
Section titled “Headers”Maximum requests in the current quota window.
Quota policy in requests and window seconds, for example 60;w=60.
Requests left in this quota window (zero when blocked).
Seconds until the current quota window resets, when available from the rate-limit store.
Seconds until another request may be attempted.
Chelsea is operated by Arepa Labs LLC