clientary.api.* operation is listed below with parameter shapes and return types from the plugin Zod schemas.
Clients
create
clients.create
Create a client
Risk: write
await corsair.clientary.api.clients.create({});
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Client name |
number | string | No | Client number (unique) |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
delete
clients.delete
Delete a client and all associated projects, invoices, estimates, and contacts [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.clients.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Client ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
clients.get
Get a client by ID
Risk: read
await corsair.clientary.api.clients.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Client ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
list
clients.list
List clients
Risk: read
await corsair.clientary.api.clients.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
updated_since | string | No | Only return clients updated since this date (YYYY-MM-DD) |
sort | date | No | Sort by most recently created |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
clients | object[] | Yes | — |
clients full type
clients full type
{
id: number,
number?: string | null,
name: string,
city?: string | null,
address?: string | null,
address_2?: string | null,
zip?: string | null,
country?: string | null,
state?: string | null,
website?: string | null,
description?: string | null,
invoice_extra_fields?: any | null
}[]
update
clients.update
Update a client
Risk: write
await corsair.clientary.api.clients.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Client ID |
name | string | No | Client name |
number | string | No | Client number (unique) |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
Contacts
create
contacts.create
Create a contact
Risk: write
await corsair.clientary.api.contacts.create({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client the contact belongs to |
name | string | Yes | Contact name |
email | string | Yes | Contact email |
title | string | No | — |
phone | string | No | — |
mobile | string | No | — |
ext | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
name | string | Yes | — |
email | string | No | — |
title | string | No | — |
phone | string | No | — |
mobile | string | No | — |
ext | string | No | — |
avatar | string | No | — |
delete
contacts.delete
Delete a contact [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.contacts.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Contact ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
contacts.get
Get a contact by ID
Risk: read
await corsair.clientary.api.contacts.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Contact ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
name | string | Yes | — |
email | string | No | — |
title | string | No | — |
phone | string | No | — |
mobile | string | No | — |
ext | string | No | — |
avatar | string | No | — |
list
contacts.list
List contacts
Risk: read
await corsair.clientary.api.contacts.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
contacts | object[] | Yes | — |
contacts full type
contacts full type
{
id: number,
client_id?: number | null,
name: string,
email?: string | null,
title?: string | null,
phone?: string | null,
mobile?: string | null,
ext?: string | null,
avatar?: string | null
}[]
listForClient
contacts.listForClient
List contacts belonging to a client
Risk: read
await corsair.clientary.api.contacts.listForClient({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client ID to scope contacts by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
contacts | object[] | Yes | — |
contacts full type
contacts full type
{
id: number,
client_id?: number | null,
name: string,
email?: string | null,
title?: string | null,
phone?: string | null,
mobile?: string | null,
ext?: string | null,
avatar?: string | null
}[]
update
contacts.update
Update a contact
Risk: write
await corsair.clientary.api.contacts.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Contact ID |
name | string | No | Contact name |
email | string | No | Contact email |
title | string | No | — |
phone | string | No | — |
mobile | string | No | — |
ext | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
name | string | Yes | — |
email | string | No | — |
title | string | No | — |
phone | string | No | — |
mobile | string | No | — |
ext | string | No | — |
avatar | string | No | — |
Estimates
create
estimates.create
Create an estimate
Risk: write
await corsair.clientary.api.estimates.create({});
| Name | Type | Required | Description |
|---|---|---|---|
number | number | No | Estimate number (autoincrements) |
date | string | Yes | Estimate date (YYYY-MM-DD) |
currency_code | string | Yes | ISO currency code, e.g. USD |
title | string | No | — |
note | string | No | — |
client_id | number | No | — |
status | number | No | — |
tax | number | No | — |
tax2 | number | No | — |
tax3 | number | No | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | No | — |
summary | string | No | — |
estimate_items_attributes | object[] | No | Estimate line items |
estimate_items_attributes full type
estimate_items_attributes full type
{
id?: number,
_destroy?: boolean,
title?: string,
quantity?: number,
price?: number,
taxable?: boolean
}[]
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
title | string | No | — |
date | string | Yes | — |
client_id | number | No | — |
note | string | No | — |
status | number | Yes | — |
currency_code | string | Yes | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
summary | string | No | — |
estimate_items | object[] | No | — |
estimate_items full type
estimate_items full type
{
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
delete
estimates.delete
Delete an estimate [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.estimates.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Estimate ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
estimates.get
Get an estimate by ID
Risk: read
await corsair.clientary.api.estimates.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Estimate ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
title | string | No | — |
date | string | Yes | — |
client_id | number | No | — |
note | string | No | — |
status | number | Yes | — |
currency_code | string | Yes | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
summary | string | No | — |
estimate_items | object[] | No | — |
estimate_items full type
estimate_items full type
{
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
list
estimates.list
List estimates
Risk: read
await corsair.clientary.api.estimates.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
estimates | object[] | Yes | — |
estimates full type
estimates full type
{
id: number,
number?: string | null,
title?: string | null,
date: string,
client_id?: number | null,
note?: string | null,
status: number,
currency_code: string,
subtotal: number,
total_cost: number,
tax: number,
tax2: number,
tax3: number,
tax_label?: string | null,
tax2_label?: string | null,
tax3_label?: string | null,
compound_tax: boolean,
summary?: string | null,
estimate_items?: {
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
}[]
listForClient
estimates.listForClient
List estimates belonging to a client
Risk: read
await corsair.clientary.api.estimates.listForClient({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client ID to scope estimates by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
estimates | object[] | Yes | — |
estimates full type
estimates full type
{
id: number,
number?: string | null,
title?: string | null,
date: string,
client_id?: number | null,
note?: string | null,
status: number,
currency_code: string,
subtotal: number,
total_cost: number,
tax: number,
tax2: number,
tax3: number,
tax_label?: string | null,
tax2_label?: string | null,
tax3_label?: string | null,
compound_tax: boolean,
summary?: string | null,
estimate_items?: {
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
}[]
listForProject
estimates.listForProject
List estimates belonging to a project
Risk: read
await corsair.clientary.api.estimates.listForProject({});
| Name | Type | Required | Description |
|---|---|---|---|
project_id | number | Yes | Project ID to scope estimates by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
estimates | object[] | Yes | — |
estimates full type
estimates full type
{
id: number,
number?: string | null,
title?: string | null,
date: string,
client_id?: number | null,
note?: string | null,
status: number,
currency_code: string,
subtotal: number,
total_cost: number,
tax: number,
tax2: number,
tax3: number,
tax_label?: string | null,
tax2_label?: string | null,
tax3_label?: string | null,
compound_tax: boolean,
summary?: string | null,
estimate_items?: {
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
}[]
send
estimates.send
Send an estimate via email
Risk: write
await corsair.clientary.api.estimates.send({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Estimate ID to send |
recipients | string[] | Yes | Recipient email addresses |
subject | string | No | Email subject line |
message | string | No | Email body message |
send_copy | boolean | number | No | Send a copy to the sending user |
attach_pdf | boolean | number | No | Attach a PDF of the estimate |
| Name | Type | Required | Description |
|---|---|---|---|
sent | true | Yes | — |
id | number | Yes | — |
update
estimates.update
Update an estimate
Risk: write
await corsair.clientary.api.estimates.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Estimate ID |
number | number | No | Estimate number (autoincrements) |
date | string | No | Estimate date (YYYY-MM-DD) |
currency_code | string | No | ISO currency code, e.g. USD |
title | string | No | — |
note | string | No | — |
client_id | number | No | — |
status | number | No | — |
tax | number | No | — |
tax2 | number | No | — |
tax3 | number | No | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | No | — |
summary | string | No | — |
estimate_items_attributes | object[] | No | Estimate line items |
estimate_items_attributes full type
estimate_items_attributes full type
{
id?: number,
_destroy?: boolean,
title?: string,
quantity?: number,
price?: number,
taxable?: boolean
}[]
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
title | string | No | — |
date | string | Yes | — |
client_id | number | No | — |
note | string | No | — |
status | number | Yes | — |
currency_code | string | Yes | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
summary | string | No | — |
estimate_items | object[] | No | — |
estimate_items full type
estimate_items full type
{
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
Expenses
create
expenses.create
Create an expense
Risk: write
await corsair.clientary.api.expenses.create({});
| Name | Type | Required | Description |
|---|---|---|---|
amount | number | Yes | Expense amount |
description | string | No | — |
incurred_on | string | No | Date incurred (YYYY-MM-DD) |
client_id | number | No | — |
project_id | number | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
project_id | number | No | — |
invoice_id | number | No | — |
invoice_item_id | number | No | — |
user_id | number | No | — |
amount | number | Yes | — |
description | string | No | — |
incurred_on | string | Yes | — |
delete
expenses.delete
Delete an expense [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.expenses.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Expense ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
expenses.get
Get an expense by ID
Risk: read
await corsair.clientary.api.expenses.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Expense ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
project_id | number | No | — |
invoice_id | number | No | — |
invoice_item_id | number | No | — |
user_id | number | No | — |
amount | number | Yes | — |
description | string | No | — |
incurred_on | string | Yes | — |
list
expenses.list
List expenses
Risk: read
await corsair.clientary.api.expenses.list({});
| Name | Type | Required | Description |
|---|---|---|---|
from_date | string | No | Start of date range (YYYY-MM-DD) |
to_date | string | No | End of date range (YYYY-MM-DD) |
| Name | Type | Required | Description |
|---|---|---|---|
total_count | number | Yes | — |
from_date | string | Yes | — |
to_date | string | Yes | — |
expenses | object[] | Yes | — |
expenses full type
expenses full type
{
id: number,
client_id?: number | null,
project_id?: number | null,
invoice_id?: number | null,
invoice_item_id?: number | null,
user_id?: number | null,
amount: number,
description?: string | null,
incurred_on: string
}[]
listForClient
expenses.listForClient
List expenses belonging to a client
Risk: read
await corsair.clientary.api.expenses.listForClient({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client ID to scope expenses by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
total_count | number | Yes | — |
from_date | string | Yes | — |
to_date | string | Yes | — |
expenses | object[] | Yes | — |
expenses full type
expenses full type
{
id: number,
client_id?: number | null,
project_id?: number | null,
invoice_id?: number | null,
invoice_item_id?: number | null,
user_id?: number | null,
amount: number,
description?: string | null,
incurred_on: string
}[]
listForProject
expenses.listForProject
List expenses belonging to a project
Risk: read
await corsair.clientary.api.expenses.listForProject({});
| Name | Type | Required | Description |
|---|---|---|---|
project_id | number | Yes | Project ID to scope expenses by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
total_count | number | Yes | — |
from_date | string | Yes | — |
to_date | string | Yes | — |
expenses | object[] | Yes | — |
expenses full type
expenses full type
{
id: number,
client_id?: number | null,
project_id?: number | null,
invoice_id?: number | null,
invoice_item_id?: number | null,
user_id?: number | null,
amount: number,
description?: string | null,
incurred_on: string
}[]
update
expenses.update
Update an expense
Risk: write
await corsair.clientary.api.expenses.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Expense ID |
amount | number | No | Expense amount |
description | string | No | — |
incurred_on | string | No | Date incurred (YYYY-MM-DD) |
client_id | number | No | — |
project_id | number | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
project_id | number | No | — |
invoice_id | number | No | — |
invoice_item_id | number | No | — |
user_id | number | No | — |
amount | number | Yes | — |
description | string | No | — |
incurred_on | string | Yes | — |
Hours
create
hours.create
Log hours to a project
Risk: write
await corsair.clientary.api.hours.create({});
| Name | Type | Required | Description |
|---|---|---|---|
project_id | number | Yes | Project to log hours against |
hours | number | Yes | Number of hours logged |
title | string | Yes | Title of the logged work |
description | string | No | — |
date | string | No | Date logged (YYYY-MM-DD) |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
project_id | number | Yes | — |
user_id | number | No | — |
title | string | Yes | — |
description | string | No | — |
date | string | Yes | — |
hours | number | Yes | — |
rate | number | No | — |
cost | number | No | — |
billed? | boolean | No | — |
delete
hours.delete
Delete an hours entry [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.hours.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Hours entry ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
hours.get
Get an hours entry by ID
Risk: read
await corsair.clientary.api.hours.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Hours entry ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
project_id | number | Yes | — |
user_id | number | No | — |
title | string | Yes | — |
description | string | No | — |
date | string | Yes | — |
hours | number | Yes | — |
rate | number | No | — |
cost | number | No | — |
billed? | boolean | No | — |
listForProject
hours.listForProject
List hours logged against a project
Risk: read
await corsair.clientary.api.hours.listForProject({});
| Name | Type | Required | Description |
|---|---|---|---|
project_id | number | Yes | Project ID to scope hours by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
filter | billed | unbilled | No | Narrow to billed or unbilled hours |
| Name | Type | Required | Description |
|---|---|---|---|
hours | object[] | Yes | — |
hours full type
hours full type
{
id: number,
project_id: number,
user_id?: number | null,
title: string,
description?: string | null,
date: string,
hours: number,
rate?: number | null,
cost?: number | null,
billed??: boolean
}[]
update
hours.update
Update an hours entry
Risk: write
await corsair.clientary.api.hours.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Hours entry ID |
hours | number | No | Number of hours logged |
title | string | No | Title of the logged work |
description | string | No | — |
date | string | No | Date logged (YYYY-MM-DD) |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
project_id | number | Yes | — |
user_id | number | No | — |
title | string | Yes | — |
description | string | No | — |
date | string | Yes | — |
hours | number | Yes | — |
rate | number | No | — |
cost | number | No | — |
billed? | boolean | No | — |
Invoices
create
invoices.create
Create an invoice
Risk: write
await corsair.clientary.api.invoices.create({});
| Name | Type | Required | Description |
|---|---|---|---|
number | number | No | Invoice number (autoincrements) |
date | string | Yes | Invoice date (YYYY-MM-DD) |
due_date | string | Yes | Invoice due date (YYYY-MM-DD) |
currency_code | string | Yes | ISO currency code, e.g. USD |
title | string | No | — |
note | string | No | — |
po | string | No | — |
client_id | number | No | — |
status | number | No | — |
tax | number | No | — |
tax2 | number | No | — |
tax3 | number | No | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | No | — |
summary | string | No | — |
invoice_items_attributes | object[] | No | Invoice line items |
invoice_items_attributes full type
invoice_items_attributes full type
{
id?: number,
_destroy?: boolean,
title?: string,
quantity?: number,
price?: number,
taxable?: boolean
}[]
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
title | string | No | — |
date | string | Yes | — |
due_date | string | No | — |
client_id | number | No | — |
note | string | No | — |
po | string | No | — |
status | number | Yes | — |
currency_code | string | Yes | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
balance | number | Yes | — |
total_payments | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
summary | string | No | — |
invoice_items | object[] | No | — |
payments | object[] | No | — |
recurring_schedules | object[] | No | — |
invoice_items full type
invoice_items full type
{
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
payments full type
payments full type
{
id: number,
amount: number,
note?: string | null,
received_on: string,
invoice_id?: number | null,
updated_at?: string | null
}[]
recurring_schedules full type
recurring_schedules full type
{
id: number
}[]
delete
invoices.delete
Delete an invoice [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.invoices.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Invoice ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
invoices.get
Get an invoice by ID
Risk: read
await corsair.clientary.api.invoices.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Invoice ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
title | string | No | — |
date | string | Yes | — |
due_date | string | No | — |
client_id | number | No | — |
note | string | No | — |
po | string | No | — |
status | number | Yes | — |
currency_code | string | Yes | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
balance | number | Yes | — |
total_payments | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
summary | string | No | — |
invoice_items | object[] | No | — |
payments | object[] | No | — |
recurring_schedules | object[] | No | — |
invoice_items full type
invoice_items full type
{
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
payments full type
payments full type
{
id: number,
amount: number,
note?: string | null,
received_on: string,
invoice_id?: number | null,
updated_at?: string | null
}[]
recurring_schedules full type
recurring_schedules full type
{
id: number
}[]
list
invoices.list
List invoices
Risk: read
await corsair.clientary.api.invoices.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
updated_since | string | No | Only return invoices updated since this date (YYYY-MM-DD) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
invoices | object[] | Yes | — |
invoices full type
invoices full type
{
id: number,
number?: string | null,
title?: string | null,
date: string,
due_date?: string | null,
client_id?: number | null,
note?: string | null,
po?: string | null,
status: number,
currency_code: string,
subtotal: number,
total_cost: number,
balance: number,
total_payments: number,
tax: number,
tax2: number,
tax3: number,
tax_label?: string | null,
tax2_label?: string | null,
tax3_label?: string | null,
compound_tax: boolean,
summary?: string | null,
invoice_items?: {
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[],
payments?: {
id: number,
amount: number,
note?: string | null,
received_on: string,
invoice_id?: number | null,
updated_at?: string | null
}[],
recurring_schedules?: {
id: number
}[]
}[]
listForClient
invoices.listForClient
List invoices belonging to a client
Risk: read
await corsair.clientary.api.invoices.listForClient({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client ID to scope invoices by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
invoices | object[] | Yes | — |
invoices full type
invoices full type
{
id: number,
number?: string | null,
title?: string | null,
date: string,
due_date?: string | null,
client_id?: number | null,
note?: string | null,
po?: string | null,
status: number,
currency_code: string,
subtotal: number,
total_cost: number,
balance: number,
total_payments: number,
tax: number,
tax2: number,
tax3: number,
tax_label?: string | null,
tax2_label?: string | null,
tax3_label?: string | null,
compound_tax: boolean,
summary?: string | null,
invoice_items?: {
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[],
payments?: {
id: number,
amount: number,
note?: string | null,
received_on: string,
invoice_id?: number | null,
updated_at?: string | null
}[],
recurring_schedules?: {
id: number
}[]
}[]
listForProject
invoices.listForProject
List invoices belonging to a project
Risk: read
await corsair.clientary.api.invoices.listForProject({});
| Name | Type | Required | Description |
|---|---|---|---|
project_id | number | Yes | Project ID to scope invoices by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
invoices | object[] | Yes | — |
invoices full type
invoices full type
{
id: number,
number?: string | null,
title?: string | null,
date: string,
due_date?: string | null,
client_id?: number | null,
note?: string | null,
po?: string | null,
status: number,
currency_code: string,
subtotal: number,
total_cost: number,
balance: number,
total_payments: number,
tax: number,
tax2: number,
tax3: number,
tax_label?: string | null,
tax2_label?: string | null,
tax3_label?: string | null,
compound_tax: boolean,
summary?: string | null,
invoice_items?: {
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[],
payments?: {
id: number,
amount: number,
note?: string | null,
received_on: string,
invoice_id?: number | null,
updated_at?: string | null
}[],
recurring_schedules?: {
id: number
}[]
}[]
listForRecurring
invoices.listForRecurring
List invoices generated by a recurring schedule
Risk: read
await corsair.clientary.api.invoices.listForRecurring({});
| Name | Type | Required | Description |
|---|---|---|---|
recurring_id | number | Yes | Recurring schedule ID to scope invoices by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
invoices | object[] | Yes | — |
invoices full type
invoices full type
{
id: number,
number?: string | null,
title?: string | null,
date: string,
due_date?: string | null,
client_id?: number | null,
note?: string | null,
po?: string | null,
status: number,
currency_code: string,
subtotal: number,
total_cost: number,
balance: number,
total_payments: number,
tax: number,
tax2: number,
tax3: number,
tax_label?: string | null,
tax2_label?: string | null,
tax3_label?: string | null,
compound_tax: boolean,
summary?: string | null,
invoice_items?: {
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[],
payments?: {
id: number,
amount: number,
note?: string | null,
received_on: string,
invoice_id?: number | null,
updated_at?: string | null
}[],
recurring_schedules?: {
id: number
}[]
}[]
send
invoices.send
Send an invoice via email
Risk: write
await corsair.clientary.api.invoices.send({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Estimate ID to send |
recipients | string[] | Yes | Recipient email addresses |
subject | string | No | Email subject line |
message | string | No | Email body message |
send_copy | boolean | number | No | Send a copy to the sending user |
attach_pdf | boolean | number | No | Attach a PDF of the estimate |
| Name | Type | Required | Description |
|---|---|---|---|
sent | true | Yes | — |
id | number | Yes | — |
update
invoices.update
Update an invoice
Risk: write
await corsair.clientary.api.invoices.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Invoice ID |
number | number | No | Invoice number (autoincrements) |
date | string | No | Invoice date (YYYY-MM-DD) |
due_date | string | No | Invoice due date (YYYY-MM-DD) |
currency_code | string | No | ISO currency code, e.g. USD |
title | string | No | — |
note | string | No | — |
po | string | No | — |
client_id | number | No | — |
status | number | No | — |
tax | number | No | — |
tax2 | number | No | — |
tax3 | number | No | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | No | — |
summary | string | No | — |
invoice_items_attributes | object[] | No | Invoice line items |
invoice_items_attributes full type
invoice_items_attributes full type
{
id?: number,
_destroy?: boolean,
title?: string,
quantity?: number,
price?: number,
taxable?: boolean
}[]
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
title | string | No | — |
date | string | Yes | — |
due_date | string | No | — |
client_id | number | No | — |
note | string | No | — |
po | string | No | — |
status | number | Yes | — |
currency_code | string | Yes | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
balance | number | Yes | — |
total_payments | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
summary | string | No | — |
invoice_items | object[] | No | — |
payments | object[] | No | — |
recurring_schedules | object[] | No | — |
invoice_items full type
invoice_items full type
{
id: number,
title: string,
price: number | string,
quantity: number,
taxable?: boolean
}[]
payments full type
payments full type
{
id: number,
amount: number,
note?: string | null,
received_on: string,
invoice_id?: number | null,
updated_at?: string | null
}[]
recurring_schedules full type
recurring_schedules full type
{
id: number
}[]
Leads
create
leads.create
Create a lead
Risk: write
await corsair.clientary.api.leads.create({});
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Client name |
number | string | No | Client number (unique) |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
delete
leads.delete
Delete a lead [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.leads.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Lead ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
leads.get
Get a lead by ID
Risk: read
await corsair.clientary.api.leads.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Lead ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
list
leads.list
List leads
Risk: read
await corsair.clientary.api.leads.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
sort | name | oldest | No | Sort by name or oldest first |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
leads | object[] | Yes | — |
leads full type
leads full type
{
id: number,
number?: string | null,
name: string,
city?: string | null,
address?: string | null,
address_2?: string | null,
zip?: string | null,
country?: string | null,
state?: string | null,
website?: string | null,
description?: string | null,
invoice_extra_fields?: any | null
}[]
update
leads.update
Update a lead
Risk: write
await corsair.clientary.api.leads.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Lead ID |
name | string | No | Client name |
number | string | No | Client number (unique) |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
city | string | No | — |
address | string | No | — |
address_2 | string | No | — |
zip | string | No | — |
country | string | No | — |
state | string | No | — |
website | string | No | — |
description | string | No | — |
invoice_extra_fields | any | No | — |
Payment Profiles
create
paymentProfiles.create
Create a payment profile for a client
Risk: write
await corsair.clientary.api.paymentProfiles.create({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client to attach the payment profile to |
stripe_customer_id | string | Yes | Stripe customer ID |
stripe_source_id | string | Yes | Stripe source ID |
last_four_digits | string | Yes | Last four digits of the card |
name | string | Yes | Cardholder name |
expiration_date | string | Yes | Card expiration date (YYYY-MM-DD) |
card_type | string | No | Card brand, e.g. Visa |
address | string | No | — |
city | string | No | — |
state | string | No | — |
zip | string | No | — |
country | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | Yes | — |
name | string | Yes | — |
gateway | string | Yes | — |
gateway_token | string | No | — |
address | string | No | — |
city | string | No | — |
state | string | No | — |
zip | string | No | — |
country | string | No | — |
expiration_date | string | No | — |
created_at | string | No | — |
updated_at | string | No | — |
delete
paymentProfiles.delete
Delete a payment profile [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.paymentProfiles.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client the payment profile belongs to |
id | number | Yes | Payment profile ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
listForClient
paymentProfiles.listForClient
List payment profiles for a client
Risk: read
await corsair.clientary.api.paymentProfiles.listForClient({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client ID to scope payment profiles by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
payment_profiles | object[] | Yes | — |
payment_profiles full type
payment_profiles full type
{
id: number,
client_id: number,
name: string,
gateway: string,
gateway_token?: string | null,
address?: string | null,
city?: string | null,
state?: string | null,
zip?: string | null,
country?: string | null,
expiration_date?: string | null,
created_at?: string | null,
updated_at?: string | null
}[]
Payments
create
payments.create
Record a payment
Risk: write
await corsair.clientary.api.payments.create({});
| Name | Type | Required | Description |
|---|---|---|---|
invoice_id | number | Yes | Invoice to apply the payment to |
amount | number | No | Payment amount |
note | string | No | Payment note |
payment_profile_id | number | No | Auto-charge this payment profile for the outstanding balance |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
invoice_id | number | Yes | — |
amount | number | Yes | — |
note | string | No | — |
received_on | string | Yes | — |
transaction_id | string | No | — |
transaction_fee_amount | number | No | — |
delete
payments.delete
Delete (void) a payment [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.payments.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
invoice_id | number | Yes | Invoice the payment belongs to |
id | number | Yes | Payment ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
list
payments.list
List payments
Risk: read
await corsair.clientary.api.payments.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
sort | created_at | No | Sort by record creation time |
| Name | Type | Required | Description |
|---|---|---|---|
page_size | number | Yes | — |
page_count | number | Yes | — |
total_count | number | Yes | — |
payments | object[] | Yes | — |
payments full type
payments full type
{
id: number,
invoice_id: number,
amount: number,
note?: string | null,
received_on: string,
transaction_id?: string | null,
transaction_fee_amount?: number | null
}[]
Projects
create
projects.create
Create a project
Risk: write
await corsair.clientary.api.projects.create({});
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Project name |
number | string | No | Project number (unique) |
rate | number | Yes | Hourly rate (or total cost for fixed amount) |
client_id | number | No | — |
description | string | No | — |
status | number | No | — |
budget_type | 0 | 1 | No | 0 = total budgeted hours, 1 = total budgeted amount |
project_type | 0 | 2 | No | 0 = hourly rate, 2 = fixed amount |
budget | number | No | — |
currency_code | string | No | — |
start_date | string | No | Start date (YYYY-MM-DD) |
end_date | string | No | End date (YYYY-MM-DD) |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
description | string | No | — |
status | number | Yes | — |
budget_type | number | Yes | — |
project_type | number | Yes | — |
budget | number | No | — |
rate | number | No | — |
cost | number | No | — |
worked_hours | number | No | — |
unbilled_hours | number | No | — |
currency_code | string | No | — |
start_date | string | No | — |
end_date | string | No | — |
client | object | No | — |
client full type
client full type
{
id: number,
number?: string | null,
name: string,
city?: string | null,
address?: string | null,
address_2?: string | null,
zip?: string | null,
country?: string | null,
state?: string | null,
website?: string | null,
description?: string | null,
invoice_extra_fields?: any | null
}
delete
projects.delete
Delete a project [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.projects.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Project ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
projects.get
Get a project by ID
Risk: read
await corsair.clientary.api.projects.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Project ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
description | string | No | — |
status | number | Yes | — |
budget_type | number | Yes | — |
project_type | number | Yes | — |
budget | number | No | — |
rate | number | No | — |
cost | number | No | — |
worked_hours | number | No | — |
unbilled_hours | number | No | — |
currency_code | string | No | — |
start_date | string | No | — |
end_date | string | No | — |
client | object | No | — |
client full type
client full type
{
id: number,
number?: string | null,
name: string,
city?: string | null,
address?: string | null,
address_2?: string | null,
zip?: string | null,
country?: string | null,
state?: string | null,
website?: string | null,
description?: string | null,
invoice_extra_fields?: any | null
}
list
projects.list
List projects
Risk: read
await corsair.clientary.api.projects.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
filter | all | No | Include closed projects (default: active/billable only) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
projects | object[] | Yes | — |
projects full type
projects full type
{
id: number,
number?: string | null,
name: string,
description?: string | null,
status: number,
budget_type: number,
project_type: number,
budget?: number | null,
rate?: number | null,
cost?: number | null,
worked_hours?: number | null,
unbilled_hours?: number | null,
currency_code?: string | null,
start_date?: string | null,
end_date?: string | null,
client?: {
id: number,
number?: string | null,
name: string,
city?: string | null,
address?: string | null,
address_2?: string | null,
zip?: string | null,
country?: string | null,
state?: string | null,
website?: string | null,
description?: string | null,
invoice_extra_fields?: any | null
} | null
}[]
listForClient
projects.listForClient
List projects belonging to a client
Risk: read
await corsair.clientary.api.projects.listForClient({});
| Name | Type | Required | Description |
|---|---|---|---|
client_id | number | Yes | Client ID to scope projects by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
page_count | number | Yes | — |
page_size | number | Yes | — |
total_count | number | Yes | — |
projects | object[] | Yes | — |
projects full type
projects full type
{
id: number,
number?: string | null,
name: string,
description?: string | null,
status: number,
budget_type: number,
project_type: number,
budget?: number | null,
rate?: number | null,
cost?: number | null,
worked_hours?: number | null,
unbilled_hours?: number | null,
currency_code?: string | null,
start_date?: string | null,
end_date?: string | null,
client?: {
id: number,
number?: string | null,
name: string,
city?: string | null,
address?: string | null,
address_2?: string | null,
zip?: string | null,
country?: string | null,
state?: string | null,
website?: string | null,
description?: string | null,
invoice_extra_fields?: any | null
} | null
}[]
update
projects.update
Update a project
Risk: write
await corsair.clientary.api.projects.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Project ID |
name | string | No | Project name |
number | string | No | Project number (unique) |
rate | number | No | Hourly rate (or total cost for fixed amount) |
client_id | number | No | — |
description | string | No | — |
status | number | No | — |
budget_type | 0 | 1 | No | 0 = total budgeted hours, 1 = total budgeted amount |
project_type | 0 | 2 | No | 0 = hourly rate, 2 = fixed amount |
budget | number | No | — |
currency_code | string | No | — |
start_date | string | No | Start date (YYYY-MM-DD) |
end_date | string | No | End date (YYYY-MM-DD) |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
number | string | No | — |
name | string | Yes | — |
description | string | No | — |
status | number | Yes | — |
budget_type | number | Yes | — |
project_type | number | Yes | — |
budget | number | No | — |
rate | number | No | — |
cost | number | No | — |
worked_hours | number | No | — |
unbilled_hours | number | No | — |
currency_code | string | No | — |
start_date | string | No | — |
end_date | string | No | — |
client | object | No | — |
client full type
client full type
{
id: number,
number?: string | null,
name: string,
city?: string | null,
address?: string | null,
address_2?: string | null,
zip?: string | null,
country?: string | null,
state?: string | null,
website?: string | null,
description?: string | null,
invoice_extra_fields?: any | null
}
Recurring
create
recurring.create
Create a recurring schedule
Risk: write
await corsair.clientary.api.recurring.create({});
| Name | Type | Required | Description |
|---|---|---|---|
number | number | No | Schedule number (autoincrements) |
next_date | string | Yes | Next invoice date (YYYY-MM-DD) |
due_period | number | Yes | Due in N days |
currency_code | string | Yes | ISO currency code, e.g. USD |
time_interval | number | Yes | Frequency (1=weekly … 11=every 4 months) |
client_id | number | Yes | Client billed by this schedule |
title | string | No | — |
note | string | No | — |
status | number | No | — |
action | number | No | 0=send, 1=draft, 2=autobill |
unlimited | boolean | No | — |
occurrences_remaining | number | No | — |
payment_profile_id | number | No | — |
po | string | No | — |
summary | string | No | — |
tax | number | No | — |
tax2 | number | No | — |
tax3 | number | No | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | No | — |
recurring_schedule_items_attributes | object[] | No | Recurring schedule line items |
recurring_schedule_items_attributes full type
recurring_schedule_items_attributes full type
{
id?: number,
_destroy?: boolean,
title?: string,
quantity?: number,
price?: number
}[]
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | Yes | — |
number | string | No | — |
title | string | Yes | — |
note | string | No | — |
status | number | Yes | — |
action | number | Yes | — |
time_interval | number | Yes | — |
due_period | number | Yes | — |
next_date | string | Yes | — |
currency_code | string | Yes | — |
unlimited | boolean | Yes | — |
occurrences_remaining | number | No | — |
payment_profile_id | number | No | — |
po | string | No | — |
summary | string | No | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
updated_at | string | No | — |
client | any | No | — |
recurring_schedule_items | object[] | No | — |
recurring_schedule_items full type
recurring_schedule_items full type
{
id: number,
recurring_schedule_id?: number | null,
title: string,
price?: string | null,
quantity: number,
item_type: number,
taxable??: boolean,
secondary_tax??: boolean,
tertiary_tax??: boolean,
total_tax?: number
}[]
delete
recurring.delete
Delete a recurring schedule [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.recurring.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Recurring schedule ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
recurring.get
Get a recurring schedule by ID
Risk: read
await corsair.clientary.api.recurring.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Recurring schedule ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | Yes | — |
number | string | No | — |
title | string | Yes | — |
note | string | No | — |
status | number | Yes | — |
action | number | Yes | — |
time_interval | number | Yes | — |
due_period | number | Yes | — |
next_date | string | Yes | — |
currency_code | string | Yes | — |
unlimited | boolean | Yes | — |
occurrences_remaining | number | No | — |
payment_profile_id | number | No | — |
po | string | No | — |
summary | string | No | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
updated_at | string | No | — |
client | any | No | — |
recurring_schedule_items | object[] | No | — |
recurring_schedule_items full type
recurring_schedule_items full type
{
id: number,
recurring_schedule_id?: number | null,
title: string,
price?: string | null,
quantity: number,
item_type: number,
taxable??: boolean,
secondary_tax??: boolean,
tertiary_tax??: boolean,
total_tax?: number
}[]
list
recurring.list
List recurring schedules
Risk: read
await corsair.clientary.api.recurring.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
| Name | Type | Required | Description |
|---|---|---|---|
page_size | number | Yes | — |
page_count | number | Yes | — |
total_count | number | Yes | — |
recurring | object[] | Yes | — |
recurring full type
recurring full type
{
id: number,
client_id: number,
number?: string | null,
title: string,
note?: string | null,
status: number,
action: number,
time_interval: number,
due_period: number,
next_date: string,
currency_code: string,
unlimited: boolean,
occurrences_remaining?: number | null,
payment_profile_id?: number | null,
po?: string | null,
summary?: string | null,
subtotal: number,
total_cost: number,
tax: number,
tax2: number,
tax3: number,
tax_label?: string | null,
tax2_label?: string | null,
tax3_label?: string | null,
compound_tax: boolean,
updated_at?: string | null,
client?: any | null,
recurring_schedule_items?: {
id: number,
recurring_schedule_id?: number | null,
title: string,
price?: string | null,
quantity: number,
item_type: number,
taxable??: boolean,
secondary_tax??: boolean,
tertiary_tax??: boolean,
total_tax?: number
}[]
}[]
update
recurring.update
Update a recurring schedule
Risk: write
await corsair.clientary.api.recurring.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Recurring schedule ID |
number | number | No | Schedule number (autoincrements) |
next_date | string | No | Next invoice date (YYYY-MM-DD) |
due_period | number | No | Due in N days |
currency_code | string | No | ISO currency code, e.g. USD |
time_interval | number | No | Frequency (1=weekly … 11=every 4 months) |
client_id | number | No | Client billed by this schedule |
title | string | No | — |
note | string | No | — |
status | number | No | — |
action | number | No | 0=send, 1=draft, 2=autobill |
unlimited | boolean | No | — |
occurrences_remaining | number | No | — |
payment_profile_id | number | No | — |
po | string | No | — |
summary | string | No | — |
tax | number | No | — |
tax2 | number | No | — |
tax3 | number | No | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | No | — |
recurring_schedule_items_attributes | object[] | No | Recurring schedule line items |
recurring_schedule_items_attributes full type
recurring_schedule_items_attributes full type
{
id?: number,
_destroy?: boolean,
title?: string,
quantity?: number,
price?: number
}[]
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | Yes | — |
number | string | No | — |
title | string | Yes | — |
note | string | No | — |
status | number | Yes | — |
action | number | Yes | — |
time_interval | number | Yes | — |
due_period | number | Yes | — |
next_date | string | Yes | — |
currency_code | string | Yes | — |
unlimited | boolean | Yes | — |
occurrences_remaining | number | No | — |
payment_profile_id | number | No | — |
po | string | No | — |
summary | string | No | — |
subtotal | number | Yes | — |
total_cost | number | Yes | — |
tax | number | Yes | — |
tax2 | number | Yes | — |
tax3 | number | Yes | — |
tax_label | string | No | — |
tax2_label | string | No | — |
tax3_label | string | No | — |
compound_tax | boolean | Yes | — |
updated_at | string | No | — |
client | any | No | — |
recurring_schedule_items | object[] | No | — |
recurring_schedule_items full type
recurring_schedule_items full type
{
id: number,
recurring_schedule_id?: number | null,
title: string,
price?: string | null,
quantity: number,
item_type: number,
taxable??: boolean,
secondary_tax??: boolean,
tertiary_tax??: boolean,
total_tax?: number
}[]
Staff
get
staff.get
Get a staff member by ID
Risk: read
await corsair.clientary.api.staff.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Staff user ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
name | string | Yes | — |
email | string | No | — |
title | string | No | — |
phone | string | No | — |
mobile | string | No | — |
ext | string | No | — |
avatar | string | No | — |
list
staff.list
List staff members
Risk: read
await corsair.clientary.api.staff.list({});
| Name | Type | Required | Description |
|---|---|---|---|
staff | object[] | Yes | — |
staff full type
staff full type
{
id: number,
client_id?: number | null,
name: string,
email?: string | null,
title?: string | null,
phone?: string | null,
mobile?: string | null,
ext?: string | null,
avatar?: string | null
}[]
Tasks
create
tasks.create
Create a task
Risk: write
await corsair.clientary.api.tasks.create({});
| Name | Type | Required | Description |
|---|---|---|---|
title | string | Yes | Task title |
description | string | No | — |
project_id | number | No | — |
assignee_id | number | No | — |
due_date | string | No | Due date (YYYY-MM-DD) |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
project_id | number | No | — |
user_id | number | No | — |
assignee_id | number | No | — |
title | string | Yes | — |
description | string | No | — |
complete | boolean | Yes | — |
completed_at | string | No | — |
due_date | string | No | — |
created_at | string | Yes | — |
updated_at | string | Yes | — |
delete
tasks.delete
Delete a task [DESTRUCTIVE]
Risk: destructive
await corsair.clientary.api.tasks.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Task ID |
| Name | Type | Required | Description |
|---|---|---|---|
success | true | Yes | — |
id | number | Yes | — |
get
tasks.get
Get a task by ID
Risk: read
await corsair.clientary.api.tasks.get({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Task ID |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
project_id | number | No | — |
user_id | number | No | — |
assignee_id | number | No | — |
title | string | Yes | — |
description | string | No | — |
complete | boolean | Yes | — |
completed_at | string | No | — |
due_date | string | No | — |
created_at | string | Yes | — |
updated_at | string | Yes | — |
list
tasks.list
List tasks
Risk: read
await corsair.clientary.api.tasks.list({});
| Name | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
total_count | number | Yes | — |
page_count | number | Yes | — |
page_size | number | Yes | — |
tasks | object[] | Yes | — |
tasks full type
tasks full type
{
id: number,
client_id?: number | null,
project_id?: number | null,
user_id?: number | null,
assignee_id?: number | null,
title: string,
description?: string | null,
complete: boolean,
completed_at?: string | null,
due_date?: string | null,
created_at: string,
updated_at: string
}[]
listForProject
tasks.listForProject
List tasks belonging to a project
Risk: read
await corsair.clientary.api.tasks.listForProject({});
| Name | Type | Required | Description |
|---|---|---|---|
project_id | number | Yes | Project ID to scope tasks by |
page | number | No | Page number (starts at 1) |
page_size | number | No | Results per page (max 100) |
| Name | Type | Required | Description |
|---|---|---|---|
total_count | number | Yes | — |
page_count | number | Yes | — |
page_size | number | Yes | — |
tasks | object[] | Yes | — |
tasks full type
tasks full type
{
id: number,
client_id?: number | null,
project_id?: number | null,
user_id?: number | null,
assignee_id?: number | null,
title: string,
description?: string | null,
complete: boolean,
completed_at?: string | null,
due_date?: string | null,
created_at: string,
updated_at: string
}[]
update
tasks.update
Update a task
Risk: write
await corsair.clientary.api.tasks.update({});
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | Task ID |
title | string | No | — |
description | string | No | — |
project_id | number | No | — |
assignee_id | number | No | — |
due_date | string | No | — |
complete | boolean | No | Mark the task complete |
| Name | Type | Required | Description |
|---|---|---|---|
id | number | Yes | — |
client_id | number | No | — |
project_id | number | No | — |
user_id | number | No | — |
assignee_id | number | No | — |
title | string | Yes | — |
description | string | No | — |
complete | boolean | Yes | — |
completed_at | string | No | — |
due_date | string | No | — |
created_at | string | Yes | — |
updated_at | string | Yes | — |