AccountingApi
- Get Aged Creditors
- Get Aged Debtors
- List Attachments
- Delete Attachment
- Download Attachment
- Get Attachment
- Get BalanceSheet
- Create Bill Payment
- List Bill Payments
- Delete Bill Payment
- Get Bill Payment
- Update Bill Payment
- Create Bill
- List Bills
- Delete Bill
- Get Bill
- Update Bill
- Get Company Info
- Create Credit Note
- List Credit Notes
- Delete Credit Note
- Get Credit Note
- Update Credit Note
- Create Customer
- List Customers
- Delete Customer
- Get Customer
- Update Customer
- Create Department
- List Departments
- Delete Department
- Get Department
- Update Department
- Create Expense
- List Expenses
- Delete Expense
- Get Expense
- Update Expense
- Create Invoice Item
- List Invoice Items
- Delete Invoice Item
- Get Invoice Item
- Update Invoice Item
- Create Invoice
- List Invoices
- Delete Invoice
- Get Invoice
- Update Invoice
- Create Journal Entry
- List Journal Entries
- Delete Journal Entry
- Get Journal Entry
- Update Journal Entry
- Create Ledger Account
- List Ledger Accounts
- Delete Ledger Account
- Get Ledger Account
- Update Ledger Account
- Create Location
- List Locations
- Delete Location
- Get Location
- Update Location
- Create Payment
- List Payments
- Delete Payment
- Get Payment
- Update Payment
- Get Profit And Loss
- Create Purchase Order
- List Purchase Orders
- Delete Purchase Order
- Get Purchase Order
- Update Purchase Order
- Create Subsidiary
- List Subsidiaries
- Delete Subsidiary
- Get Subsidiary
- Update Subsidiary
- Create Supplier
- List Suppliers
- Delete Supplier
- Get Supplier
- Update Supplier
- Create Tax Rate
- List Tax Rates
- Delete Tax Rate
- Get Tax Rate
- Update Tax Rate
- Create Tracking Category
- List Tracking Categories
- Delete Tracking Category
- Get Tracking Category
- Update Tracking Category
Method: agedCreditorsOne
accountingApi.agedCreditorsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
filter | AgedReportFilter | Apply filters | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Aged Creditors |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.agedCreditorsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: agedDebtorsOne
accountingApi.agedDebtorsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
filter | AgedReportFilter | Apply filters | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Aged Debtors |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.agedDebtorsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: attachmentsAll
accountingApi.attachmentsAll(body)
Name | Type | Description | Notes |
---|---|---|---|
referenceType | AttachmentReferenceType | The reference type of the document. | |
referenceId | [string] | The reference id of the object to retrieve. | |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Attachments |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
referenceType: 'invoice',
referenceId: '123456'
}
try {
const { data } = await apideck.accounting.attachmentsAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: attachmentsDelete
accountingApi.attachmentsDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
referenceType | AttachmentReferenceType | The reference type of the document. | |
referenceId | [string] | The reference id of the object to retrieve. | |
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Attachments |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
referenceType: 'invoice',
referenceId: '123456',
id: 'id_example'
}
try {
const { data } = await apideck.accounting.attachmentsDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: attachmentsDownload
accountingApi.attachmentsDownload(body)
Name | Type | Description | Notes |
---|---|---|---|
referenceType | AttachmentReferenceType | The reference type of the document. | |
referenceId | [string] | The reference id of the object to retrieve. | |
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Blob
Status code | Description |
---|---|
200 | Attachment Download |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
referenceType: 'invoice',
referenceId: '123456',
id: 'id_example'
}
try {
const { data } = await apideck.accounting.attachmentsDownload(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: attachmentsOne
accountingApi.attachmentsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
referenceType | AttachmentReferenceType | The reference type of the document. | |
referenceId | [string] | The reference id of the object to retrieve. | |
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Attachments |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
referenceType: 'invoice',
referenceId: '123456',
id: 'id_example'
}
try {
const { data } = await apideck.accounting.attachmentsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: balanceSheetOne
accountingApi.balanceSheetOne(body)
Name | Type | Description | Notes |
---|---|---|---|
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
filter | BalanceSheetFilter | Apply filters | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | BalanceSheet |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.balanceSheetOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billPaymentsAdd
accountingApi.billPaymentsAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
billPayment | BillPayment | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Bill Payment created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
billPayment: {
currency: 'USD',
currency_rate: 0.69,
total_amount: 49.99,
reference: '123456',
payment_method: 'cash',
payment_method_reference: '123456',
payment_method_id: '12345',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
transaction_date: '2021-05-01T12:00:00.000Z',
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
company_id: '12345',
reconciled: true,
status: 'authorised',
type: 'accounts_payable',
allocations: [
{
id: '12345',
type: 'bill',
amount: 49.99,
allocation_id: '123456'
}
],
note: 'Some notes about this transaction',
number: '123456',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
display_id: '123456',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.billPaymentsAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billPaymentsAll
accountingApi.billPaymentsAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | PaymentsFilter | Apply filters | (optional) |
sort | PaymentsSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Bill Payments |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.billPaymentsAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billPaymentsDelete
accountingApi.billPaymentsDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Bill Payment deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.billPaymentsDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billPaymentsOne
accountingApi.billPaymentsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Bill Payment |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.billPaymentsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billPaymentsUpdate
accountingApi.billPaymentsUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
billPayment | BillPayment | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Bill Payment updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
billPayment: {
currency: 'USD',
currency_rate: 0.69,
total_amount: 49.99,
reference: '123456',
payment_method: 'cash',
payment_method_reference: '123456',
payment_method_id: '12345',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
transaction_date: '2021-05-01T12:00:00.000Z',
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
company_id: '12345',
reconciled: true,
status: 'authorised',
type: 'accounts_payable',
allocations: [
{
id: '12345',
type: 'bill',
amount: 49.99,
allocation_id: '123456'
}
],
note: 'Some notes about this transaction',
number: '123456',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
display_id: '123456',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.billPaymentsUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billsAdd
accountingApi.billsAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
bill | Bill | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Bill created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
bill: {
bill_number: '10001',
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
company_id: '12345',
currency: 'USD',
currency_rate: 0.69,
tax_inclusive: true,
bill_date: '2020-09-30',
due_date: '2020-10-30',
paid_date: '2020-10-30',
po_number: '90000117',
reference: '123456',
line_items: [
{
row_id: '12345',
code: '120-C',
line_number: 1,
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
type: 'expense_account',
tax_amount: 27500,
total_amount: 27500,
quantity: 1,
unit_price: 27500.5,
unit_of_measure: 'pc.',
discount_percentage: 0.01,
discount_amount: 19.99,
location_id: '1234',
department_id: '1234',
item: {
id: '12344',
code: '120-C',
name: 'Model Y'
},
tax_rate: {
id: '123456',
rate: 10
},
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
row_version: '1-12345'
}
],
terms: 'Net 30 days',
balance: 27500,
deposit: 0,
sub_total: 27500,
total_tax: 2500,
total: 27500,
tax_code: '1234',
notes: 'Some notes about this bill.',
status: 'draft',
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
payment_method: 'cash',
channel: 'email',
language: 'EN',
accounting_by_row: false,
bank_account: {
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
},
discount_percentage: 5.5,
source_document_url: 'https://www.invoicesolution.com/bill/123456',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
row_version: '1-12345',
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
],
accounting_period: '01-24'
}
}
try {
const { data } = await apideck.accounting.billsAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billsAll
accountingApi.billsAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | BillsFilter | Apply filters | (optional) |
sort | BillsSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Bills |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.billsAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billsDelete
accountingApi.billsDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Bill deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.billsDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billsOne
accountingApi.billsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Bill |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.billsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: billsUpdate
accountingApi.billsUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
bill | Bill | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Bill Updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
bill: {
bill_number: '10001',
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
company_id: '12345',
currency: 'USD',
currency_rate: 0.69,
tax_inclusive: true,
bill_date: '2020-09-30',
due_date: '2020-10-30',
paid_date: '2020-10-30',
po_number: '90000117',
reference: '123456',
line_items: [
{
row_id: '12345',
code: '120-C',
line_number: 1,
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
type: 'expense_account',
tax_amount: 27500,
total_amount: 27500,
quantity: 1,
unit_price: 27500.5,
unit_of_measure: 'pc.',
discount_percentage: 0.01,
discount_amount: 19.99,
location_id: '1234',
department_id: '1234',
item: {
id: '12344',
code: '120-C',
name: 'Model Y'
},
tax_rate: {
id: '123456',
rate: 10
},
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
row_version: '1-12345'
}
],
terms: 'Net 30 days',
balance: 27500,
deposit: 0,
sub_total: 27500,
total_tax: 2500,
total: 27500,
tax_code: '1234',
notes: 'Some notes about this bill.',
status: 'draft',
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
payment_method: 'cash',
channel: 'email',
language: 'EN',
accounting_by_row: false,
bank_account: {
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
},
discount_percentage: 5.5,
source_document_url: 'https://www.invoicesolution.com/bill/123456',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
row_version: '1-12345',
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
],
accounting_period: '01-24'
}
}
try {
const { data } = await apideck.accounting.billsUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: companyInfoOne
accountingApi.companyInfoOne(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | CompanyInfo |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.companyInfoOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: creditNotesAdd
accountingApi.creditNotesAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
creditNote | CreditNote | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Credit Note created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
creditNote: {
number: 'OIT00546',
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
company_id: '12345',
currency: 'USD',
currency_rate: 0.69,
tax_inclusive: true,
sub_total: 27500,
total_amount: 49.99,
total_tax: 2500,
tax_code: '1234',
balance: 27500,
remaining_credit: 27500,
status: 'authorised',
reference: '123456',
date_issued: '2021-05-01T12:00:00.000Z',
date_paid: '2021-05-01T12:00:00.000Z',
type: 'accounts_receivable_credit',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
line_items: [
{
id: '12345',
row_id: '12345',
code: '120-C',
line_number: 1,
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
type: 'sales_item',
tax_amount: 27500,
total_amount: 27500,
quantity: 1,
unit_price: 27500.5,
unit_of_measure: 'pc.',
discount_percentage: 0.01,
discount_amount: 19.99,
location_id: '1234',
department_id: '1234',
item: {
id: '12344',
code: '120-C',
name: 'Model Y'
},
tax_rate: {
id: '123456',
rate: 10
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345'
}
],
allocations: [
{
id: '123456',
type: 'invoice',
amount: 49.99,
allocation_id: '123456'
}
],
note: 'Some notes about this credit note',
terms: 'Some terms about this credit note',
billing_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
shipping_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.creditNotesAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: creditNotesAll
accountingApi.creditNotesAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | CreditNotesFilter | Apply filters | (optional) |
sort | CreditNotesSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Credit Notes |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.creditNotesAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: creditNotesDelete
accountingApi.creditNotesDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Credit Note deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.creditNotesDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: creditNotesOne
accountingApi.creditNotesOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Credit Note |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.creditNotesOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: creditNotesUpdate
accountingApi.creditNotesUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
creditNote | CreditNote | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Credit Note updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
creditNote: {
number: 'OIT00546',
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
company_id: '12345',
currency: 'USD',
currency_rate: 0.69,
tax_inclusive: true,
sub_total: 27500,
total_amount: 49.99,
total_tax: 2500,
tax_code: '1234',
balance: 27500,
remaining_credit: 27500,
status: 'authorised',
reference: '123456',
date_issued: '2021-05-01T12:00:00.000Z',
date_paid: '2021-05-01T12:00:00.000Z',
type: 'accounts_receivable_credit',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
line_items: [
{
id: '12345',
row_id: '12345',
code: '120-C',
line_number: 1,
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
type: 'sales_item',
tax_amount: 27500,
total_amount: 27500,
quantity: 1,
unit_price: 27500.5,
unit_of_measure: 'pc.',
discount_percentage: 0.01,
discount_amount: 19.99,
location_id: '1234',
department_id: '1234',
item: {
id: '12344',
code: '120-C',
name: 'Model Y'
},
tax_rate: {
id: '123456',
rate: 10
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345'
}
],
allocations: [
{
id: '123456',
type: 'invoice',
amount: 49.99,
allocation_id: '123456'
}
],
note: 'Some notes about this credit note',
terms: 'Some terms about this credit note',
billing_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
shipping_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.creditNotesUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: customersAdd
accountingApi.customersAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
customer | Customer | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Customers |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
customer: {
display_id: 'EMP00101',
display_name: 'Windsurf Shop',
company_name: 'SpaceX',
company_id: '12345',
title: 'CEO',
first_name: 'Elon',
middle_name: 'D.',
last_name: 'Musk',
suffix: 'Jr.',
individual: true,
project: false,
addresses: [
{
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
],
phone_numbers: [
{
id: '12345',
country_code: '1',
area_code: '323',
number: '111-111-1111',
extension: '105',
type: 'primary'
}
],
emails: [
{
id: '123',
email: 'elon@musk.com',
type: 'primary'
}
],
websites: [
{
id: '12345',
url: 'http://example.com',
type: 'primary'
}
],
bank_accounts: [
{
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
}
],
notes: 'Some notes about this customer',
tax_rate: {
id: '123456',
rate: 10
},
tax_number: 'US123945459',
currency: 'USD',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
parent: {
id: '12345',
name: 'Windsurf Shop'
},
status: 'active',
payment_method: 'cash',
channel: 'email',
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.customersAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: customersAll
accountingApi.customersAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | CustomersFilter | Apply filters | (optional) |
sort | CustomersSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Customers |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.customersAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: customersDelete
accountingApi.customersDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Customers |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.customersDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: customersOne
accountingApi.customersOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Customer |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.customersOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: customersUpdate
accountingApi.customersUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
customer | Customer | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Customers |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
customer: {
display_id: 'EMP00101',
display_name: 'Windsurf Shop',
company_name: 'SpaceX',
company_id: '12345',
title: 'CEO',
first_name: 'Elon',
middle_name: 'D.',
last_name: 'Musk',
suffix: 'Jr.',
individual: true,
project: false,
addresses: [
{
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
],
phone_numbers: [
{
id: '12345',
country_code: '1',
area_code: '323',
number: '111-111-1111',
extension: '105',
type: 'primary'
}
],
emails: [
{
id: '123',
email: 'elon@musk.com',
type: 'primary'
}
],
websites: [
{
id: '12345',
url: 'http://example.com',
type: 'primary'
}
],
bank_accounts: [
{
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
}
],
notes: 'Some notes about this customer',
tax_rate: {
id: '123456',
rate: 10
},
tax_number: 'US123945459',
currency: 'USD',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
parent: {
id: '12345',
name: 'Windsurf Shop'
},
status: 'active',
payment_method: 'cash',
channel: 'email',
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.customersUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: departmentsAdd
accountingApi.departmentsAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
department | AccountingDepartment | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
CreateAccountingDepartmentResponse
Status code | Description |
---|---|
201 | Department |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
department: {
parent_id: '12345',
name: 'Sales',
status: 'active',
subsidiaries: [
{
name: 'SpaceX'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.departmentsAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: departmentsAll
accountingApi.departmentsAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
filter | AccountingDepartmentsFilter | Apply filters | (optional) |
GetAccountingDepartmentsResponse
Status code | Description |
---|---|
200 | Departments |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.departmentsAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: departmentsDelete
accountingApi.departmentsDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
DeleteAccountingDepartmentResponse
Status code | Description |
---|---|
200 | Department deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.departmentsDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: departmentsOne
accountingApi.departmentsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
GetAccountingDepartmentResponse
Status code | Description |
---|---|
200 | Location |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.departmentsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: departmentsUpdate
accountingApi.departmentsUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
department | AccountingDepartment | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
UpdateAccountingDepartmentResponse
Status code | Description |
---|---|
200 | Department |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
department: {
parent_id: '12345',
name: 'Sales',
status: 'active',
subsidiaries: [
{
name: 'SpaceX'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.departmentsUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: expensesAdd
accountingApi.expensesAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
expense | Expense | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Expenses |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
expense: {
number: 'OIT00546',
transaction_date: '2021-05-01T12:00:00.000Z',
account_id: '123456',
customer_id: '12345',
supplier_id: '12345',
company_id: '12345',
department_id: '12345',
payment_type: 'cash',
currency: 'USD',
currency_rate: 0.69,
type: 'expense',
memo: 'For travel expenses incurred on 2024-05-15',
tax_rate: {
id: '123456',
rate: 10
},
total_amount: 275,
line_items: [
{
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
account_id: '123456',
customer_id: '12345',
department_id: '12345',
location_id: '12345',
tax_rate: {
id: '123456',
rate: 10
},
description: 'Travel US.',
total_amount: 275,
billable: true
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.expensesAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: expensesAll
accountingApi.expensesAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
Status code | Description |
---|---|
200 | Expenses |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.expensesAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: expensesDelete
accountingApi.expensesDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Expenses |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.expensesDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: expensesOne
accountingApi.expensesOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Expenses |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.expensesOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: expensesUpdate
accountingApi.expensesUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
expense | Expense | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Expenses |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
expense: {
number: 'OIT00546',
transaction_date: '2021-05-01T12:00:00.000Z',
account_id: '123456',
customer_id: '12345',
supplier_id: '12345',
company_id: '12345',
department_id: '12345',
payment_type: 'cash',
currency: 'USD',
currency_rate: 0.69,
type: 'expense',
memo: 'For travel expenses incurred on 2024-05-15',
tax_rate: {
id: '123456',
rate: 10
},
total_amount: 275,
line_items: [
{
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
account_id: '123456',
customer_id: '12345',
department_id: '12345',
location_id: '12345',
tax_rate: {
id: '123456',
rate: 10
},
description: 'Travel US.',
total_amount: 275,
billable: true
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.expensesUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoiceItemsAdd
accountingApi.invoiceItemsAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
invoiceItem | InvoiceItem | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | InvoiceItems |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
invoiceItem: {
name: 'Model Y',
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
code: '120-C',
sold: true,
purchased: true,
tracked: true,
taxable: true,
inventory_date: '2020-10-30',
type: 'inventory',
sales_details: {
unit_price: 27500.5,
unit_of_measure: 'pc.',
tax_inclusive: true,
tax_rate: {
id: '123456',
rate: 10
}
},
purchase_details: {
unit_price: 27500.5,
unit_of_measure: 'pc.',
tax_inclusive: true,
tax_rate: {
id: '123456',
rate: 10
}
},
quantity: 1,
unit_price: 27500.5,
asset_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
income_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
expense_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
tracking_category: {
id: '123456',
name: 'New York'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
active: true,
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.invoiceItemsAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoiceItemsAll
accountingApi.invoiceItemsAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | InvoiceItemsFilter | Apply filters | (optional) |
sort | InvoiceItemsSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | InvoiceItems |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.invoiceItemsAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoiceItemsDelete
accountingApi.invoiceItemsDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | InvoiceItems |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.invoiceItemsDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoiceItemsOne
accountingApi.invoiceItemsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
filter | InvoiceItemFilter | Apply filters | (optional) |
Status code | Description |
---|---|
200 | InvoiceItems |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.invoiceItemsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoiceItemsUpdate
accountingApi.invoiceItemsUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
invoiceItem | InvoiceItem | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | InvoiceItems |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
invoiceItem: {
name: 'Model Y',
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
code: '120-C',
sold: true,
purchased: true,
tracked: true,
taxable: true,
inventory_date: '2020-10-30',
type: 'inventory',
sales_details: {
unit_price: 27500.5,
unit_of_measure: 'pc.',
tax_inclusive: true,
tax_rate: {
id: '123456',
rate: 10
}
},
purchase_details: {
unit_price: 27500.5,
unit_of_measure: 'pc.',
tax_inclusive: true,
tax_rate: {
id: '123456',
rate: 10
}
},
quantity: 1,
unit_price: 27500.5,
asset_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
income_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
expense_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
tracking_category: {
id: '123456',
name: 'New York'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
active: true,
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.invoiceItemsUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoicesAdd
accountingApi.invoicesAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
invoice | Invoice | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Invoice created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
invoice: {
type: 'service',
number: 'OIT00546',
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
company_id: '12345',
invoice_date: '2020-09-30',
due_date: '2020-09-30',
terms: 'Net 30 days',
po_number: '90000117',
reference: '123456',
status: 'draft',
invoice_sent: true,
currency: 'USD',
currency_rate: 0.69,
tax_inclusive: true,
sub_total: 27500,
total_tax: 2500,
tax_code: '1234',
discount_percentage: 5.5,
discount_amount: 25,
total: 27500,
balance: 27500,
deposit: 0,
customer_memo: 'Thank you for your business and have a great day!',
tracking_category: {
id: '123456',
name: 'New York'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
line_items: [
{
id: '12345',
row_id: '12345',
code: '120-C',
line_number: 1,
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
type: 'sales_item',
tax_amount: 27500,
total_amount: 27500,
quantity: 1,
unit_price: 27500.5,
unit_of_measure: 'pc.',
discount_percentage: 0.01,
discount_amount: 19.99,
location_id: '1234',
department_id: '1234',
item: {
id: '12344',
code: '120-C',
name: 'Model Y'
},
tax_rate: {
id: '123456',
rate: 10
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345'
}
],
billing_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
shipping_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
template_id: '123456',
source_document_url: 'https://www.invoicesolution.com/invoice/123456',
payment_method: 'cash',
channel: 'email',
language: 'EN',
accounting_by_row: false,
bank_account: {
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
},
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.invoicesAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoicesAll
accountingApi.invoicesAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | InvoicesFilter | Apply filters | (optional) |
sort | InvoicesSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Invoices |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.invoicesAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoicesDelete
accountingApi.invoicesDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Invoice deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.invoicesDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoicesOne
accountingApi.invoicesOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Invoice |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.invoicesOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: invoicesUpdate
accountingApi.invoicesUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
invoice | Invoice | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Invoice updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
invoice: {
type: 'service',
number: 'OIT00546',
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
company_id: '12345',
invoice_date: '2020-09-30',
due_date: '2020-09-30',
terms: 'Net 30 days',
po_number: '90000117',
reference: '123456',
status: 'draft',
invoice_sent: true,
currency: 'USD',
currency_rate: 0.69,
tax_inclusive: true,
sub_total: 27500,
total_tax: 2500,
tax_code: '1234',
discount_percentage: 5.5,
discount_amount: 25,
total: 27500,
balance: 27500,
deposit: 0,
customer_memo: 'Thank you for your business and have a great day!',
tracking_category: {
id: '123456',
name: 'New York'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
line_items: [
{
id: '12345',
row_id: '12345',
code: '120-C',
line_number: 1,
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
type: 'sales_item',
tax_amount: 27500,
total_amount: 27500,
quantity: 1,
unit_price: 27500.5,
unit_of_measure: 'pc.',
discount_percentage: 0.01,
discount_amount: 19.99,
location_id: '1234',
department_id: '1234',
item: {
id: '12344',
code: '120-C',
name: 'Model Y'
},
tax_rate: {
id: '123456',
rate: 10
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345'
}
],
billing_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
shipping_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
template_id: '123456',
source_document_url: 'https://www.invoicesolution.com/invoice/123456',
payment_method: 'cash',
channel: 'email',
language: 'EN',
accounting_by_row: false,
bank_account: {
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
},
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.invoicesUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: journalEntriesAdd
accountingApi.journalEntriesAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
journalEntry | JournalEntry | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | JournalEntries |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
journalEntry: {
title: 'Purchase Invoice-Inventory (USD): 2019/02/01 Batch Summary Entry',
currency_rate: 0.69,
currency: 'USD',
company_id: '12345',
line_items: [
{
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
tax_amount: 27500,
sub_total: 27500,
total_amount: 27500,
type: 'debit',
tax_rate: {
id: '123456',
rate: 10
},
tracking_category: {
id: '123456',
name: 'New York'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
line_number: 1
},
{
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
tax_amount: 27500,
sub_total: 27500,
total_amount: 27500,
type: 'debit',
tax_rate: {
id: '123456',
rate: 10
},
tracking_category: {
id: '123456',
name: 'New York'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
line_number: 1
}
],
memo: 'Thank you for your business and have a great day!',
posted_at: '2020-09-30T07:43:32.000Z',
journal_symbol: 'IND',
tax_type: 'sales',
tax_code: '1234',
number: 'OIT00546',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
accounting_period: '01-24',
row_version: '1-12345',
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.journalEntriesAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: journalEntriesAll
accountingApi.journalEntriesAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | JournalEntriesFilter | Apply filters | (optional) |
sort | JournalEntriesSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | JournalEntry |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.journalEntriesAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: journalEntriesDelete
accountingApi.journalEntriesDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | JournalEntries |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.journalEntriesDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: journalEntriesOne
accountingApi.journalEntriesOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | JournalEntries |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.journalEntriesOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: journalEntriesUpdate
accountingApi.journalEntriesUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
journalEntry | JournalEntry | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | JournalEntries |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
journalEntry: {
title: 'Purchase Invoice-Inventory (USD): 2019/02/01 Batch Summary Entry',
currency_rate: 0.69,
currency: 'USD',
company_id: '12345',
line_items: [
{
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
tax_amount: 27500,
sub_total: 27500,
total_amount: 27500,
type: 'debit',
tax_rate: {
id: '123456',
rate: 10
},
tracking_category: {
id: '123456',
name: 'New York'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
line_number: 1
},
{
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
tax_amount: 27500,
sub_total: 27500,
total_amount: 27500,
type: 'debit',
tax_rate: {
id: '123456',
rate: 10
},
tracking_category: {
id: '123456',
name: 'New York'
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
line_number: 1
}
],
memo: 'Thank you for your business and have a great day!',
posted_at: '2020-09-30T07:43:32.000Z',
journal_symbol: 'IND',
tax_type: 'sales',
tax_code: '1234',
number: 'OIT00546',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
accounting_period: '01-24',
row_version: '1-12345',
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.journalEntriesUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: ledgerAccountsAdd
accountingApi.ledgerAccountsAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
ledgerAccount | LedgerAccount | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | LedgerAccount created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
ledgerAccount: {
display_id: '1-12345',
nominal_code: 'N091',
code: '453',
classification: 'asset',
type: 'bank',
sub_type: 'CHECKING_ACCOUNT',
name: 'Bank account',
fully_qualified_name: 'Asset.Bank.Checking_Account',
description: 'Main checking account',
opening_balance: 75000,
current_balance: 20000,
currency: 'USD',
tax_type: 'NONE',
tax_rate: {
id: '123456',
rate: 10
},
level: 1,
active: true,
status: 'active',
header: true,
bank_account: {
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
},
parent_account: {
id: '12345',
name: 'Bank Accounts',
display_id: '1-1100'
},
sub_account: false,
last_reconciliation_date: '2020-09-30',
subsidiaries: [
{
id: 'string'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.ledgerAccountsAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: ledgerAccountsAll
accountingApi.ledgerAccountsAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | LedgerAccountsFilter | Apply filters | (optional) |
sort | LedgerAccountsSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | LedgerAccounts |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.ledgerAccountsAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: ledgerAccountsDelete
accountingApi.ledgerAccountsDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | LedgerAccount deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.ledgerAccountsDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: ledgerAccountsOne
accountingApi.ledgerAccountsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | LedgerAccount |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.ledgerAccountsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: ledgerAccountsUpdate
accountingApi.ledgerAccountsUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
ledgerAccount | LedgerAccount | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | LedgerAccount updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
ledgerAccount: {
display_id: '1-12345',
nominal_code: 'N091',
code: '453',
classification: 'asset',
type: 'bank',
sub_type: 'CHECKING_ACCOUNT',
name: 'Bank account',
fully_qualified_name: 'Asset.Bank.Checking_Account',
description: 'Main checking account',
opening_balance: 75000,
current_balance: 20000,
currency: 'USD',
tax_type: 'NONE',
tax_rate: {
id: '123456',
rate: 10
},
level: 1,
active: true,
status: 'active',
header: true,
bank_account: {
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
},
parent_account: {
id: '12345',
name: 'Bank Accounts',
display_id: '1-1100'
},
sub_account: false,
last_reconciliation_date: '2020-09-30',
subsidiaries: [
{
id: 'string'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.ledgerAccountsUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: locationsAdd
accountingApi.locationsAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
location | AccountingLocation | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
CreateAccountingLocationResponse
Status code | Description |
---|---|
201 | Location |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
location: {
parent_id: '12345',
company_name: 'SpaceX',
display_name: '11 UT - South Jordan',
status: 'active',
addresses: [
{
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
],
subsidiaries: [
{
name: 'SpaceX'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.locationsAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: locationsAll
accountingApi.locationsAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
filter | AccountingLocationsFilter | Apply filters | (optional) |
GetAccountingLocationsResponse
Status code | Description |
---|---|
200 | Locations |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.locationsAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: locationsDelete
accountingApi.locationsDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
DeleteAccountingLocationResponse
Status code | Description |
---|---|
200 | Location deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.locationsDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: locationsOne
accountingApi.locationsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Location |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.locationsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: locationsUpdate
accountingApi.locationsUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
location | AccountingLocation | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
UpdateAccountingLocationResponse
Status code | Description |
---|---|
200 | Location |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
location: {
parent_id: '12345',
company_name: 'SpaceX',
display_name: '11 UT - South Jordan',
status: 'active',
addresses: [
{
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
],
subsidiaries: [
{
name: 'SpaceX'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.locationsUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: paymentsAdd
accountingApi.paymentsAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
payment | Payment | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Payment created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
payment: {
currency: 'USD',
currency_rate: 0.69,
total_amount: 49.99,
reference: '123456',
payment_method: 'cash',
payment_method_reference: '123456',
payment_method_id: '12345',
accounts_receivable_account_type: 'Account',
accounts_receivable_account_id: '123456',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
transaction_date: '2021-05-01T12:00:00.000Z',
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
supplier: {
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
company_id: '12345',
reconciled: true,
status: 'authorised',
type: 'accounts_receivable',
allocations: [
{
id: '123456',
type: 'invoice',
amount: 49.99,
allocation_id: '123456'
}
],
note: 'Some notes about this transaction',
number: '123456',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
display_id: '123456',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.paymentsAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: paymentsAll
accountingApi.paymentsAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | PaymentsFilter | Apply filters | (optional) |
sort | PaymentsSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Payments |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.paymentsAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: paymentsDelete
accountingApi.paymentsDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Payment deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.paymentsDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: paymentsOne
accountingApi.paymentsOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Payment |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.paymentsOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: paymentsUpdate
accountingApi.paymentsUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
payment | Payment | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Payment Updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
payment: {
currency: 'USD',
currency_rate: 0.69,
total_amount: 49.99,
reference: '123456',
payment_method: 'cash',
payment_method_reference: '123456',
payment_method_id: '12345',
accounts_receivable_account_type: 'Account',
accounts_receivable_account_id: '123456',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
transaction_date: '2021-05-01T12:00:00.000Z',
customer: {
id: '12345',
display_name: 'Windsurf Shop',
name: 'Windsurf Shop',
email: 'boring@boring.com'
},
supplier: {
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
company_id: '12345',
reconciled: true,
status: 'authorised',
type: 'accounts_receivable',
allocations: [
{
id: '123456',
type: 'invoice',
amount: 49.99,
allocation_id: '123456'
}
],
note: 'Some notes about this transaction',
number: '123456',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
display_id: '123456',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.paymentsUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: profitAndLossOne
accountingApi.profitAndLossOne(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
filter | ProfitAndLossFilter | Apply filters | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Profit & Loss Report |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.profitAndLossOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: purchaseOrdersAdd
accountingApi.purchaseOrdersAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
purchaseOrder | PurchaseOrder | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | PurchaseOrders |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
purchaseOrder: {
po_number: '90000117',
reference: '123456',
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
company_id: '12345',
status: 'open',
issued_date: '2020-09-30',
delivery_date: '2020-09-30',
expected_arrival_date: '2020-09-30',
currency: 'USD',
currency_rate: 0.69,
sub_total: 27500,
total_tax: 2500,
total: 27500,
tax_inclusive: true,
line_items: [
{
id: '12345',
row_id: '12345',
code: '120-C',
line_number: 1,
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
type: 'sales_item',
tax_amount: 27500,
total_amount: 27500,
quantity: 1,
unit_price: 27500.5,
unit_of_measure: 'pc.',
discount_percentage: 0.01,
discount_amount: 19.99,
location_id: '1234',
department_id: '1234',
item: {
id: '12344',
code: '120-C',
name: 'Model Y'
},
tax_rate: {
id: '123456',
rate: 10
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345'
}
],
shipping_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
template_id: '123456',
discount_percentage: 5.5,
bank_account: {
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
},
accounting_by_row: false,
due_date: '2020-10-30',
payment_method: 'cash',
tax_code: '1234',
channel: 'email',
memo: 'Thank you for the partnership and have a great day!',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.purchaseOrdersAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: purchaseOrdersAll
accountingApi.purchaseOrdersAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | PurchaseOrdersFilter | Apply filters | (optional) |
sort | PurchaseOrdersSort | Apply sorting | (optional) |
Status code | Description |
---|---|
200 | PurchaseOrders |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.purchaseOrdersAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: purchaseOrdersDelete
accountingApi.purchaseOrdersDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | PurchaseOrders |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.purchaseOrdersDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: purchaseOrdersOne
accountingApi.purchaseOrdersOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | PurchaseOrders |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.purchaseOrdersOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: purchaseOrdersUpdate
accountingApi.purchaseOrdersUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
purchaseOrder | PurchaseOrder | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | PurchaseOrders |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
purchaseOrder: {
po_number: '90000117',
reference: '123456',
supplier: {
id: '12345',
display_name: 'Windsurf Shop',
address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
},
company_id: '12345',
status: 'open',
issued_date: '2020-09-30',
delivery_date: '2020-09-30',
expected_arrival_date: '2020-09-30',
currency: 'USD',
currency_rate: 0.69,
sub_total: 27500,
total_tax: 2500,
total: 27500,
tax_inclusive: true,
line_items: [
{
id: '12345',
row_id: '12345',
code: '120-C',
line_number: 1,
description: 'Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection.',
type: 'sales_item',
tax_amount: 27500,
total_amount: 27500,
quantity: 1,
unit_price: 27500.5,
unit_of_measure: 'pc.',
discount_percentage: 0.01,
discount_amount: 19.99,
location_id: '1234',
department_id: '1234',
item: {
id: '12344',
code: '120-C',
name: 'Model Y'
},
tax_rate: {
id: '123456',
rate: 10
},
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345'
}
],
shipping_address: {
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
},
ledger_account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
template_id: '123456',
discount_percentage: 5.5,
bank_account: {
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
},
accounting_by_row: false,
due_date: '2020-10-30',
payment_method: 'cash',
tax_code: '1234',
channel: 'email',
memo: 'Thank you for the partnership and have a great day!',
tracking_categories: [
{
id: '123456',
name: 'New York'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.purchaseOrdersUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: subsidiariesAdd
accountingApi.subsidiariesAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
subsidiary | Subsidiary | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Subsidiaries |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
subsidiary: {
parent_id: '12345',
name: 'SpaceX',
status: 'active',
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.subsidiariesAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: subsidiariesAll
accountingApi.subsidiariesAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Subsidiaries |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.subsidiariesAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: subsidiariesDelete
accountingApi.subsidiariesDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Subsidiarys |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.subsidiariesDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: subsidiariesOne
accountingApi.subsidiariesOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Subsidiary |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.subsidiariesOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: subsidiariesUpdate
accountingApi.subsidiariesUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
subsidiary | Subsidiary | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Subsidiaries |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
subsidiary: {
parent_id: '12345',
name: 'SpaceX',
status: 'active',
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
]
}
}
try {
const { data } = await apideck.accounting.subsidiariesUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: suppliersAdd
accountingApi.suppliersAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
supplier | Supplier | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | Supplier created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
supplier: {
display_id: 'EMP00101',
display_name: 'Windsurf Shop',
company_name: 'SpaceX',
company_id: '12345',
title: 'CEO',
first_name: 'Elon',
middle_name: 'D.',
last_name: 'Musk',
suffix: 'Jr.',
individual: true,
addresses: [
{
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
],
phone_numbers: [
{
id: '12345',
country_code: '1',
area_code: '323',
number: '111-111-1111',
extension: '105',
type: 'primary'
}
],
emails: [
{
id: '123',
email: 'elon@musk.com',
type: 'primary'
}
],
websites: [
{
id: '12345',
url: 'http://example.com',
type: 'primary'
}
],
bank_accounts: [
{
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
}
],
notes: 'Some notes about this supplier',
tax_rate: {
id: '123456',
rate: 10
},
tax_number: 'US123945459',
currency: 'USD',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
status: 'active',
payment_method: 'cash',
channel: 'email',
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
],
subsidiary_id: '12345'
}
}
try {
const { data } = await apideck.accounting.suppliersAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: suppliersAll
accountingApi.suppliersAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | SuppliersFilter | Apply filters | (optional) |
sort | SuppliersSort | Apply sorting | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Suppliers |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.suppliersAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: suppliersDelete
accountingApi.suppliersDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Supplier deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.suppliersDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: suppliersOne
accountingApi.suppliersOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Supplier |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.suppliersOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: suppliersUpdate
accountingApi.suppliersUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
supplier | Supplier | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | Supplier updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
supplier: {
display_id: 'EMP00101',
display_name: 'Windsurf Shop',
company_name: 'SpaceX',
company_id: '12345',
title: 'CEO',
first_name: 'Elon',
middle_name: 'D.',
last_name: 'Musk',
suffix: 'Jr.',
individual: true,
addresses: [
{
id: '123',
type: 'primary',
string: '25 Spring Street, Blackburn, VIC 3130',
name: 'HQ US',
line1: 'Main street',
line2: 'apt #',
line3: 'Suite #',
line4: 'delivery instructions',
street_number: '25',
city: 'San Francisco',
state: 'CA',
postal_code: '94104',
country: 'US',
latitude: '40.759211',
longitude: '-73.984638',
county: 'Santa Clara',
contact_name: 'Elon Musk',
salutation: 'Mr',
phone_number: '111-111-1111',
fax: '122-111-1111',
email: 'elon@musk.com',
website: 'https://elonmusk.com',
notes: 'Address notes or delivery instructions.',
row_version: '1-12345'
}
],
phone_numbers: [
{
id: '12345',
country_code: '1',
area_code: '323',
number: '111-111-1111',
extension: '105',
type: 'primary'
}
],
emails: [
{
id: '123',
email: 'elon@musk.com',
type: 'primary'
}
],
websites: [
{
id: '12345',
url: 'http://example.com',
type: 'primary'
}
],
bank_accounts: [
{
bank_name: 'Monzo',
account_number: '123465',
account_name: 'SPACEX LLC',
account_type: 'credit_card',
iban: 'CH2989144532982975332',
bic: 'AUDSCHGGXXX',
routing_number: '012345678',
bsb_number: '062-001',
branch_identifier: '001',
bank_code: 'BNH',
currency: 'USD'
}
],
notes: 'Some notes about this supplier',
tax_rate: {
id: '123456',
rate: 10
},
tax_number: 'US123945459',
currency: 'USD',
account: {
id: '123456',
nominal_code: 'N091',
code: '453'
},
status: 'active',
payment_method: 'cash',
channel: 'email',
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
],
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
],
subsidiary_id: '12345'
}
}
try {
const { data } = await apideck.accounting.suppliersUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: taxRatesAdd
accountingApi.taxRatesAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
taxRate | TaxRate | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
Status code | Description |
---|---|
201 | TaxRate created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
taxRate: {
id: '1234',
name: 'GST on Purchases',
code: 'ABN',
description: 'Reduced rate GST Purchases',
effective_tax_rate: 10,
total_tax_rate: 10,
tax_payable_account_id: '123456',
tax_remitted_account_id: '123456',
components: [
{
id: '10',
name: 'GST',
rate: 10,
compound: true
}
],
type: 'NONE',
report_tax_type: 'NONE',
original_tax_rate_id: '12345',
status: 'active',
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
],
subsidiaries: [
{
id: 'string'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
]
}
}
try {
const { data } = await apideck.accounting.taxRatesAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: taxRatesAll
accountingApi.taxRatesAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
filter | TaxRatesFilter | Apply filters | (optional) |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | TaxRates |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.taxRatesAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: taxRatesDelete
accountingApi.taxRatesDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | TaxRates deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.taxRatesDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: taxRatesOne
accountingApi.taxRatesOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | TaxRate |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.taxRatesOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: taxRatesUpdate
accountingApi.taxRatesUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
taxRate | TaxRate | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
Status code | Description |
---|---|
200 | TaxRate updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
taxRate: {
id: '1234',
name: 'GST on Purchases',
code: 'ABN',
description: 'Reduced rate GST Purchases',
effective_tax_rate: 10,
total_tax_rate: 10,
tax_payable_account_id: '123456',
tax_remitted_account_id: '123456',
components: [
{
id: '10',
name: 'GST',
rate: 10,
compound: true
}
],
type: 'NONE',
report_tax_type: 'NONE',
original_tax_rate_id: '12345',
status: 'active',
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
],
subsidiaries: [
{
id: 'string'
}
],
custom_fields: [
{
id: '2389328923893298',
name: 'employee_level',
description: 'Employee Level',
value: 'Uses Salesforce and Marketo'
}
]
}
}
try {
const { data } = await apideck.accounting.taxRatesUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: trackingCategoriesAdd
accountingApi.trackingCategoriesAdd(body)
Name | Type | Description | Notes |
---|---|---|---|
trackingCategory | TrackingCategory | ||
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
CreateTrackingCategoryResponse
Status code | Description |
---|---|
201 | Tracking category created |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
trackingCategory: {
parent_id: '12345',
name: 'Department',
code: '100',
status: 'active',
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
],
subsidiaries: [
{
id: 'string'
}
]
}
}
try {
const { data } = await apideck.accounting.trackingCategoriesAdd(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: trackingCategoriesAll
accountingApi.trackingCategoriesAll(body)
Name | Type | Description | Notes |
---|---|---|---|
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
cursor | [string] | Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. | (optional) |
limit | [number] | Number of results to return. Minimum 1, Maximum 200, Default 20 | (optional) defaults to 20 |
passThrough | PassThroughQuery | Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads | (optional) |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Tracking categories |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {}
try {
const { data } = await apideck.accounting.trackingCategoriesAll(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: trackingCategoriesDelete
accountingApi.trackingCategoriesDelete(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
DeleteTrackingCategoryResponse
Status code | Description |
---|---|
200 | Tracking category deleted |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.trackingCategoriesDelete(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: trackingCategoriesOne
accountingApi.trackingCategoriesOne(body)
Name | Type | Description | Notes |
---|---|---|---|
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
fields | [string] | The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. Example: `fields=name,email,addresses.city` In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded. |
(optional) |
Status code | Description |
---|---|
200 | Tracking category |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example'
}
try {
const { data } = await apideck.accounting.trackingCategoriesOne(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}
[Back to top] [Back to API list] [Back to README]
Method: trackingCategoriesUpdate
accountingApi.trackingCategoriesUpdate(body)
Name | Type | Description | Notes |
---|---|---|---|
trackingCategory | TrackingCategory | ||
id | [string] | ID of the record you are acting upon. | |
consumerId | [string] | ID of the consumer which you want to get or push data from | (optional) |
appId | [string] | The ID of your Unify application | (optional) |
serviceId | [string] | Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. | (optional) |
raw | [boolean] | Include raw response. Mostly used for debugging purposes | (optional) defaults to false |
UpdateTrackingCategoryResponse
Status code | Description |
---|---|
200 | Tracking category updated |
400 | Bad Request |
401 | Unauthorized |
402 | Payment Required |
404 | The specified resource was not found |
422 | Unprocessable |
4/5xx | Unexpected error |
import { Apideck } from '@apideck/node';
const apideck = new Apideck({
apiKey: 'REPLACE_WITH_API_KEY',
appId: 'REPLACE_WITH_APP_ID',
consumerId: 'REPLACE_WITH_CONSUMER_ID'
});
const params = {
id: 'id_example',
trackingCategory: {
parent_id: '12345',
name: 'Department',
code: '100',
status: 'active',
row_version: '1-12345',
pass_through: [
{
service_id: 'string',
operation_id: 'string',
extend_object: {},
extend_paths: [
{
path: '$.nested.property',
value: [Object]
}
]
}
],
subsidiaries: [
{
id: 'string'
}
]
}
}
try {
const { data } = await apideck.accounting.trackingCategoriesUpdate(params)
console.log('API called successfully', data)
} catch (error) {
console.error(error)
return error.json()
}