openapi: 3.0.3 info: version: 10.8.1 title: Accounting API description: "Welcome to the Accounting API.\n\nYou can use this API to access all Accounting API endpoints.\n\n## Base URL\n\nThe base URL for all API requests is `https://unify.apideck.com`\n\n## Headers\n\nCustom headers that are expected as part of the request. Note that [RFC7230](https://tools.ietf.org/html/rfc7230) states header names are case insensitive.\n\n| Name | Type | Required | Description |\n| --------------------- | ------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| x-apideck-consumer-id | String | Yes | The id of the customer stored inside Apideck Vault. This can be a user id, account id, device id or whatever entity that can have integration within your app. |\n| x-apideck-service-id | String | No | Describe the service you want to call (e.g., pipedrive). Only needed when a customer has activated multiple integrations for the same Unified API. |\n| x-apideck-raw | Boolean | No | Include raw response. Mostly used for debugging purposes. |\n| x-apideck-app-id | String | Yes | The application id of your Unify application. Available at https://app.apideck.com/unify/api-keys. |\n| Authorization | String | Yes | Bearer API KEY |\n\n## Authorization\n\nYou can interact with the API through the authorization methods below.\n\n\n\n## Pagination\n\nAll API resources have support for bulk retrieval via list APIs. Apideck uses cursor-based pagination via the optional `cursor` and `limit` parameters.\n\nTo fetch the first page of results, call the list API without a `cursor` parameter. Afterwards you can fetch subsequent pages by providing a cursor parameter. You will find the next cursor in the response body in `meta.cursors.next`. If `meta.cursors.next` is `null` you're at the end of the list.\n\nIn the REST API you can also use the `links` from the response for added convenience. Simply call the URL in `links.next` to get the next page of results.\n\n### Query Parameters\n\n| Name | Type | Required | Description |\n| ------ | ------ | -------- | ------------------------------------------------------------------------------------------------------------------ |\n| cursor | String | No | Cursor to start from. You can find cursors for next & previous pages in the meta.cursors property of the response. |\n| limit | Number | No | Number of results to return. Minimum 1, Maximum 200, Default 20 |\n\n### Response Body\n\n| Name | Type | Description |\n| --------------------- | ------ | ------------------------------------------------------------------ |\n| meta.cursors.previous | String | Cursor to navigate to the previous page of results through the API |\n| meta.cursors.current | String | Cursor to navigate to the current page of results through the API |\n| meta.cursors.next | String | Cursor to navigate to the next page of results through the API |\n| meta.items_on_page | Number | Number of items returned in the data property of the response |\n| links.previous | String | Link to navigate to the previous page of results through the API |\n| links.current | String | Link to navigate to the current page of results through the API |\n| links.next | String | Link to navigate to the next page of results through the API |\n\n⚠️ `meta.cursors.previous`/`links.previous` is not available for all connectors.\n\n## SDKs and API Clients\n\nWe currently offer a [Node.js](https://developers.apideck.com/sdks/node), [PHP](https://developers.apideck.com/sdks/php), [Python](https://developers.apideck.com/sdks/python) and [.NET](https://developers.apideck.com/sdks/dot-net) SDK.\nNeed another SDK? [Request the SDK of your choice](https://requests.apideck.io/request).\n\n## Debugging\n\nBecause of the nature of the abstraction we do in Apideck Unify we still provide the option to the receive raw requests and responses being handled underlying. By including the raw flag `?raw=true` in your requests you can still receive the full request. Please note that this increases the response size and can introduce extra latency.\n\n## Errors\n\nThe API returns standard HTTP response codes to indicate success or failure of the API requests. For errors, we also return a customized error message inside the JSON response. You can see the returned HTTP status codes below.\n\n| Code | Title | Description |\n| ---- | -------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| 200 | OK | The request message has been successfully processed, and it has produced a response. The response message varies, depending on the request method and the requested data. |\n| 201 | Created | The request has been fulfilled and has resulted in one or more new resources being created. |\n| 204 | No Content | The server has successfully fulfilled the request and that there is no additional content to send in the response payload body. |\n| 400 | Bad Request | The receiving server cannot understand the request because of malformed syntax. Do not repeat the request without first modifying it; check the request for errors, fix them and then retry the request. |\n| 401 | Unauthorized | The request has not been applied because it lacks valid authentication credentials for the target resource. |\n| 402 | Payment Required | Subscription data is incomplete or out of date. You'll need to provide payment details to continue. |\n| 403 | Forbidden | You do not have the appropriate user rights to access the request. Do not repeat the request. |\n| 404 | Not Found | The origin server did not find a current representation for the target resource or is not willing to disclose that one exists. |\n| 409 | Conflict | The request could not be completed due to a conflict with the current state of the target resource. |\n| 422 | Unprocessable Entity | The server understands the content type of the request entity, and the syntax of the request entity is correct but was unable to process the contained instructions. |\n| 429 | Too Many Requests | You sent too many requests in a given amount of time (\"rate limit\"). Try again later |\n| 5xx | Server Errors | Something went wrong with the Unify API. These errors are logged on our side. You can contact our team to resolve the issue. |\n\n### Handling errors\n\nThe Unify API and SDKs can produce errors for many reasons, such as a failed requests due to misconfigured integrations, invalid parameters, authentication errors, and network unavailability.\n\n### Error Types\n\n#### RequestValidationError\n\nRequest is not valid for the current endpoint. The response body will include details on the validation error. Check the spelling and types of your attributes, and ensure you are not passing data that is outside of the specification.\n\n#### UnsupportedFiltersError\n\nFilters in the request are valid, but not supported by the connector. Remove the unsupported filter(s) to get a successful response.\n\n#### UnsupportedSortFieldError\n\nSort field (`sort[by]`) in the request is valid, but not supported by the connector. Replace or remove the sort field to get a successful response.\n\n#### InvalidCursorError\n\nPagination cursor in the request is not valid for the current connector. Make sure to use a cursor returned from the API, for the same connector.\n\n#### ConnectorExecutionError\n\nA Unified API request made via one of our downstream connectors returned an unexpected error. The `status_code` returned is proxied through to error response along with their original response via the error detail.\n\n#### UnauthorizedError\n\nWe were unable to authorize the request as made. This can happen for a number of reasons, from missing header params to passing an incorrect authorization token. Verify your Api Key is being set correctly in the authorization header. ie: `Authorization: 'Bearer sk_live_***'`\n\n#### ConnectorCredentialsError\n\nA request using a given connector has not been authorized. Ensure the connector you are trying to use has been configured correctly and been authorized for use.\n\n#### ConnectorDisabledError\n\nA request has been made to a connector that has since been disabled. This may be temporary - You can contact our team to resolve the issue.\n\n#### ConnectorRateLimitError\n\nYou sent too many request to a connector. These rate limits vary from connector to connector. You will need to try again later.\n\n#### RequestLimitError\n\nYou have reached the number of requests included in your Free Tier Subscription. You will not be able to make further requests until you upgrade your subscription. Please reach out to sales@apideck.com to continue making requests.\n\n#### EntityNotFoundError\n\nYou've made a request for a resource or route that does not exist. Verify your path parameters or any identifiers used to fetch this resource.\n\n#### OAuthCredentialsNotFoundError\n\nWhen adding a connector integration that implements OAuth, both a `client_id` and `client_secret` must be provided before any authorizations can be performed. Verify the integration has been configured properly before continuing.\n\n#### IntegrationNotFoundError\n\nThe requested connector integration could not be found associated to your `application_id`. Verify your `application_id` is correct, and that this connector has been added and configured for your application.\n\n#### ConnectionNotFoundError\n\nA valid connection could not be found associated to your `application_id`. Something _may_ have interrupted the authorization flow. You may need to start the connector authorization process again.\n\n#### ConnectionSettingsError\n\nThe connector has required settings that were not supplied. Verify `connection.settings` contains all required settings for the connector to be callable.\n\n#### ConnectorNotFoundError\n\nA request was made for an unknown connector. Verify your `service_id` is spelled correctly, and that this connector is enabled for your provided `unified_api`.\n\n#### OAuthRedirectUriError\n\nA request was made either in a connector authorization flow, or attempting to revoke connector access without a valid `redirect_uri`. This is the url the user should be returned to on completion of process.\n\n#### OAuthInvalidStateError\n\nThe state param is required and is used to ensure the outgoing authorization state has not been altered before the user is redirected back. It also contains required params needed to identify the connector being used. If this has been altered, the authorization will not succeed.\n\n#### OAuthCodeExchangeError\n\nWhen attempting to exchange the authorization code for an `access_token` during an OAuth flow, an error occurred. This may be temporary. You can reattempt authorization or contact our team to resolve the issue.\n\n#### OAuthConnectorError\n\nIt seems something went wrong on the connector side. It's possible this connector is in `beta` or still under development. We've been notified and are working to fix this issue.\n\n#### MappingError\n\nThere was an error attempting to retrieve the mapping for a given attribute. We've been notified and are working to fix this issue.\n\n#### ConnectorMappingNotFoundError\n\nIt seems the implementation for this connector is incomplete. It's possible this connector is in `beta` or still under development. We've been notified and are working to fix this issue.\n\n#### ConnectorResponseMappingNotFoundError\n\nWe were unable to retrieve the response mapping for this connector. It's possible this connector is in `beta` or still under development. We've been notified and are working to fix this issue.\n\n#### ConnectorOperationMappingNotFoundError\n\nConnector mapping has not been implemented for the requested operation. It's possible this connector is in `beta` or still under development. We've been notified and are working to fix this issue.\n\n#### ConnectorWorkflowMappingError\n\nThe composite api calls required for this operation have not been mapped entirely. It's possible this connector is in `beta` or still under development. We've been notified and are working to fix this issue.\n\n#### ConnectorOperationUnsupportedError\n\nYou're attempting a call that is not supported by the connector. It's likely this operation is supported by another connector, but we're unable to implement for this one.\n\n#### PaginationNotSupportedError\n\nPagination is not yet supported for this connector, try removing limit and/or cursor from the query. It's possible this connector is in `beta` or still under development. We've been notified and are working to fix this issue.\n\n## API Design\n\n### API Styles and data formats\n\n#### REST API\n\nThe API is organized around [REST](https://restfulapi.net/), providing simple and predictable URIs to access and modify objects. Requests support standard HTTP methods like GET, PUT, POST, and DELETE and standard status codes. JSON is returned by all API responses, including errors. In all API requests, you must set the content-type HTTP header to application/json. All API requests must be made over HTTPS. Calls made over HTTP will fail.\n\n##### Available HTTP methods\n\nThe Apideck API uses HTTP verbs to understand if you want to read (GET), delete (DELETE) or create (POST) an object. When your web application cannot do a POST or DELETE, we provide the ability to set the method through the query parameter \\_method.\n\n```\nPOST /messages\nGET /messages\nGET /messages/{messageId}\nPATCH /messages/{messageId}\nDELETE /messages/{messageId}\n```\n\nResponse bodies are always UTF-8 encoded JSON objects, unless explicitly documented otherwise. For some endpoints and use cases we divert from REST to provide a better developer experience.\n\n### Schema\n\nAll API requests and response bodies adhere to a common JSON format representing individual items, collections of items, links to related items and additional meta data.\n\n### Meta\n\nMeta data can be represented as a top level member named “meta”. Any information may be provided in the meta data. It’s most common use is to return the total number of records when requesting a collection of resources.\n\n### Request IDs\n\nEach API request has an associated request identifier. You can find this value in the response headers, under Request-Id. You can also find request identifiers in the URLs of individual request logs in your Dashboard. If you need to contact us about a specific request, providing the request identifier will ensure the fastest possible resolution.\n\n### Fixed field types\n\n#### Dates\n\nThe dates returned by the API are all represented in UTC (ISO8601 format).\n\nThis example\_`2019-11-14T00:55:31.820Z`\_is defined by the\_ISO 8601\_standard. The\_T\_in the middle separates the year-month-day portion from the hour-minute-second portion. The\_Z\_on the end means UTC, that is, an offset-from-UTC of zero hours-minutes-seconds. The\_Z\_is pronounced \"Zulu\" per military/aviation tradition.\n\nThe ISO 8601 standard is more modern. The formats are wisely designed to be easy to parse by machine as well as easy to read by humans across cultures.\n\n#### Prices and Currencies\n\nAll prices returned by the API are represented as integer amounts in a currency’s smallest unit. For example, $5 USD would be returned as 500 (i.e, 500 cents).\n\nFor zero-decimal currencies, amounts will still be provided as an integer but without the need to divide by 100. For example, an amount of ¥5 (JPY) would be returned as 5.\n\nAll currency codes conform to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217).\n\n## Support\n\nIf you have problems or need help with your case, you can always reach out to our Support.\n\n## Static IP\n\nSome of the APIs you want to use can require a static IP. Apideck's static IP feature allows you to use Apideck with a fixed IP avoiding the need for you to set up your own infrastructure. This feature is currently available to all Apideck customers.\nTo use this feature, the API Vendor will need to whitelist the associated static IP addresses.\nThe provided static IP addresses are fixed to their specified region and shared by all customers who use this feature.\n\n- EU Central 1: **18.197.244.247**, **18.156.9.3**, **3.65.139.215**\n- Other: upcoming\n\n More info about our data security can be found at [https://compliance.apideck.com/](https://compliance.apideck.com/)\n\n" contact: email: hello@apideck.com url: https://developers.apideck.com x-logo: url: https://developers.apideck.com/icon.png x-apideck-api: accounting x-apideck-sdk-support: true license: name: Apache 2.0 url: http://www.apache.org/licenses/LICENSE-2.0.html externalDocs: description: Apideck Developer Docs url: https://developers.apideck.com servers: - url: https://unify.apideck.com components: parameters: applicationId: name: x-apideck-app-id in: header required: true description: The ID of your Unify application schema: type: string example: dSBdXd2H6Mqwfg0atXHXYcysLJE9qyn1VwBtXHX x-speakeasy-name-override: appId x-speakeasy-globals-hidden: true balanceSheetFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/BalanceSheetFilter' billsFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/BillsFilter' billsSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/BillsSort' consumerId: name: x-apideck-consumer-id in: header required: true description: ID of the consumer which you want to get or push data from schema: type: string example: test-consumer x-speakeasy-name-override: consumerId x-speakeasy-globals-hidden: true cursor: name: cursor in: query description: Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response. schema: type: string nullable: true creditNotesFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/CreditNotesFilter' creditNotesSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/CreditNotesSort' customersFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/CustomersFilter' customersSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/CustomersSort' fields: name: fields in: query description: '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.' example: id,updated_at schema: type: string nullable: true id: in: path name: id schema: type: string required: true description: ID of the record you are acting upon. invoiceItemsFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/InvoiceItemsFilter' invoiceItemFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/InvoiceItemFilter' invoicesFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/InvoicesFilter' invoicesSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/InvoicesSort' journalEntriesFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/JournalEntriesFilter' journalEntriesSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/JournalEntriesSort' ledgerAccountsFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/LedgerAccountsFilter' ledgerAccountsSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/LedgerAccountsSort' limit: name: limit in: query description: Number of results to return. Minimum 1, Maximum 200, Default 20 schema: type: integer minimum: 1 maximum: 200 default: 20 passThrough: name: pass_through in: query description: 'Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads' style: deepObject explode: true schema: $ref: '#/components/schemas/PassThroughQuery' paymentsFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/PaymentsFilter' paymentsSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/PaymentsSort' profitAndLossFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/ProfitAndLossFilter' purchaseOrdersFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/PurchaseOrdersFilter' purchaseOrdersSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/PurchaseOrdersSort' raw: name: raw in: query description: Include raw response. Mostly used for debugging purposes schema: type: boolean default: false serviceId: name: x-apideck-service-id in: header description: Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API. schema: type: string example: salesforce x-speakeasy-name-override: serviceId suppliersFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/SuppliersFilter' suppliersSort: name: sort in: query description: Apply sorting style: deepObject explode: true schema: $ref: '#/components/schemas/SuppliersSort' taxRatesFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/TaxRatesFilter' accountingDepartmentsFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/AccountingDepartmentsFilter' accountingLocationsFilter: name: filter in: query description: Apply filters style: deepObject explode: true schema: $ref: '#/components/schemas/AccountingLocationsFilter' referenceType: in: path name: reference_type schema: $ref: '#/components/schemas/AttachmentReferenceType' required: true description: The reference type of the document. example: invoice referenceId: in: path name: reference_id schema: $ref: '#/components/schemas/Id' required: true description: The reference id of the object to retrieve. example: '123456' attachmentMetadata: name: x-apideck-metadata in: header description: Metadata to attach to the attachment file required: true content: application/json: schema: $ref: '#/components/schemas/CreateAttachmentRequest' contentType: name: content-type in: header description: The content-type of the file being uploaded required: true schema: type: string responses: BadRequestResponse: content: application/json: schema: $ref: '#/components/schemas/BadRequestResponse' description: Bad Request CompanyInfo: content: application/json: schema: $ref: '#/components/schemas/CompanyInfo' description: Company Info CreateBillResponse: content: application/json: schema: $ref: '#/components/schemas/CreateBillResponse' description: Bill created CreateCreditNoteResponse: content: application/json: schema: $ref: '#/components/schemas/CreateCreditNoteResponse' description: Credit Note created CreateCustomerResponse: content: application/json: schema: $ref: '#/components/schemas/CreateCustomerResponse' description: Customers CreateInvoiceItemResponse: content: application/json: schema: $ref: '#/components/schemas/CreateInvoiceItemResponse' description: InvoiceItems CreateInvoiceResponse: content: application/json: schema: $ref: '#/components/schemas/CreateInvoiceResponse' description: Invoice created CreateLedgerAccountResponse: content: application/json: schema: $ref: '#/components/schemas/CreateLedgerAccountResponse' description: LedgerAccount created CreatePaymentResponse: content: application/json: schema: $ref: '#/components/schemas/CreatePaymentResponse' description: Payment created CreateSupplierResponse: content: application/json: schema: $ref: '#/components/schemas/CreateSupplierResponse' description: Supplier created CreateTaxRateResponse: content: application/json: schema: $ref: '#/components/schemas/CreateTaxRateResponse' description: TaxRate created DeleteBillResponse: content: application/json: schema: $ref: '#/components/schemas/DeleteBillResponse' description: Bill deleted DeleteCreditNoteResponse: content: application/json: schema: $ref: '#/components/schemas/DeleteCreditNoteResponse' description: Credit Note deleted DeleteCustomerResponse: content: application/json: schema: $ref: '#/components/schemas/DeleteCustomerResponse' description: Customers DeleteInvoiceItemResponse: content: application/json: schema: $ref: '#/components/schemas/DeleteTaxRateResponse' description: InvoiceItems DeleteInvoiceResponse: content: application/json: schema: $ref: '#/components/schemas/DeleteInvoiceResponse' description: Invoice deleted DeleteLedgerAccountResponse: content: application/json: schema: $ref: '#/components/schemas/DeleteLedgerAccountResponse' description: LedgerAccount deleted DeletePaymentResponse: content: application/json: schema: $ref: '#/components/schemas/DeletePaymentResponse' description: Payment deleted DeleteSupplierResponse: content: application/json: schema: $ref: '#/components/schemas/DeleteSupplierResponse' description: Supplier deleted DeleteTaxRateResponse: content: application/json: schema: $ref: '#/components/schemas/DeleteTaxRateResponse' description: TaxRates deleted GetBalanceSheetResponse: content: application/json: schema: $ref: '#/components/schemas/GetBalanceSheetResponse' description: BalanceSheet GetBillResponse: content: application/json: schema: $ref: '#/components/schemas/GetBillResponse' description: Bill GetBillsResponse: content: application/json: schema: $ref: '#/components/schemas/GetBillsResponse' description: Bills GetCompanyInfoResponse: content: application/json: schema: $ref: '#/components/schemas/GetCompanyInfoResponse' description: CompanyInfo GetCreditNoteResponse: content: application/json: schema: $ref: '#/components/schemas/GetCreditNoteResponse' description: Credit Note GetCreditNotesResponse: content: application/json: schema: $ref: '#/components/schemas/GetCreditNotesResponse' description: Credit Notes GetCustomerResponse: content: application/json: schema: $ref: '#/components/schemas/GetCustomerResponse' description: Customer GetCustomersResponse: content: application/json: schema: $ref: '#/components/schemas/GetCustomersResponse' description: Customers GetInvoiceItemResponse: content: application/json: schema: $ref: '#/components/schemas/GetInvoiceItemResponse' description: InvoiceItems GetInvoiceItemsResponse: content: application/json: schema: $ref: '#/components/schemas/GetInvoiceItemsResponse' description: InvoiceItems GetInvoiceResponse: content: application/json: schema: $ref: '#/components/schemas/GetInvoiceResponse' description: Invoice GetInvoicesResponse: content: application/json: schema: $ref: '#/components/schemas/GetInvoicesResponse' description: Invoices GetLedgerAccountResponse: content: application/json: schema: $ref: '#/components/schemas/GetLedgerAccountResponse' description: LedgerAccount GetLedgerAccountsResponse: content: application/json: schema: $ref: '#/components/schemas/GetLedgerAccountsResponse' description: LedgerAccounts GetPaymentResponse: content: application/json: schema: $ref: '#/components/schemas/GetPaymentResponse' description: Payment GetPaymentsResponse: content: application/json: schema: $ref: '#/components/schemas/GetPaymentsResponse' description: Payments CreateSubsidiaryResponse: description: Subsidiaries content: application/json: schema: $ref: '#/components/schemas/CreateSubsidiaryResponse' DeleteSubsidiaryResponse: description: Subsidiarys content: application/json: schema: $ref: '#/components/schemas/DeleteSubsidiaryResponse' GetSubsidiariesResponse: content: application/json: schema: $ref: '#/components/schemas/GetSubsidiariesResponse' description: Subsidiaries GetSubsidiaryResponse: content: application/json: schema: $ref: '#/components/schemas/GetSubsidiaryResponse' description: Subsidiary GetAccountingLocationsResponse: content: application/json: schema: $ref: '#/components/schemas/GetAccountingLocationsResponse' description: Locations GetAccountingLocationResponse: content: application/json: schema: $ref: '#/components/schemas/GetAccountingLocationResponse' description: Location CreateAccountingLocationResponse: description: Location content: application/json: schema: $ref: '#/components/schemas/CreateAccountingLocationResponse' UpdateAccountingLocationResponse: description: Location content: application/json: schema: $ref: '#/components/schemas/UpdateAccountingLocationResponse' DeleteAccountingLocationResponse: description: Location deleted content: application/json: schema: $ref: '#/components/schemas/DeleteAccountingLocationResponse' GetAccountingDepartmentsResponse: content: application/json: schema: $ref: '#/components/schemas/GetAccountingDepartmentsResponse' description: Departments GetAccountingDepartmentResponse: content: application/json: schema: $ref: '#/components/schemas/GetAccountingDepartmentResponse' description: Location CreateAccountingDepartmentResponse: description: Department content: application/json: schema: $ref: '#/components/schemas/CreateAccountingDepartmentResponse' UpdateAccountingDepartmentResponse: description: Department content: application/json: schema: $ref: '#/components/schemas/UpdateAccountingDepartmentResponse' DeleteAccountingDepartmentResponse: description: Department deleted content: application/json: schema: $ref: '#/components/schemas/DeleteAccountingDepartmentResponse' UpdateSubsidiaryResponse: description: Subsidiaries content: application/json: schema: $ref: '#/components/schemas/UpdateSubsidiaryResponse' GetSupplierResponse: content: application/json: schema: $ref: '#/components/schemas/GetSupplierResponse' description: Supplier GetSuppliersResponse: content: application/json: schema: $ref: '#/components/schemas/GetSuppliersResponse' description: Suppliers GetTaxRateResponse: content: application/json: schema: $ref: '#/components/schemas/GetTaxRateResponse' description: TaxRate GetTaxRatesResponse: content: application/json: schema: $ref: '#/components/schemas/GetTaxRatesResponse' description: TaxRates NotFoundResponse: content: application/json: schema: $ref: '#/components/schemas/NotFoundResponse' description: The specified resource was not found NotImplementedResponse: content: application/json: schema: $ref: '#/components/schemas/NotImplementedResponse' description: Not Implemented PaymentRequiredResponse: content: application/json: schema: $ref: '#/components/schemas/PaymentRequiredResponse' description: Payment Required TooManyRequestsResponse: content: application/json: schema: $ref: '#/components/schemas/TooManyRequestsResponse' description: Too Many Requests UnauthorizedResponse: content: application/json: schema: $ref: '#/components/schemas/UnauthorizedResponse' description: Unauthorized UnexpectedErrorResponse: content: application/json: schema: $ref: '#/components/schemas/UnexpectedErrorResponse' description: Unexpected error UnprocessableResponse: content: application/json: schema: $ref: '#/components/schemas/UnprocessableResponse' description: Unprocessable UpdateBillResponse: content: application/json: schema: $ref: '#/components/schemas/UpdateBillResponse' description: Bill Updated UpdateCreditNoteResponse: content: application/json: schema: $ref: '#/components/schemas/UpdateCreditNoteResponse' description: Credit Note updated UpdateCustomerResponse: content: application/json: schema: $ref: '#/components/schemas/UpdateCustomerResponse' description: Customers UpdateInvoiceItemResponse: content: application/json: schema: $ref: '#/components/schemas/UpdateInvoiceItemsResponse' description: InvoiceItems UpdateInvoiceResponse: content: application/json: schema: $ref: '#/components/schemas/UpdateInvoiceResponse' description: Invoice updated UpdateLedgerAccountResponse: content: application/json: schema: $ref: '#/components/schemas/UpdateLedgerAccountResponse' description: LedgerAccount updated UpdatePaymentResponse: content: application/json: schema: $ref: '#/components/schemas/UpdatePaymentResponse' description: Payment Updated UpdateSupplierResponse: content: application/json: schema: $ref: '#/components/schemas/UpdateSupplierResponse' description: Supplier updated UpdateTaxRateResponse: content: application/json: schema: $ref: '#/components/schemas/UpdateTaxRateResponse' description: TaxRate updated GetProfitAndLossResponse: content: application/json: schema: $ref: '#/components/schemas/GetProfitAndLossResponse' description: Profit & Loss Report CreateJournalEntryResponse: description: JournalEntries content: application/json: schema: $ref: '#/components/schemas/CreateJournalEntryResponse' DeleteJournalEntryResponse: description: JournalEntries content: application/json: schema: $ref: '#/components/schemas/DeleteJournalEntryResponse' GetJournalEntryResponse: description: JournalEntries content: application/json: schema: $ref: '#/components/schemas/GetJournalEntryResponse' GetJournalEntriesResponse: description: JournalEntry content: application/json: schema: $ref: '#/components/schemas/GetJournalEntriesResponse' JournalEntry: description: JournalEntries content: application/json: schema: $ref: '#/components/schemas/JournalEntry' UpdateJournalEntryResponse: description: JournalEntries content: application/json: schema: $ref: '#/components/schemas/UpdateJournalEntryResponse' CreatePurchaseOrderResponse: description: PurchaseOrders content: application/json: schema: $ref: '#/components/schemas/CreatePurchaseOrderResponse' DeletePurchaseOrderResponse: description: PurchaseOrders content: application/json: schema: $ref: '#/components/schemas/DeletePurchaseOrderResponse' GetPurchaseOrderResponse: description: PurchaseOrders content: application/json: schema: $ref: '#/components/schemas/GetPurchaseOrderResponse' GetPurchaseOrdersResponse: description: PurchaseOrders content: application/json: schema: $ref: '#/components/schemas/GetPurchaseOrdersResponse' PurchaseOrder: description: PurchaseOrders content: application/json: schema: $ref: '#/components/schemas/PurchaseOrder' UpdatePurchaseOrderResponse: description: PurchaseOrders content: application/json: schema: $ref: '#/components/schemas/UpdatePurchaseOrderResponse' GetAttachmentsResponse: description: Attachments content: application/json: schema: $ref: '#/components/schemas/GetAttachmentsResponse' CreateAttachmentResponse: description: Attachments content: application/json: schema: $ref: '#/components/schemas/CreateAttachmentResponse' DeleteAttachmentResponse: description: Attachments content: application/json: schema: $ref: '#/components/schemas/DeleteAttachmentResponse' GetAttachmentResponse: description: Attachments content: application/json: schema: $ref: '#/components/schemas/GetAttachmentResponse' GetAttachmentDownloadResponse: description: Attachment Download content: '*/*': schema: type: string format: binary GetTrackingCategoriesResponse: description: Tracking categories content: application/json: schema: $ref: '#/components/schemas/GetTrackingCategoriesResponse' GetTrackingCategoryResponse: description: Tracking category content: application/json: schema: $ref: '#/components/schemas/GetTrackingCategoryResponse' CreateTrackingCategoryResponse: description: Tracking category created content: application/json: schema: $ref: '#/components/schemas/CreateTrackingCategoryResponse' UpdateTrackingCategoryResponse: description: Tracking category updated content: application/json: schema: $ref: '#/components/schemas/UpdateTrackingCategoryResponse' DeleteTrackingCategoryResponse: description: Tracking category deleted content: application/json: schema: $ref: '#/components/schemas/DeleteTrackingCategoryResponse' GetBillPaymentsResponse: description: Bill Payments content: application/json: schema: $ref: '#/components/schemas/GetBillPaymentsResponse' GetBillPaymentResponse: description: Bill Payment content: application/json: schema: $ref: '#/components/schemas/GetBillPaymentResponse' CreateBillPaymentResponse: description: Bill Payment created content: application/json: schema: $ref: '#/components/schemas/CreateBillPaymentResponse' UpdateBillPaymentResponse: description: Bill Payment updated content: application/json: schema: $ref: '#/components/schemas/UpdateBillPaymentResponse' DeleteBillPaymentResponse: description: Bill Payment deleted content: application/json: schema: $ref: '#/components/schemas/DeleteBillPaymentResponse' CreateExpenseResponse: description: Expenses content: application/json: schema: $ref: '#/components/schemas/CreateExpenseResponse' DeleteExpenseResponse: description: Expenses content: application/json: schema: $ref: '#/components/schemas/DeleteExpenseResponse' GetExpenseResponse: description: Expenses content: application/json: schema: $ref: '#/components/schemas/GetExpenseResponse' GetExpensesResponse: description: Expenses content: application/json: schema: $ref: '#/components/schemas/GetExpensesResponse' UpdateExpenseResponse: description: Expenses content: application/json: schema: $ref: '#/components/schemas/UpdateExpenseResponse' schemas: AccountCode: title: Account Code description: The account code of the account type: string example: '1100' readOnly: true AccountId: title: Account Id description: The unique identifier for the account. type: string example: '123456' readOnly: true AccountName: title: Account Name description: The name of the account. type: string example: Current assets readOnly: true Amount: title: Amount description: The amount or value of the item type: number example: 1000 readOnly: true AccountingByRow: type: boolean title: Accounting by Row description: Indicates if accounting by row is used (true) or not (false). Accounting by row means that a separate ledger transaction is created for each row. nullable: true example: false AccountingCustomer: $ref: '#/components/schemas/Customer' AccountingEventType: type: string x-apideck-enum-id: accounting.events enum: - '*' - accounting.customer.created - accounting.customer.updated - accounting.customer.deleted - accounting.invoice.created - accounting.invoice.updated - accounting.invoice.deleted - accounting.invoice_item.created - accounting.invoice_item.updated - accounting.invoice_item.deleted - accounting.ledger_account.created - accounting.ledger_account.updated - accounting.ledger_account.deleted - accounting.tax_rate.created - accounting.tax_rate.updated - accounting.tax_rate.deleted - accounting.bill.created - accounting.bill.updated - accounting.bill.deleted - accounting.payment.created - accounting.payment.updated - accounting.payment.deleted - accounting.supplier.created - accounting.supplier.updated - accounting.supplier.deleted - accounting.purchase_order.created - accounting.purchase_order.updated - accounting.purchase_order.deleted - accounting.expense.created - accounting.expense.updated - accounting.expense.deleted AccountingWebhookEvent: x-sdk-exclude: true allOf: - type: object x-apideck-schema-id: WebhookEvent properties: event_id: type: string description: Unique reference to this request event example: 9755c355-56c3-4a2f-a2da-86ff4411fccb unified_api: description: Name of Apideck Unified API x-apideck-enum-id: unified_api enum: - accounting - ats - calendar - crm - csp - customer-support - ecommerce - email - email-marketing - expense-management - file-storage - form - hris - lead - payroll - pos - procurement - project-management - script - sms - spreadsheet - team-messaging - issue-tracking - time-registration - transactional-email - vault - data-warehouse example: crm type: string service_id: type: string description: Service provider identifier example: close consumer_id: type: string example: test_consumer_id description: Unique consumer identifier. You can freely choose a consumer ID yourself. Most of the time, this is an ID of your internal data model that represents a user or account in your system (for example account:12345). If the consumer doesn't exist yet, Vault will upsert a consumer based on your ID. entity_id: type: string description: The service provider's ID of the entity that triggered this event example: 123456ASDF entity_type: type: string description: The type entity that triggered this event example: Company entity_url: type: string description: The url to retrieve entity detail. example: https://unify.apideck.com/crm/contacts/123456 execution_attempt: type: number description: The current count this request event has been attempted example: 2 occurred_at: type: string description: ISO Datetime for when the original event occurred example: '2021-10-01T03:14:55.419Z' - type: object properties: event_type: $ref: '#/components/schemas/AccountingEventType' Active: type: boolean title: Is active example: true nullable: true Address: type: object x-apideck-schema-id: Address additionalProperties: false x-apideck-weights: id: edge-case name: edge-case type: critical line1: high line2: low line3: edge-case line4: edge-case street_number: low city: high string: low state: high postal_code: high country: high latitude: low longitude: low county: edge-case contact_name: edge-case salutation: edge-case phone_number: edge-case fax: edge-case email: edge-case website: edge-case row_version: edge-case properties: id: description: Unique identifier for the address. type: string example: '123' nullable: true type: type: string description: The type of address. x-apideck-enum-id: addresses.type enum: - primary - secondary - home - office - shipping - billing - other example: primary nullable: true string: type: string description: The address string. Some APIs don't provide structured address data. example: 25 Spring Street, Blackburn, VIC 3130 nullable: true name: description: The name of the address. type: string example: HQ US nullable: true line1: type: string example: Main street description: 'Line 1 of the address e.g. number, street, suite, apt #, etc.' nullable: true line2: type: string example: 'apt #' description: Line 2 of the address nullable: true line3: type: string example: 'Suite #' description: Line 3 of the address nullable: true line4: type: string example: delivery instructions description: Line 4 of the address nullable: true street_number: type: string example: '25' description: Street number nullable: true city: type: string example: San Francisco description: Name of city. nullable: true state: type: string example: CA description: Name of state nullable: true postal_code: type: string example: '94104' description: Zip code or equivalent. nullable: true country: type: string example: US description: country code according to ISO 3166-1 alpha-2. nullable: true latitude: description: Latitude of the address type: string example: '40.759211' nullable: true longitude: description: Longitude of the address type: string example: '-73.984638' nullable: true county: type: string example: Santa Clara description: Address field that holds a sublocality, such as a county nullable: true contact_name: description: Name of the contact person at the address type: string example: Elon Musk nullable: true salutation: description: Salutation of the contact person at the address type: string example: Mr nullable: true phone_number: description: Phone number of the address type: string example: 111-111-1111 nullable: true fax: description: Fax number of the address type: string example: 122-111-1111 nullable: true email: description: Email address of the address type: string example: elon@musk.com nullable: true website: description: Website of the address type: string example: https://elonmusk.com nullable: true notes: description: Additional notes type: string title: Notes example: Address notes or delivery instructions. nullable: true row_version: $ref: '#/components/schemas/RowVersion' BadRequestResponse: type: object x-apideck-schema-id: BadRequest properties: status_code: type: number description: HTTP status code example: 400 error: type: string description: Contains an explanation of the status_code as defined in HTTP/1.1 standard (RFC 7231) example: Bad Request type_name: type: string description: The type of error returned example: RequestValidationError message: type: string description: A human-readable message providing more details about the error. example: Invalid Params x-speakeasy-error-message: true detail: anyOf: - type: string example: Missing property foobar - type: object additionalProperties: true example: missing: - foobar: required description: Contains parameter or domain specific information related to the error and why it occurred. ref: type: string description: Link to documentation of error type example: https://developers.apideck.com/errors#requestvalidationerror BalanceSheet: type: object x-apideck-schema-id: BalanceSheet x-apideck-circular-ref: true x-apideck-weights: reports: critical additionalProperties: false required: - reports properties: reports: type: array x-apideck-schema-id: BalanceSheetReports items: type: object x-apideck-schema-id: BalanceSheetReport x-apideck-weights: id: medium report_name: medium start_date: medium end_date: critical currency: medium assets: critical liabilities: critical equity: critical net_assets: high custom_mappings: edge-case updated_by: edge-case created_by: edge-case updated_at: low created_at: edge-case uncategorized_items: edge-case additionalProperties: false required: - end_date - assets - liabilities - equity properties: id: $ref: '#/components/schemas/Id' report_name: type: string description: The name of the report title: Report Name example: BalanceSheet start_date: type: string description: The start date of the report title: Start Date pattern: ^\d{4}-\d{2}-\d{2}$ example: '2017-01-01' end_date: type: string description: The start date of the report title: Start Date pattern: ^\d{4}-\d{2}-\d{2}$ example: '2017-01-31' currency: $ref: '#/components/schemas/Currency' assets: type: object x-apideck-schema-id: BalanceSheetAssetsAccount x-apideck-weights: account_id: critical name: high value: critical items: medium title: Balance Sheet Assets Account description: A balance sheet assets account represents the financial position of a company at a specific point in time. additionalProperties: false properties: account_id: $ref: '#/components/schemas/AccountId' code: $ref: '#/components/schemas/AccountCode' name: $ref: '#/components/schemas/AccountName' value: $ref: '#/components/schemas/Amount' items: $ref: '#/components/schemas/BalanceSheetAccounts' example: account_id: '1' code: '1000' name: Assets value: 50000 items: - account_id: '101' code: '1100' name: Current Assets value: 20000 items: - account_id: '1011' code: '1101' name: Cash and Cash Equivalents value: 10000 - account_id: '1012' code: '1102' name: Accounts Receivable value: 5000 - account_id: '1013' code: '1103' name: Inventory value: 3000 - account_id: '1014' code: '1104' name: Prepaid Expenses value: 2000 - account_id: '102' code: '1200' name: Non-Current Assets value: 30000 items: - account_id: '1021' code: '1201' name: Property, Plant, and Equipment (PPE) value: 25000 - account_id: '1022' code: '1202' name: Intangible Assets value: 5000 items: - account_id: '10221' code: '1203' name: Goodwill value: 3000 - account_id: '10222' code: '1204' name: Patents value: 2000 liabilities: type: object x-apideck-schema-id: BalanceSheetLiabilitiesAccount x-apideck-weights: account_id: critical name: high value: critical items: medium title: Balance Sheet Liabilities Account description: A balance sheet liabilities account represents the financial position of a company at a specific point in time. additionalProperties: false properties: account_id: $ref: '#/components/schemas/AccountId' code: $ref: '#/components/schemas/AccountCode' name: $ref: '#/components/schemas/AccountName' value: $ref: '#/components/schemas/Amount' items: $ref: '#/components/schemas/BalanceSheetAccounts' example: account_id: '2' code: '2000' name: Liabilities value: 30000 items: - account_id: '201' code: '2100' name: Current Liabilities value: 10000 items: - account_id: '2011' code: '2101' name: Accounts Payable value: 4000 - account_id: '2012' code: '2102' name: Short-Term Debt value: 2000 - account_id: '2013' code: '2103' name: Accrued Expenses value: 1000 - account_id: '2014' code: '2104' name: Current Portion of Long-Term Debt value: 3000 - account_id: '202' code: '2200' name: Non-Current Liabilities value: 20000 items: - account_id: '2021' code: '2201' name: Long-Term Debt value: 15000 - account_id: '2022' code: '2202' name: Deferred Tax Liabilities value: 3000 - account_id: '2023' code: '2203' name: Pension Liabilities value: 2000 equity: type: object x-apideck-schema-id: BalanceSheetEquityAccount x-apideck-weights: account_id: critical name: high value: critical items: medium title: Balance Sheet Equity Account description: A balance sheet equity account represents the financial position of a company at a specific point in time. additionalProperties: false properties: account_id: $ref: '#/components/schemas/AccountId' code: $ref: '#/components/schemas/AccountCode' name: $ref: '#/components/schemas/AccountName' value: $ref: '#/components/schemas/Amount' items: $ref: '#/components/schemas/BalanceSheetAccounts' example: account_id: '3' code: '3000' name: Equity value: 20000 items: - account_id: '301' code: '3100' name: Common Stock value: 5000 - account_id: '302' code: '3200' name: Retained Earnings value: 10000 - account_id: '303' code: '3300' name: Additional Paid-In Capital value: 3000 - account_id: '304' code: '3400' name: Treasury Stock value: -1000 - account_id: '305' code: '3500' name: Other Comprehensive Income value: 3000 net_assets: type: number description: The net assets of the balance sheet title: Net Assets example: 1000 custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' uncategorized_items: type: object x-apideck-schema-id: BalanceSheetUncategorizedItemsAccount x-apideck-weights: account_id: critical name: high value: critical items: medium title: Balance Sheet Uncategorized Items Account description: A balance sheet uncategorized items account represents the financial position of a company at a specific point in time. additionalProperties: false properties: account_id: $ref: '#/components/schemas/AccountId' code: $ref: '#/components/schemas/AccountCode' name: $ref: '#/components/schemas/AccountName' value: $ref: '#/components/schemas/Amount' items: $ref: '#/components/schemas/BalanceSheetAccounts' example: account_id: '3' code: '3000' name: Uncategorized Items value: 1000 items: - account_id: '301' code: '3100' name: not linked account value: 1000 BalanceSheetAccount: type: object x-apideck-schema-id: BalanceSheetAccount x-apideck-weights: account_id: critical name: high value: critical items: medium title: Balance Sheet Account description: A balance sheet account represents the financial position of a company at a specific point in time. additionalProperties: false properties: account_id: $ref: '#/components/schemas/AccountId' code: $ref: '#/components/schemas/AccountCode' name: $ref: '#/components/schemas/AccountName' value: $ref: '#/components/schemas/Amount' items: $ref: '#/components/schemas/BalanceSheetAccounts' BalanceSheetAccounts: type: array x-apideck-schema-id: BalanceSheetAccounts x-speakeasy-type-override: any title: Balance Sheet Accounts description: A list of balance sheet accounts nullable: true items: anyOf: - $ref: '#/components/schemas/BalanceSheetAccount' - $ref: '#/components/schemas/BalanceSheetAccountRecord' BalanceSheetAccountRecord: type: object x-apideck-schema-id: BalanceSheetAccountRecord x-apideck-weights: account_id: critical name: high value: critical items: medium title: Balance Sheet Account Record description: A record of a balance sheet account. additionalProperties: false properties: account_id: $ref: '#/components/schemas/AccountId' code: $ref: '#/components/schemas/AccountCode' name: $ref: '#/components/schemas/AccountName' value: $ref: '#/components/schemas/Amount' BalanceSheetFilter: type: object x-apideck-schema-id: BalanceSheetFilter example: start_date: '2021-01-01' end_date: '2021-12-31' period_count: 3 period_type: month properties: start_date: type: string title: Start date description: The start date of the period to include in the resource. example: '2021-01-01' end_date: type: string title: End date description: The end date of the period to include in the resource. example: '2021-12-31' period_count: type: integer title: Period count description: The number of periods to include in the resource. example: 3 period_type: x-apideck-enum-id: balance-sheet.period-type type: string title: Period type description: 'The type of period to include in the resource: month, quarter, year.' example: month enum: - month - quarter - year additionalProperties: false BankAccount: type: object x-apideck-schema-id: BankAccount additionalProperties: false x-apideck-weights: account_number: critical account_name: medium account_type: medium iban: high bic: medium bsb_number: edge-case branch_identifier: low bank_code: low bank_name: medium currency: medium properties: bank_name: type: string title: Bank Name description: The name of the bank example: Monzo nullable: true account_number: type: string title: Bank Account Number description: A bank account number is a number that is tied to your bank account. If you have several bank accounts, such as personal, joint, business (and so on), each account will have a different account number. example: '123465' nullable: true account_name: type: string title: Bank Account Name description: The name which you used in opening your bank account. example: SPACEX LLC nullable: true account_type: type: string title: Account Type x-apideck-enum-id: bank-accounts.account_type enum: - bank_account - credit_card - other description: The type of bank account. example: credit_card nullable: true iban: description: The International Bank Account Number (IBAN). type: string example: CH2989144532982975332 nullable: true bic: description: The Bank Identifier Code (BIC). type: string example: AUDSCHGGXXX nullable: true routing_number: type: string title: Routing number description: A routing number is a nine-digit code used to identify a financial institution in the United States. example: '012345678' nullable: true bsb_number: type: string title: BSB Number description: A BSB is a 6 digit numeric code used for identifying the branch of an Australian or New Zealand bank or financial institution. example: 062-001 nullable: true branch_identifier: type: string title: Branch Identifier description: A branch identifier is a unique identifier for a branch of a bank or financial institution. example: '001' nullable: true bank_code: type: string title: Bank Code description: A bank code is a code assigned by a central bank, a bank supervisory body or a Bankers Association in a country to all its licensed member banks or financial institutions. example: BNH nullable: true currency: $ref: '#/components/schemas/Currency' Bill: type: object x-apideck-schema-id: Bill additionalProperties: false x-apideck-weights: id: critical downstream_id: low bill_number: high supplier: high company_id: middle currency: medium currency_rate: low tax_inclusive: low bill_date: critical due_date: critical paid_date: high po_number: low reference: low line_items: critical terms: low balance: high deposit: low sub_total: high total_tax: high total: critical tax_code: medium notes: low status: critical ledger_account: low payment_method: low channel: low language: low accounting_by_row: edge-case bank_account: low discount_percentage: medium tracking_categories: low updated_by: low created_by: low created_at: edge-case updated_at: high row_version: edge-case accounting_period: low x-apideck-strict-required: - id - bill_date - due_date - line_items - total - status properties: id: $ref: '#/components/schemas/Id' downstream_id: $ref: '#/components/schemas/DownstreamId' bill_number: type: string title: Bill number example: '10001' description: Reference to supplier bill number nullable: true supplier: $ref: '#/components/schemas/LinkedSupplier' company_id: $ref: '#/components/schemas/AccountingCompanyId' currency: $ref: '#/components/schemas/Currency' currency_rate: $ref: '#/components/schemas/CurrencyRate' tax_inclusive: $ref: '#/components/schemas/TaxInclusive' bill_date: type: string title: Bill date description: Date bill was issued - YYYY-MM-DD. format: date example: '2020-09-30' due_date: $ref: '#/components/schemas/DueDate' paid_date: type: string title: Paid date description: The paid date is the date on which a payment was sent to the supplier - YYYY-MM-DD. format: date example: '2020-10-30' nullable: true po_number: type: string title: Purchase Order number description: A PO Number uniquely identifies a purchase order and is generally defined by the buyer. The buyer will match the PO number in the invoice to the Purchase Order. example: '90000117' nullable: true reference: type: string title: Bill reference description: Optional bill reference. example: '123456' nullable: true line_items: type: array items: $ref: '#/components/schemas/BillLineItem' terms: type: string title: Terms description: Terms of payment. example: Net 30 days nullable: true balance: type: number title: Balance description: Balance of bill due. example: 27500 nullable: true deposit: type: number title: Deposit description: Amount of deposit made to this bill. example: 0 nullable: true sub_total: title: Sub-total amount description: Sub-total amount, normally before tax. type: number example: 27500 nullable: true total_tax: type: number title: Total tax amount description: Total tax amount applied to this bill. example: 2500 nullable: true total: type: number title: Total amount description: Total amount of bill, including tax. example: 27500 nullable: true tax_code: $ref: '#/components/schemas/TaxCode' notes: type: string title: Notes example: Some notes about this bill. nullable: true status: type: string title: Status description: Invoice status example: draft x-apideck-enum-id: invoices.status enum: - draft - submitted - authorised - partially_paid - paid - void - credit - deleted nullable: true ledger_account: $ref: '#/components/schemas/LinkedLedgerAccount' payment_method: $ref: '#/components/schemas/PaymentMethod' channel: $ref: '#/components/schemas/Channel' language: $ref: '#/components/schemas/Language' accounting_by_row: $ref: '#/components/schemas/AccountingByRow' bank_account: $ref: '#/components/schemas/BankAccount' discount_percentage: $ref: '#/components/schemas/DiscountPercentage' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' row_version: $ref: '#/components/schemas/RowVersion' custom_mappings: $ref: '#/components/schemas/CustomMappings' pass_through: $ref: '#/components/schemas/PassThroughBody' accounting_period: $ref: '#/components/schemas/AccountingPeriod' BillLineItem: type: object title: Bill Line Item x-apideck-schema-id: BillLineItem additionalProperties: false x-apideck-weights: id: high row_id: edge-case code: medium line_number: medium description: high type: medium tax_amount: high total_amount: high quantity: high unit_price: high unit_of_measure: edge-case discount_percentage: low discount_amount: low location_id: low department_id: low item: high tax_rate: medium ledger_account: low tracking_categories: low row_version: edge-case created_at: edge-case updated_at: high updated_by: edge-case created_by: edge-case properties: id: $ref: '#/components/schemas/Id' row_id: type: string title: Row ID description: Row ID example: '12345' code: type: string title: Item code description: User defined item code example: 120-C nullable: true line_number: type: integer title: Line number description: Line number in the invoice example: 1 nullable: true description: type: string title: Description description: User defined description example: Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection. nullable: true type: type: string title: Type description: Bill Line Item type example: expense_account x-apideck-enum-id: bills.line_items.type enum: - expense_item - expense_account - other nullable: true tax_amount: type: number title: Tax amount description: Tax amount example: 27500 nullable: true total_amount: type: number title: Total amount description: Total amount of the line item example: 27500 nullable: true quantity: $ref: '#/components/schemas/Quantity' unit_price: $ref: '#/components/schemas/UnitPrice' unit_of_measure: $ref: '#/components/schemas/UnitOfMeasure' discount_percentage: type: number title: Discount Percentage description: Discount percentage applied to the line item when supported downstream. example: 0.01 nullable: true discount_amount: type: number title: Discount Amount description: Discount amount applied to the line item when supported downstream. example: 19.99 nullable: true location_id: type: string title: Location id description: Location id example: '1234' nullable: true department_id: type: string title: Department id description: Department id example: '1234' nullable: true item: $ref: '#/components/schemas/LinkedInvoiceItem' tax_rate: $ref: '#/components/schemas/LinkedTaxRate' ledger_account: $ref: '#/components/schemas/LinkedLedgerAccount' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' created_at: $ref: '#/components/schemas/CreatedAt' updated_at: $ref: '#/components/schemas/UpdatedAt' BillsFilter: type: object x-apideck-schema-id: BillsFilter example: updated_since: '2020-09-30T07:43:32.000Z' properties: updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' additionalProperties: false BillsSort: type: object x-apideck-schema-id: BillsSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: bills.sort_by description: The field on which to sort the Bills enum: - updated_at - created_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false Channel: type: string title: Channel description: The channel through which the transaction is processed. nullable: true example: email Company: type: object x-apideck-schema-id: Company x-apideck-weights: id: critical name: critical interaction_count: edge-case owner_id: high image: low description: medium vat_number: high currency: medium status: high fax: low annual_revenue: low number_of_employees: low industry: medium ownership: low sales_tax_number: medium payee_number: edge-case abn_or_tfn: edge-case abn_branch: edge-case acn: edge-case first_name: edge-case last_name: edge-case parent_id: edge-case bank_accounts: medium websites: medium addresses: high social_links: low phone_numbers: high emails: high row_type: edge-case custom_fields: medium tags: low read_only: low last_activity_at: low deleted: medium salutation: edge-case birthday: edge-case updated_by: edge-case created_by: edge-case updated_at: high created_at: medium required: - name additionalProperties: false properties: id: description: Unique identifier for the company type: string readOnly: true example: '12345' name: title: Name description: Name of the company type: string example: SpaceX nullable: true interaction_count: description: Number of interactions type: integer example: 1 readOnly: true nullable: true owner_id: description: Owner ID type: string example: '12345' nullable: true image: description: The Image URL of the company type: string example: https://www.spacex.com/static/images/share.jpg nullable: true description: description: A description of the company type: string example: Space Exploration Technologies Corp. is an American aerospace manufacturer, space transportation services and communications company headquartered in Hawthorne, California. nullable: true vat_number: description: The VAT number of the company type: string example: BE0689615164 nullable: true currency: $ref: '#/components/schemas/Currency' status: description: The status of the company type: string example: Open nullable: true fax: description: The fax number of the company type: string example: '+12129876543' nullable: true annual_revenue: description: The annual revenue of the company type: string example: +$35m nullable: true number_of_employees: description: Number of employees type: string example: 500-1000 nullable: true industry: description: The industry represents the type of business the company is in. type: string example: Apparel nullable: true ownership: description: The ownership indicates the type of ownership of the company. type: string example: Public nullable: true sales_tax_number: title: Sales tax number description: A sales tax number is a unique number that identifies a company for tax purposes. type: string example: 12456EN nullable: true payee_number: title: Payee number description: A payee number is a unique number that identifies a payee for tax purposes. type: string example: 78932EN nullable: true abn_or_tfn: title: ABN or TFN description: An ABN is necessary for operating a business, while a TFN (Tax File Number) is required for any person working in Australia. type: string example: 46 115 614 695 nullable: true abn_branch: title: ABN Branch description: An ABN Branch (also known as a GST Branch) is used if part of your business needs to account for GST separately from its parent entity. type: string example: '123' nullable: true acn: title: ACN description: The Australian Company Number (ACN) is a nine digit number with the last digit being a check digit calculated using a modified modulus 10 calculation. ASIC has adopted a convention of always printing and displaying the ACN in the format XXX XXX XXX; three blocks of three characters, each block separated by a blank. type: string example: XXX XXX XXX nullable: true first_name: $ref: '#/components/schemas/FirstName' last_name: $ref: '#/components/schemas/LastName' parent_id: description: Parent ID type: string readOnly: true nullable: true example: '22345' bank_accounts: type: array items: $ref: '#/components/schemas/BankAccount' websites: type: array items: $ref: '#/components/schemas/Website' addresses: type: array items: $ref: '#/components/schemas/Address' social_links: type: array items: $ref: '#/components/schemas/SocialLink' phone_numbers: type: array items: $ref: '#/components/schemas/PhoneNumber' emails: type: array items: $ref: '#/components/schemas/Email' row_type: x-apideck-weights: id: critical name: medium type: object title: Company Row Type properties: id: type: string example: '12345' nullable: true name: type: string example: Customer Account nullable: true custom_fields: type: array items: $ref: '#/components/schemas/CustomField' tags: $ref: '#/components/schemas/Tags' read_only: description: Whether the company is read-only or not type: boolean title: Read-only example: false nullable: true last_activity_at: description: Last activity date type: string format: date-time example: '2020-09-30T07:43:32.000Z' readOnly: true nullable: true deleted: description: Whether the company is deleted or not type: boolean example: false readOnly: true salutation: type: string description: A formal salutation for the person. For example, 'Mr', 'Mrs' example: Mr nullable: true birthday: type: string title: Birth Date description: The date of birth of the person. example: '2000-08-12' format: date nullable: true custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_by: description: Updated by user ID type: string example: '12345' readOnly: true nullable: true created_by: description: Created by user ID type: string example: '12345' readOnly: true nullable: true updated_at: description: Last updated date type: string format: date-time example: '2020-09-30T07:43:32.000Z' readOnly: true nullable: true created_at: description: Creation date type: string format: date-time example: '2020-09-30T07:43:32.000Z' readOnly: true nullable: true pass_through: $ref: '#/components/schemas/PassThroughBody' AccountingCompanyId: type: string title: CompanyId description: The company or subsidiary id the transaction belongs to example: '12345' nullable: true CompanyInfo: type: object x-apideck-schema-id: CompanyInfo x-apideck-weights: id: medium company_name: critical status: critical legal_name: medium sales_tax_number: medium currency: medium language: low fiscal_year_start_month: medium company_start_date: medium addresses: medium phone_numbers: medium emails: medium default_sales_tax: edge-case sales_tax_enabled: edge-case automated_sales_tax: edge-case row_version: edge-case updated_by: edge-case created_by: edge-case updated_at: medium created_at: low additionalProperties: false properties: id: $ref: '#/components/schemas/Id' company_name: $ref: '#/components/schemas/CompanyName' status: type: string title: Company status description: Based on the status some functionality is enabled or disabled. x-apideck-enum-id: company-info.status enum: - active - inactive example: active legal_name: type: string title: Legal name description: The legal name of the company example: SpaceX Inc. country: type: string example: US description: country code according to ISO 3166-1 alpha-2. nullable: true sales_tax_number: $ref: '#/components/schemas/SalesTaxNumber' automated_sales_tax: type: boolean title: Automated sales tax description: Whether sales tax is calculated automatically for the company sales_tax_enabled: type: boolean title: Sales tax enabled description: Whether sales tax is enabled for the company default_sales_tax: $ref: '#/components/schemas/TaxRate' currency: $ref: '#/components/schemas/Currency' language: $ref: '#/components/schemas/Language' fiscal_year_start_month: type: string title: The start month of fiscal year. description: The start month of fiscal year. x-apideck-enum-id: company-info.fiscal_year_start_month enum: - January - February - March - April - May - June - July - August - September - October - November - December example: January company_start_date: type: string title: Date when company file was created description: Date when company file was created format: date example: '2015-06-05' addresses: type: array items: $ref: '#/components/schemas/Address' phone_numbers: type: array items: $ref: '#/components/schemas/PhoneNumber' emails: type: array items: $ref: '#/components/schemas/Email' custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' CompanyName: type: string title: Company name description: The name of the company. example: SpaceX nullable: true Contact: type: object x-apideck-schema-id: Contact x-apideck-weights: id: critical name: critical owner_id: medium type: medium company_id: high company_name: medium lead_id: medium first_name: high middle_name: low last_name: high prefix: low suffix: low title: medium department: medium language: medium gender: medium birthday: medium image: medium photo_url: medium lead_source: low fax: low description: low current_balance: edge-case status: edge-case active: edge-case websites: medium addresses: high social_links: low phone_numbers: high emails: high email_domain: edge-case custom_fields: medium tags: low first_call_at: edge-case first_email_at: edge-case last_activity_at: medium updated_at: high created_at: medium opportunity_ids: low required: - name x-pii: - name - first_name - middle_name - last_name - email properties: id: description: Unique identifier for the contact. type: string example: '12345' readOnly: true name: description: Full name of the contact. type: string example: Elon Musk nullable: true owner_id: description: The owner of the contact. type: string example: '54321' nullable: true type: description: The type of the contact. type: string example: personal x-apideck-enum-id: contacts.type enum: - customer - supplier - employee - personal nullable: true company_id: description: The company the contact is associated with. type: string example: '23456' nullable: true company_name: description: The name of the company the contact is associated with. type: string example: '23456' nullable: true lead_id: description: The lead the contact is associated with. type: string example: '34567' nullable: true first_name: description: The first name of the contact. type: string example: Elon nullable: true middle_name: description: The middle name of the contact. type: string example: D. nullable: true last_name: description: The last name of the contact. type: string example: Musk nullable: true prefix: description: The prefix of the contact. type: string example: Mr. nullable: true suffix: description: The suffix of the contact. type: string example: PhD nullable: true title: description: The job title of the contact. type: string example: CEO nullable: true department: description: The department of the contact. type: string example: Engineering nullable: true language: type: string example: EN description: language code according to ISO 639-1. For the United States - EN nullable: true gender: type: string x-apideck-enum-id: contacts.gender enum: - male - female - unisex description: The gender of the contact. example: female nullable: true birthday: description: The birthday of the contact. type: string example: '2000-08-12' nullable: true image: type: string example: https://unavatar.io/elon-musk nullable: true deprecated: true photo_url: type: string title: Photo URL description: The URL of the photo of a person. example: https://unavatar.io/elon-musk nullable: true lead_source: description: The lead source of the contact. type: string example: Cold Call nullable: true fax: description: The fax number of the contact. type: string example: '+12129876543' nullable: true description: description: The description of the contact. type: string title: Description example: Internal champion nullable: true current_balance: description: The current balance of the contact. type: number title: Current Balance example: 10.5 nullable: true status: description: The status of the contact. type: string example: open nullable: true active: description: The active status of the contact. type: boolean example: true nullable: true websites: type: array items: $ref: '#/components/schemas/Website' addresses: type: array items: $ref: '#/components/schemas/Address' social_links: type: array items: $ref: '#/components/schemas/SocialLink' phone_numbers: type: array items: $ref: '#/components/schemas/PhoneNumber' emails: type: array items: $ref: '#/components/schemas/Email' email_domain: type: string example: gmail.com nullable: true custom_fields: type: array items: $ref: '#/components/schemas/CustomField' tags: $ref: '#/components/schemas/Tags' first_call_at: description: The first call date of the contact. type: string format: date-time example: '2020-09-30T07:43:32.000Z' readOnly: true nullable: true first_email_at: description: The first email date of the contact. type: string format: date-time example: '2020-09-30T07:43:32.000Z' readOnly: true nullable: true last_activity_at: description: The last activity date of the contact. type: string format: date-time example: '2020-09-30T07:43:32.000Z' readOnly: true nullable: true custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_at: description: The last update date of the contact. type: string format: date-time example: '2017-08-12T20:43:21.291Z' readOnly: true nullable: true created_at: description: The creation date of the contact. type: string format: date-time example: '2017-08-12T20:43:21.291Z' readOnly: true nullable: true opportunity_ids: description: The opportunity ids of the contact. type: array items: type: string example: '12345' pass_through: $ref: '#/components/schemas/PassThroughBody' additionalProperties: false CreateBillResponse: type: object x-apideck-schema-id: CreateBillResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: bills operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreateCreditNoteResponse: type: object x-apideck-schema-id: CreateCreditNoteResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: credit-notes operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreateCustomerResponse: type: object x-apideck-schema-id: CreateCustomerResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: customers operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreateInvoiceItemResponse: type: object x-apideck-schema-id: CreateInvoiceItemResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoice-items operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreateInvoiceResponse: type: object x-apideck-schema-id: CreateInvoiceResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoices operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/InvoiceResponse' CreateJournalEntryResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: journal-entries operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreateLedgerAccountResponse: type: object x-apideck-schema-id: CreateLedgerAccountResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: ledger-accounts operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreatePaymentResponse: type: object x-apideck-schema-id: CreatePaymentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreatePurchaseOrderResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: PurchaseOrders operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreateSupplierResponse: type: object x-apideck-schema-id: CreateSupplierResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreateTaxRateResponse: type: object x-apideck-schema-id: CreateTaxRateResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: tax-rates operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' CreatedAt: type: string title: Created at (timestamp) description: The date and time when the object was created. format: date-time example: '2020-09-30T07:43:32.000Z' readOnly: true nullable: true CreatedBy: type: string title: Created by description: The user who created the object. example: '12345' readOnly: true nullable: true CreditNote: type: object x-apideck-schema-id: CreditNote x-apideck-weights: id: critical number: low customer: high company_id: middle currency: critical currency_rate: medium tax_inclusive: low sub_total: critical total_amount: critical total_tax: edge-case tax_code: edge-case balance: critical remaining_credit: edge-case status: high reference: low date_issued: edge-case date_paid: critical type: edge-case account: critical line_items: medium allocations: medium note: low terms: low billing_address: low shipping_address: low tracking_categories: low custom_fields: medium row_version: edge-case updated_by: low created_by: low created_at: medium updated_at: medium required: - id - total_amount x-apideck-strict-required: - total_amount - currency - customer additionalProperties: false properties: id: type: string title: Credit Note identifier description: Unique identifier representing the entity example: '123456' readOnly: true number: type: string title: Credit note number description: Credit note number. example: OIT00546 nullable: true customer: $ref: '#/components/schemas/LinkedCustomer' company_id: $ref: '#/components/schemas/AccountingCompanyId' currency: $ref: '#/components/schemas/Currency' currency_rate: $ref: '#/components/schemas/CurrencyRate' tax_inclusive: $ref: '#/components/schemas/TaxInclusive' sub_total: title: Sub-total amount description: Sub-total amount, normally before tax. type: number example: 27500 nullable: true total_amount: type: number title: Total amount description: Amount of transaction example: 49.99 total_tax: type: number title: Total tax amount description: Total tax amount applied to this invoice. example: 2500 nullable: true tax_code: type: string title: Tax Code description: Applicable tax id/code override if tax is not supplied on a line item basis. example: '1234' nullable: true balance: type: number title: Balance description: The balance reflecting any payments made against the transaction. example: 27500 nullable: true remaining_credit: type: number title: Remaining Credit description: Indicates the total credit amount still available to apply towards the payment. example: 27500 nullable: true status: type: string title: Credit Note status description: Status of credit notes x-apideck-enum-id: credit-notes.status enum: - draft - authorised - paid - voided - deleted example: authorised reference: type: string title: Credit Note reference description: 'Optional reference message ie: Debit remittance detail.' example: '123456' nullable: true date_issued: type: string title: Datetime description: Date credit note issued - YYYY:MM::DDThh:mm:ss.sTZD format: date-time example: '2021-05-01T12:00:00.000Z' date_paid: type: string title: Datetime description: Date credit note paid - YYYY:MM::DDThh:mm:ss.sTZD format: date-time example: '2021-05-01T12:00:00.000Z' nullable: true type: type: string title: Credit Note Type description: Type of payment x-apideck-enum-id: credit-notes.type enum: - accounts_receivable_credit - accounts_payable_credit example: accounts_receivable_credit account: $ref: '#/components/schemas/LinkedLedgerAccount' line_items: type: array items: $ref: '#/components/schemas/InvoiceLineItem' allocations: type: array items: $ref: '#/components/schemas/Allocation' note: type: string title: Note description: Optional note to be associated with the credit note. example: Some notes about this credit note nullable: true terms: type: string title: Terms description: Optional terms to be associated with the credit note. example: Some terms about this credit note nullable: true billing_address: $ref: '#/components/schemas/Address' shipping_address: $ref: '#/components/schemas/Address' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' custom_mappings: $ref: '#/components/schemas/CustomMappings' custom_fields: type: array items: $ref: '#/components/schemas/CustomField' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' CreditNotesFilter: type: object x-apideck-schema-id: CreditNotesFilter example: updated_since: '2020-09-30T07:43:32.000Z' properties: updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' additionalProperties: false CreditNotesSort: type: object x-apideck-schema-id: CreditNotesSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: customers.sort_by description: The field on which to sort the Customers enum: - created_at - updated_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false Currency: type: string title: Currency description: Indicates the associated currency for an amount of money. Values correspond to [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217). example: USD x-apideck-enum-id: currencies x-apideck-enum-coverage-ignore: true enum: - UNKNOWN_CURRENCY - AED - AFN - ALL - AMD - ANG - AOA - ARS - AUD - AWG - AZN - BAM - BBD - BDT - BGN - BHD - BIF - BMD - BND - BOB - BOV - BRL - BSD - BTN - BWP - BYR - BZD - CAD - CDF - CHE - CHF - CHW - CLF - CLP - CNY - COP - COU - CRC - CUC - CUP - CVE - CZK - DJF - DKK - DOP - DZD - EGP - ERN - ETB - EUR - FJD - FKP - GBP - GEL - GHS - GIP - GMD - GNF - GTQ - GYD - HKD - HNL - HRK - HTG - HUF - IDR - ILS - INR - IQD - IRR - ISK - JMD - JOD - JPY - KES - KGS - KHR - KMF - KPW - KRW - KWD - KYD - KZT - LAK - LBP - LKR - LRD - LSL - LTL - LVL - LYD - MAD - MDL - MGA - MKD - MMK - MNT - MOP - MRO - MUR - MVR - MWK - MXN - MXV - MYR - MZN - NAD - NGN - NIO - NOK - NPR - NZD - OMR - PAB - PEN - PGK - PHP - PKR - PLN - PYG - QAR - RON - RSD - RUB - RWF - SAR - SBD - SCR - SDG - SEK - SGD - SHP - SLL - SOS - SRD - SSP - STD - SVC - SYP - SZL - THB - TJS - TMT - TND - TOP - TRC - TRY - TTD - TWD - TZS - UAH - UGX - USD - USN - USS - UYI - UYU - UZS - VEF - VND - VUV - WST - XAF - XAG - XAU - XBA - XBB - XBC - XBD - XCD - XDR - XOF - XPD - XPF - XPT - XTS - XXX - YER - ZAR - ZMK - ZMW - BTC - ETH x-enum-elements: - name: UNKNOWN_CURRENCY description: Unknown currency - name: AED description: United Arab Emirates dirham - name: AFN description: Afghan afghani - name: ALL description: Albanian lek - name: AMD description: Armenian dram - name: ANG description: Netherlands Antillean guilder - name: AOA description: Angolan kwanza - name: ARS description: Argentine peso - name: AUD description: Australian dollar - name: AWG description: Aruban florin - name: AZN description: Azerbaijani manat - name: BAM description: Bosnia and Herzegovina convertible mark - name: BBD description: Barbados dollar - name: BDT description: Bangladeshi taka - name: BGN description: Bulgarian lev - name: BHD description: Bahraini dinar - name: BIF description: Burundian franc - name: BMD description: Bermudian dollar - name: BND description: Brunei dollar - name: BOB description: Boliviano - name: BOV description: Bolivian Mvdol - name: BRL description: Brazilian real - name: BSD description: Bahamian dollar - name: BTN description: Bhutanese ngultrum - name: BWP description: Botswana pula - name: BYR description: Belarusian ruble - name: BZD description: Belize dollar - name: CAD description: Canadian dollar - name: CDF description: Congolese franc - name: CHE description: WIR Euro - name: CHF description: Swiss franc - name: CHW description: WIR Franc - name: CLF description: Unidad de Fomento - name: CLP description: Chilean peso - name: CNY description: Chinese yuan - name: COP description: Colombian peso - name: COU description: Unidad de Valor Real - name: CRC description: Costa Rican colon - name: CUC description: Cuban convertible peso - name: CUP description: Cuban peso - name: CVE description: Cape Verdean escudo - name: CZK description: Czech koruna - name: DJF description: Djiboutian franc - name: DKK description: Danish krone - name: DOP description: Dominican peso - name: DZD description: Algerian dinar - name: EGP description: Egyptian pound - name: ERN description: Eritrean nakfa - name: ETB description: Ethiopian birr - name: EUR description: Euro - name: FJD description: Fiji dollar - name: FKP description: Falkland Islands pound - name: GBP description: Pound sterling - name: GEL description: Georgian lari - name: GHS description: Ghanaian cedi - name: GIP description: Gibraltar pound - name: GMD description: Gambian dalasi - name: GNF description: Guinean franc - name: GTQ description: Guatemalan quetzal - name: GYD description: Guyanese dollar - name: HKD description: Hong Kong dollar - name: HNL description: Honduran lempira - name: HRK description: Croatian kuna - name: HTG description: Haitian gourde - name: HUF description: Hungarian forint - name: IDR description: Indonesian rupiah - name: ILS description: Israeli new shekel - name: INR description: Indian rupee - name: IQD description: Iraqi dinar - name: IRR description: Iranian rial - name: ISK description: Icelandic króna - name: JMD description: Jamaican dollar - name: JOD description: Jordanian dinar - name: JPY description: Japanese yen - name: KES description: Kenyan shilling - name: KGS description: Kyrgyzstani som - name: KHR description: Cambodian riel - name: KMF description: Comoro franc - name: KPW description: North Korean won - name: KRW description: South Korean won - name: KWD description: Kuwaiti dinar - name: KYD description: Cayman Islands dollar - name: KZT description: Kazakhstani tenge - name: LAK description: Lao kip - name: LBP description: Lebanese pound - name: LKR description: Sri Lankan rupee - name: LRD description: Liberian dollar - name: LSL description: Lesotho loti - name: LTL description: Lithuanian litas - name: LVL description: Latvian lats - name: LYD description: Libyan dinar - name: MAD description: Moroccan dirham - name: MDL description: Moldovan leu - name: MGA description: Malagasy ariary - name: MKD description: Macedonian denar - name: MMK description: Myanmar kyat - name: MNT description: Mongolian tögrög - name: MOP description: Macanese pataca - name: MRO description: Mauritanian ouguiya - name: MUR description: Mauritian rupee - name: MVR description: Maldivian rufiyaa - name: MWK description: Malawian kwacha - name: MXN description: Mexican peso - name: MXV description: Mexican Unidad de Inversion - name: MYR description: Malaysian ringgit - name: MZN description: Mozambican metical - name: NAD description: Namibian dollar - name: NGN description: Nigerian naira - name: NIO description: Nicaraguan córdoba - name: NOK description: Norwegian krone - name: NPR description: Nepalese rupee - name: NZD description: New Zealand dollar - name: OMR description: Omani rial - name: PAB description: Panamanian balboa - name: PEN description: Peruvian sol - name: PGK description: Papua New Guinean kina - name: PHP description: Philippine peso - name: PKR description: Pakistani rupee - name: PLN description: Polish złoty - name: PYG description: Paraguayan guaraní - name: QAR description: Qatari riyal - name: RON description: Romanian leu - name: RSD description: Serbian dinar - name: RUB description: Russian ruble - name: RWF description: Rwandan franc - name: SAR description: Saudi riyal - name: SBD description: Solomon Islands dollar - name: SCR description: Seychelles rupee - name: SDG description: Sudanese pound - name: SEK description: Swedish krona - name: SGD description: Singapore dollar - name: SHP description: Saint Helena pound - name: SLL description: Sierra Leonean leone - name: SOS description: Somali shilling - name: SRD description: Surinamese dollar - name: SSP description: South Sudanese pound - name: STD description: São Tomé and Príncipe dobra - name: SVC description: Salvadoran colón - name: SYP description: Syrian pound - name: SZL description: Swazi lilangeni - name: THB description: Thai baht - name: TJS description: Tajikstani somoni - name: TMT description: Turkmenistan manat - name: TND description: Tunisian dinar - name: TOP description: Tongan pa'anga - name: TRY description: Turkish lira - name: TTD description: Trinidad and Tobago dollar - name: TWD description: New Taiwan dollar - name: TZS description: Tanzanian shilling - name: UAH description: Ukrainian hryvnia - name: UGX description: Ugandan shilling - name: USD description: United States dollar - name: USN description: United States dollar (next day) - name: USS description: United States dollar (same day) - name: UYI description: Uruguay Peso en Unidedades Indexadas - name: UYU description: Uruguyan peso - name: UZS description: Uzbekistan som - name: VEF description: Venezuelan bolívar soberano - name: VND description: Vietnamese đồng - name: VUV description: Vanuatu vatu - name: WST description: Samoan tala - name: XAF description: CFA franc BEAC - name: XAG description: Silver - name: XAU description: Gold - name: XBA description: European Composite Unit - name: XBB description: European Monetary Unit - name: XBC description: European Unit of Account 9 - name: XBD description: European Unit of Account 17 - name: XCD description: East Caribbean dollar - name: XDR description: Special drawing rights (International Monetary Fund) - name: XOF description: CFA franc BCEAO - name: XPD description: Palladium - name: XPF description: CFP franc - name: XPT description: Platinum - name: XTS description: Code reserved for testing - name: XXX description: No currency - name: YER description: Yemeni rial - name: ZAR description: South African rand - name: ZMK description: Zambian kwacha - name: ZMW description: Zambian kwacha - name: BTC description: Bitcoin - name: ETH description: Ether nullable: true CurrencyRate: type: number title: Currency Exchange Rate description: Currency Exchange Rate at the time entity was recorded/generated. nullable: true example: 0.69 CustomField: type: object x-apideck-schema-id: CustomField required: - id additionalProperties: false x-apideck-weights: id: critical value: critical name: medium description: edge-case properties: id: title: ID description: Unique identifier for the custom field. type: string example: '2389328923893298' nullable: true name: title: Name type: string description: Name of the custom field. example: employee_level nullable: true description: title: Description type: string description: More information about the custom field example: Employee Level nullable: true value: anyOf: - type: string example: Uses Salesforce and Marketo nullable: true - type: number example: 10 nullable: true - type: boolean example: true nullable: true - type: object example: foo: bar nullable: true - type: array items: type: string - type: array items: type: object Customer: type: object x-apideck-schema-id: Customer x-apideck-weights: id: critical downstream_id: edge-case display_id: edge-case display_name: edge-case company_name: high company_id: medium title: high first_name: high middle_name: low last_name: high suffix: low individual: medium addresses: high phone_numbers: high emails: high websites: medium bank_accounts: high notes: low tax_rate: medium tax_number: medium currency: medium account: medium status: high payment_method: edge-case channel: edge-case updated_by: edge-case created_by: edge-case updated_at: medium created_at: medium row_version: edge-case additionalProperties: false required: - id x-apideck-strict-required: - emails - addresses - phone_numbers - status - updated_at x-apideck-strict-any-of: - required: - first_name - last_name - required: - company_name properties: id: $ref: '#/components/schemas/Id' downstream_id: $ref: '#/components/schemas/DownstreamId' display_id: type: string title: Display ID description: Display ID example: EMP00101 nullable: true display_name: type: string title: Display Name description: Display name example: Windsurf Shop nullable: true company_name: $ref: '#/components/schemas/CompanyName' company_id: $ref: '#/components/schemas/AccountingCompanyId' title: $ref: '#/components/schemas/Title' first_name: $ref: '#/components/schemas/FirstName' middle_name: $ref: '#/components/schemas/MiddleName' last_name: $ref: '#/components/schemas/LastName' suffix: $ref: '#/components/schemas/Suffix' individual: type: boolean title: Is individual description: Is this an individual or business customer example: true nullable: true project: type: boolean title: Is project description: If true, indicates this is a Project. example: false nullable: true addresses: type: array items: $ref: '#/components/schemas/Address' phone_numbers: type: array items: $ref: '#/components/schemas/PhoneNumber' emails: type: array items: $ref: '#/components/schemas/Email' websites: type: array items: $ref: '#/components/schemas/Website' bank_accounts: type: array items: $ref: '#/components/schemas/BankAccount' notes: type: string title: Notes description: Some notes about this customer example: Some notes about this customer nullable: true tax_rate: $ref: '#/components/schemas/LinkedTaxRate' tax_number: $ref: '#/components/schemas/TaxNumber' currency: $ref: '#/components/schemas/Currency' account: $ref: '#/components/schemas/LinkedLedgerAccount' parent: $ref: '#/components/schemas/LinkedParentCustomer' status: type: string title: Status description: Customer status nullable: true example: active x-apideck-enum-id: customers.status enum: - active - inactive - archived - gdpr-erasure-request - unknown payment_method: $ref: '#/components/schemas/PaymentMethod' channel: $ref: '#/components/schemas/Channel' custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' row_version: $ref: '#/components/schemas/RowVersion' pass_through: $ref: '#/components/schemas/PassThroughBody' CustomersFilter: type: object x-apideck-schema-id: CustomersFilter example: company_name: SpaceX display_name: Elon Musk first_name: Elon last_name: Musk email: elon@musk.com status: active updated_since: '2020-09-30T07:43:32.000Z' properties: company_name: type: string title: Company Name description: Company Name of customer to search for example: SpaceX display_name: type: string title: Display Name description: Display Name of customer to search for example: Techno King first_name: type: string title: First Name description: First name of customer to search for example: Elon last_name: type: string title: Last Name description: Last name of customer to search for example: Musk email: type: string title: Email description: Email of customer to search for example: elon@spacex.com status: type: string title: Status description: Status of customer to filter on nullable: true example: active x-apideck-enum-id: customers.status enum: - active - inactive - archived - all updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' additionalProperties: false CustomersSort: type: object x-apideck-schema-id: CustomersSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: customers.sort_by description: The field on which to sort the Customers enum: - created_at - updated_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false DeleteBillResponse: type: object x-apideck-schema-id: DeleteBillResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: bills operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeleteCreditNoteResponse: type: object x-apideck-schema-id: DeleteCreditNoteResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: credit-notes operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeleteCustomerResponse: type: object x-apideck-schema-id: DeleteCustomerResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: customers operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeleteInvoiceItemResponse: $ref: '#/components/schemas/DeleteTaxRateResponse' DeleteInvoiceResponse: type: object x-apideck-schema-id: DeleteInvoiceResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoices operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/InvoiceResponse' DeleteJournalEntryResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: journal-entries operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeleteLedgerAccountResponse: type: object x-apideck-schema-id: DeleteLedgerAccountResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: ledger-accounts operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeletePaymentResponse: type: object x-apideck-schema-id: DeletePaymentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeletePurchaseOrderResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: PurchaseOrders operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeleteSubsidiaryResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeleteSupplierResponse: type: object x-apideck-schema-id: DeleteSupplierResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: suppliers operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' DeleteTaxRateResponse: type: object x-apideck-schema-id: DeleteTaxRateResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: tax-rates operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' AccountingDepartment: type: object x-apideck-schema-id: AccountingDepartment x-apideck-weights: id: medium parent_id: low name: critical status: critical subsidiaries: low additionalProperties: false properties: id: $ref: '#/components/schemas/Id' parent_id: $ref: '#/components/schemas/WritableId' name: type: string title: Department name description: The name of the department. example: Sales nullable: true status: type: string title: Department status description: Based on the status some functionality is enabled or disabled. x-apideck-enum-id: department.status enum: - active - inactive example: active subsidiaries: type: array items: $ref: '#/components/schemas/SubsidiaryReference' custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' AccountingDepartmentsFilter: type: object x-apideck-schema-id: AccountingDepartmentsFilter example: subsidiary: '1' properties: subsidiary: type: string title: Subsidiary Id description: Id of the subsidiary to search for example: '1' additionalProperties: false AccountingLocationsFilter: type: object x-apideck-schema-id: AccountingLocationsFilter example: subsidiary: '1' properties: subsidiary: type: string title: Subsidiary Id description: Id of the subsidiary to search for example: '1' additionalProperties: false DiscountPercentage: type: number title: Discount Percentage description: Discount percentage applied to this transaction. example: 5.5 nullable: true DownstreamId: type: string description: The third-party API ID of original entity example: '12345' nullable: true readOnly: true DueDate: type: string title: Due date description: The due date is the date on which a payment is scheduled to be received - YYYY-MM-DD. format: date example: '2020-10-30' Email: type: object x-apideck-schema-id: Email required: - email additionalProperties: false x-apideck-weights: email: critical type: critical id: edge-case properties: id: type: string example: '123' description: Unique identifier for the email address nullable: true email: type: string format: email description: Email address example: elon@musk.com minLength: 1 nullable: true type: type: string description: Email type x-apideck-enum-id: emails.type enum: - primary - secondary - work - personal - billing - other example: primary nullable: true FirstName: type: string title: First name description: The first name of the person. example: Elon nullable: true GetBalanceSheetResponse: type: object x-apideck-schema-id: GetBalanceSheetResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: BalanceSheets operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/BalanceSheet' GetBillResponse: type: object x-apideck-schema-id: GetBillResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: bills operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/Bill' GetBillsResponse: type: object x-apideck-schema-id: GetBillsResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: bills operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/Bill' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetCompanyInfoResponse: type: object x-apideck-schema-id: GetCompanyInfoResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: company-info operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/CompanyInfo' GetCreditNoteResponse: type: object x-apideck-schema-id: GetCreditNoteResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: credit-notes operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/CreditNote' GetCreditNotesResponse: type: object x-apideck-schema-id: GetCreditNotesResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: credit-notes operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/CreditNote' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetCustomerResponse: type: object x-apideck-schema-id: GetCustomerResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: customers operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/Customer' GetCustomersResponse: type: object x-apideck-schema-id: GetCustomersResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: customers operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/Customer' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetInvoiceItemResponse: type: object x-apideck-schema-id: GetInvoiceItemResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoice-items operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/InvoiceItem' GetInvoiceItemsResponse: type: object x-apideck-schema-id: GetInvoiceItemsResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoice-items operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/InvoiceItem' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetInvoiceResponse: type: object x-apideck-schema-id: GetInvoiceResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoices operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/Invoice' GetInvoicesResponse: type: object x-apideck-schema-id: GetInvoicesResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoices operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/Invoice' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetJournalEntriesResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: journal-entries operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/JournalEntry' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetJournalEntryResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: journal-entries operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/JournalEntry' GetLedgerAccountResponse: type: object x-apideck-schema-id: GetLedgerAccountResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: ledger-accounts operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/LedgerAccount' GetLedgerAccountsResponse: type: object x-apideck-schema-id: GetLedgerAccountsResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: ledger-accounts operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/LedgerAccount' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetPaymentResponse: type: object x-apideck-schema-id: GetPaymentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/Payment' GetPaymentsResponse: type: object x-apideck-schema-id: GetPaymentsResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/Payment' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetProfitAndLossResponse: type: object x-apideck-schema-id: GetProfitAndLossResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: ProfitAndLosses operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/ProfitAndLoss' GetPurchaseOrderResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: PurchaseOrders operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/PurchaseOrder' GetPurchaseOrdersResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: PurchaseOrders operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/PurchaseOrder' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' CreateSubsidiaryResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' GetSubsidiariesResponse: type: object x-apideck-schema-id: GetSubsidiariesResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/Subsidiary' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetSubsidiaryResponse: type: object x-apideck-schema-id: GetSubsidiaryResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/Subsidiary' GetAccountingLocationsResponse: type: object x-apideck-schema-id: GetAccountingLocationsResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/AccountingLocation' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetAccountingLocationResponse: type: object x-apideck-schema-id: GetAccountingLocationResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/AccountingLocation' CreateAccountingLocationResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: locations operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' DeleteAccountingLocationResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: locations operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' UpdateAccountingLocationResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: locations operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' GetAccountingDepartmentsResponse: type: object x-apideck-schema-id: GetAccountingDepartmentsResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/AccountingDepartment' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetAccountingDepartmentResponse: type: object x-apideck-schema-id: GetAccountingDepartmentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/AccountingDepartment' CreateAccountingDepartmentResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: departments operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' DeleteAccountingDepartmentResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: departments operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' UpdateAccountingDepartmentResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: departments operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' GetSupplierResponse: type: object x-apideck-schema-id: GetSupplierResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: suppliers operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/Supplier' GetSuppliersResponse: type: object x-apideck-schema-id: GetSuppliersResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: suppliers operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/Supplier' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' GetTaxRateResponse: type: object x-apideck-schema-id: GetTaxRateResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: tax-rates operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/TaxRate' GetTaxRatesResponse: type: object x-apideck-schema-id: GetTaxRatesResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: tax-rates operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/TaxRate' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' Id: type: string title: ID description: A unique identifier for an object. example: '12345' readOnly: true Invoice: type: object x-apideck-schema-id: Invoice additionalProperties: false x-apideck-weights: id: critical downstream_id: low type: high number: high customer: high company_id: middle invoice_date: edge-case due_date: edge-case terms: low po_number: low reference: low status: critical invoice_sent: low currency: medium currency_rate: low tax_inclusive: low sub_total: high total_tax: high tax_code: medium discount_percentage: medium discount_amount: medium total: critical balance: high deposit: low customer_memo: low line_items: critical billing_address: high shipping_address: medium template_id: edge-case source_document_url: edge-case payment_method: low channel: low language: low accounting_by_row: edge-case bank_account: low ledger_account: edge-case tracking_category: low tracking_categories: low row_version: edge-case custom_fields: medium updated_by: low created_by: low created_at: high updated_at: high properties: id: $ref: '#/components/schemas/Id' downstream_id: $ref: '#/components/schemas/DownstreamId' type: type: string title: Invoice type description: Invoice type x-apideck-enum-id: invoices.type enum: - standard - credit - service - product - supplier - other example: service nullable: true number: type: string title: Invoice number description: Invoice number. example: OIT00546 nullable: true customer: $ref: '#/components/schemas/LinkedCustomer' company_id: $ref: '#/components/schemas/AccountingCompanyId' invoice_date: type: string title: Invoice date description: Date invoice was issued - YYYY-MM-DD. format: date example: '2020-09-30' nullable: true due_date: type: string title: Due date description: The invoice due date is the date on which a payment or invoice is scheduled to be received by the seller - YYYY-MM-DD. format: date example: '2020-09-30' nullable: true terms: type: string title: Terms description: Terms of payment. example: Net 30 days nullable: true po_number: type: string title: Purchase Order number description: A PO Number uniquely identifies a purchase order and is generally defined by the buyer. The buyer will match the PO number in the invoice to the Purchase Order. example: '90000117' nullable: true reference: type: string title: Invoice reference description: Optional invoice reference. example: '123456' nullable: true status: type: string title: Status description: Invoice status example: draft x-apideck-enum-id: invoices.status enum: - draft - submitted - authorised - partially_paid - paid - void - credit - deleted nullable: true invoice_sent: type: boolean title: Invoice Sent description: Invoice sent to contact/customer. example: true currency: $ref: '#/components/schemas/Currency' currency_rate: $ref: '#/components/schemas/CurrencyRate' tax_inclusive: $ref: '#/components/schemas/TaxInclusive' sub_total: title: Sub-total amount description: Sub-total amount, normally before tax. type: number example: 27500 nullable: true total_tax: type: number title: Total tax amount description: Total tax amount applied to this invoice. example: 2500 nullable: true tax_code: type: string title: Tax Code description: Applicable tax id/code override if tax is not supplied on a line item basis. example: '1234' nullable: true discount_percentage: type: number title: Discount Percent description: Discount percentage applied to this invoice. example: 5.5 nullable: true discount_amount: type: number title: Discount Amount description: Discount amount applied to this invoice. example: 25 nullable: true total: type: number title: Total amount description: Total amount of invoice, including tax. example: 27500 nullable: true balance: type: number title: Balance description: Balance of invoice due. example: 27500 nullable: true deposit: type: number title: Deposit description: Amount of deposit made to this invoice. example: 0 nullable: true customer_memo: type: string title: Customer memo description: Customer memo example: Thank you for your business and have a great day! nullable: true tracking_category: $ref: '#/components/schemas/DeprecatedLinkedTrackingCategory' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' line_items: type: array items: $ref: '#/components/schemas/InvoiceLineItem' billing_address: $ref: '#/components/schemas/Address' shipping_address: $ref: '#/components/schemas/Address' template_id: type: string title: Template description: Optional invoice template example: '123456' nullable: true source_document_url: type: string title: Source document URL description: URL link to a source document - shown as 'Go to [appName]' in the downstream app. Currently only supported for Xero. example: https://www.invoicesolution.com/invoice/123456 nullable: true payment_method: $ref: '#/components/schemas/PaymentMethod' channel: $ref: '#/components/schemas/Channel' language: $ref: '#/components/schemas/Language' accounting_by_row: $ref: '#/components/schemas/AccountingByRow' bank_account: $ref: '#/components/schemas/BankAccount' ledger_account: $ref: '#/components/schemas/LinkedLedgerAccount' custom_mappings: $ref: '#/components/schemas/CustomMappings' custom_fields: type: array items: $ref: '#/components/schemas/CustomField' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' InvoiceItem: type: object x-apideck-schema-id: InvoiceItem x-apideck-weights: id: critical name: critical description: medium code: high sold: edge-case purchased: edge-case tracked: edge-case taxable: edge-case inventory_date: high type: high sales_details: medium purchase_details: medium quantity: high unit_price: high asset_account: medium income_account: high expense_account: medium active: medium tracking_category: low tracking_categories: low row_version: edge-case updated_by: edge-case created_by: edge-case updated_at: medium created_at: medium additionalProperties: false properties: id: title: Item ID description: The ID of the item. type: string example: '123456' readOnly: true name: type: string title: Item name description: Item name example: Model Y nullable: true description: type: string title: Description description: A short description of the item example: Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection. nullable: true code: type: string title: Item code description: User defined item code example: 120-C nullable: true sold: type: boolean title: Item sold description: Item will be available on sales transactions example: true nullable: true purchased: type: boolean title: Item purchased description: Item is available for purchase transactions example: true nullable: true tracked: type: boolean title: Item tracked description: Item is inventoried example: true nullable: true taxable: type: boolean title: Item taxable description: If true, transactions for this item are taxable example: true nullable: true inventory_date: type: string title: Inventory date description: The date of opening balance if inventory item is tracked - YYYY-MM-DD. format: date example: '2020-10-30' nullable: true type: type: string title: Type description: Item type example: inventory x-apideck-enum-id: invoice-items.type enum: - inventory - service - other nullable: true sales_details: x-apideck-weights: unit_price: medium unit_of_measure: medium tax_inclusive: medium tax_rate: medium type: object properties: unit_price: $ref: '#/components/schemas/UnitPrice' unit_of_measure: $ref: '#/components/schemas/UnitOfMeasure' tax_inclusive: $ref: '#/components/schemas/TaxInclusive' tax_rate: $ref: '#/components/schemas/LinkedTaxRate' purchase_details: x-apideck-weights: unit_price: medium unit_of_measure: medium tax_inclusive: medium tax_rate: medium type: object properties: unit_price: $ref: '#/components/schemas/UnitPrice' unit_of_measure: $ref: '#/components/schemas/UnitOfMeasure' tax_inclusive: $ref: '#/components/schemas/TaxInclusive' tax_rate: $ref: '#/components/schemas/LinkedTaxRate' quantity: $ref: '#/components/schemas/Quantity' unit_price: $ref: '#/components/schemas/UnitPrice' asset_account: $ref: '#/components/schemas/LinkedLedgerAccount' income_account: $ref: '#/components/schemas/LinkedLedgerAccount' expense_account: $ref: '#/components/schemas/LinkedLedgerAccount' tracking_category: $ref: '#/components/schemas/DeprecatedLinkedTrackingCategory' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' active: $ref: '#/components/schemas/Active' custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' InvoiceItemAssetAccount: $ref: '#/components/schemas/LinkedLedgerAccount' InvoiceItemExpenseAccount: $ref: '#/components/schemas/LinkedLedgerAccount' InvoiceItemIncomeAccount: $ref: '#/components/schemas/LinkedLedgerAccount' InvoiceItemsFilter: type: object x-apideck-schema-id: InvoiceItemsFilter example: name: Widgets Large type: service properties: name: type: string title: Name description: Name of Invoice Items to search for example: Widgets Large type: type: string title: Invoice item type example: service description: The type of invoice item, indicating whether it is an inventory item, a service, or another type. x-apideck-enum-id: accounting.invoice_items_type enum: - inventory - service - other nullable: true additionalProperties: false InvoiceItemFilter: type: object x-apideck-schema-id: InvoiceItemFilter example: type: service properties: type: type: string title: Invoice item type example: service description: The type of invoice item, indicating whether it is an inventory item, a service, or another type. x-apideck-enum-id: accounting.invoice_item_type enum: - inventory - service - other nullable: true additionalProperties: false InvoiceLineItem: type: object title: Invoice Line Item x-apideck-schema-id: InvoiceLineItem additionalProperties: false x-apideck-weights: id: high row_id: edge-case code: medium line_number: medium description: high type: medium tax_amount: high total_amount: high quantity: high unit_price: high unit_of_measure: edge-case discount_percentage: low discount_amount: low location_id: low department_id: low item: high tax_rate: medium ledger_account: low tracking_categories: low custom_fields: medium row_version: edge-case created_at: edge-case updated_at: high updated_by: edge-case created_by: edge-case properties: id: $ref: '#/components/schemas/WritableId' row_id: type: string title: Row ID description: Row ID example: '12345' code: type: string title: Item code description: User defined item code example: 120-C nullable: true line_number: $ref: '#/components/schemas/LineNumber' description: type: string title: Description description: User defined description example: Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection. nullable: true type: type: string title: Type description: Item type example: sales_item x-apideck-enum-id: invoices.lines-items.type enum: - sales_item - discount - info - sub_total - other nullable: true tax_amount: type: number title: Tax amount description: Tax amount example: 27500 nullable: true total_amount: type: number title: Total amount description: Total amount of the line item example: 27500 nullable: true quantity: $ref: '#/components/schemas/Quantity' unit_price: $ref: '#/components/schemas/UnitPrice' unit_of_measure: $ref: '#/components/schemas/UnitOfMeasure' discount_percentage: type: number title: Discount Percentage description: Discount percentage applied to the line item when supported downstream. example: 0.01 nullable: true discount_amount: type: number title: Discount Amount description: Discount amount applied to the line item when supported downstream. example: 19.99 nullable: true location_id: type: string title: Location id description: Location id example: '1234' nullable: true department_id: type: string title: Department id description: Department id example: '1234' nullable: true item: $ref: '#/components/schemas/LinkedInvoiceItem' tax_rate: $ref: '#/components/schemas/LinkedTaxRate' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' ledger_account: $ref: '#/components/schemas/LinkedLedgerAccount' custom_fields: type: array items: $ref: '#/components/schemas/CustomField' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' created_at: $ref: '#/components/schemas/CreatedAt' updated_at: $ref: '#/components/schemas/UpdatedAt' InvoiceResponse: type: object x-apideck-schema-id: InvoiceResponse properties: id: $ref: '#/components/schemas/Id' downstream_id: $ref: '#/components/schemas/DownstreamId' InvoicesFilter: type: object x-apideck-schema-id: InvoicesFilter example: updated_since: '2020-09-30T07:43:32.000Z' created_since: '2020-09-30T07:43:32.000Z' number: OIT00546 properties: updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' created_since: type: string title: Created since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' number: type: string title: Invoice number description: Invoice number to search for example: OIT00546 additionalProperties: false InvoicesSort: type: object x-apideck-schema-id: InvoicesSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: invoices.sort_by description: The field on which to sort the Invoices enum: - created_at - updated_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false JournalEntry: type: object additionalProperties: false x-apideck-weights: id: critical title: medium currency_rate: low currency: medium company_id: medium line_items: medium memo: low posted_at: low journal_symbol: edge-case tax_type: edge-case tax_code: edge-case number: medium tracking_categories: low accounting_period: low updated_by: edge-case created_by: edge-case updated_at: medium created_at: medium row_version: edge-case x-apideck-strict-required: - line_items properties: id: $ref: '#/components/schemas/Id' title: type: string title: Journal entry title description: Journal entry title example: 'Purchase Invoice-Inventory (USD): 2019/02/01 Batch Summary Entry' nullable: true currency_rate: $ref: '#/components/schemas/CurrencyRate' currency: $ref: '#/components/schemas/Currency' company_id: $ref: '#/components/schemas/AccountingCompanyId' line_items: type: array minItems: 2 description: Requires a minimum of 2 line items that sum to 0 items: $ref: '#/components/schemas/JournalEntryLineItem' memo: type: string title: Memo description: Reference for the journal entry. example: Thank you for your business and have a great day! nullable: true posted_at: type: string title: Posted at (timestamp) description: This is the date on which the journal entry was added. This can be different from the creation date and can also be backdated. format: date-time example: '2020-09-30T07:43:32.000Z' journal_symbol: type: string title: Journal symbol description: Journal symbol of the entry. For example IND for indirect costs example: IND nullable: true tax_type: type: string title: Tax Type description: The specific category of tax associated with a transaction like sales or purchase example: sales nullable: true tax_code: $ref: '#/components/schemas/TaxCode' number: type: string title: Journal entry number description: Journal entry number. example: OIT00546 nullable: true tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' accounting_period: $ref: '#/components/schemas/AccountingPeriod' custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' row_version: $ref: '#/components/schemas/RowVersion' pass_through: $ref: '#/components/schemas/PassThroughBody' JournalEntriesFilter: type: object x-apideck-schema-id: JournalEntriesFilter example: updated_since: '2020-09-30T07:43:32.000Z' properties: updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' additionalProperties: false JournalEntriesSort: type: object x-apideck-schema-id: JournalEntriesSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: journal_entries.sort_by description: The field on which to sort the Journal Entries. enum: - created_at - updated_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false JournalEntryLineItem: type: object x-apideck-schema-id: JournalEntryLineItem additionalProperties: false x-apideck-weights: id: high description: medium tax_amount: high sub_total: medium total_amount: high type: critical tax_rate: medium tracking_category: low tracking_categories: low ledger_account: critical customer: medium supplier: medium department_id: edge-case location_id: edge-case line_number: low required: - ledger_account - type x-apideck-strict-required: - ledger_account - type x-apideck-strict-any-of: - required: - total_amount - required: - sub_total properties: id: $ref: '#/components/schemas/Id' description: type: string title: Description description: User defined description example: Model Y is a fully electric, mid-size SUV, with seating for up to seven, dual motor AWD and unparalleled protection. nullable: true tax_amount: type: number title: Tax amount description: Tax amount example: 27500 nullable: true sub_total: title: Sub-total amount description: Sub-total amount, normally before tax. type: number example: 27500 nullable: true total_amount: type: number title: Total amount description: Debit entries are considered positive, and credit entries are considered negative. example: 27500 nullable: true type: type: string enum: - debit - credit x-apideck-enum-id: JournalEntryLineItemType title: Type description: Debit entries are considered positive, and credit entries are considered negative. example: debit tax_rate: $ref: '#/components/schemas/LinkedTaxRate' tracking_category: $ref: '#/components/schemas/DeprecatedLinkedTrackingCategory' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' ledger_account: $ref: '#/components/schemas/LinkedLedgerAccount' customer: $ref: '#/components/schemas/LinkedCustomer' supplier: $ref: '#/components/schemas/LinkedSupplier' department_id: $ref: '#/components/schemas/Id' location_id: $ref: '#/components/schemas/Id' line_number: $ref: '#/components/schemas/LineNumber' Language: type: string example: EN description: language code according to ISO 639-1. For the United States - EN nullable: true LastName: type: string title: Last name description: The last name of the person. example: Musk nullable: true LedgerAccount: type: object x-apideck-schema-id: LedgerAccount additionalProperties: false x-apideck-weights: id: critical display_id: low nominal_code: low code: low classification: edge-case type: high sub_type: edge-case name: high fully_qualified_name: edge-case description: edge-case opening_balance: edge-case current_balance: edge-case currency: edge-case tax_type: edge-case tax_rate: edge-case level: edge-case active: edge-case status: medium header: edge-case bank_account: high categories: high parent_account: high sub_account: medium sub_accounts: medium last_reconciliation_date: edge-case row_version: edge-case updated_by: edge-case created_by: edge-case subsidiaries: edge-case created_at: low updated_at: high properties: id: $ref: '#/components/schemas/Id' display_id: type: string title: Display ID description: The human readable display ID used when displaying the account example: 1-12345 nominal_code: type: string title: Nominal Code description: The nominal code of the ledger account. example: N091 nullable: true deprecated: true code: type: string title: Code description: The code assigned to the account. example: '453' nullable: true classification: type: string title: Classification description: The classification of account. x-apideck-enum-id: ledger-accounts.classification enum: - asset - equity - expense - liability - revenue - income - other_income - other_expense - costs_of_sales - other example: asset nullable: true type: type: string title: Type description: The type of account. x-apideck-enum-id: ledger-accounts.type enum: - accounts_receivable - revenue - sales - other_income - bank - current_asset - fixed_asset - non_current_asset - other_asset - balancesheet - equity - expense - other_expense - costs_of_sales - accounts_payable - credit_card - current_liability - non_current_liability - other_liability - other example: bank sub_type: type: string title: Sub Type description: The sub type of account. example: CHECKING_ACCOUNT nullable: true name: type: string title: Name description: The name of the account. example: Bank account nullable: true fully_qualified_name: type: string title: Fully Qualified Name description: The fully qualified name of the account. example: Asset.Bank.Checking_Account nullable: true description: type: string title: Description description: The description of the account. example: Main checking account nullable: true opening_balance: type: number title: Opening balance description: The opening balance of the account. example: 75000 nullable: true current_balance: type: number title: Current balance description: The current balance of the account. example: 20000 nullable: true currency: $ref: '#/components/schemas/Currency' tax_type: type: string title: Tax Type description: The tax type of the account. example: NONE nullable: true tax_rate: $ref: '#/components/schemas/LinkedTaxRate' level: type: number example: 1 nullable: true active: type: boolean title: Is active description: Whether the account is active or not. example: true nullable: true status: type: string title: Account status description: The status of the account. x-apideck-enum-id: ledger-accounts.status enum: - active - inactive - archived example: active nullable: true header: type: boolean title: Is header description: Whether the account is a header or not. example: true nullable: true bank_account: $ref: '#/components/schemas/BankAccount' categories: type: array title: Categories description: The categories of the account. readOnly: true items: type: object properties: id: type: string readOnly: true example: '12345' name: type: string title: Category name description: The name of the category. readOnly: true example: Finance Charges Expense parent_account: type: object properties: id: type: string title: Parent account ID description: The ID of the parent account. example: '12345' name: type: string title: Name description: The name of the parent account. example: Bank Accounts display_id: type: string title: Display ID description: The human readable display ID used when displaying the parent account example: 1-1100 sub_account: type: boolean title: Is sub account description: Whether the account is a sub account or not. example: false nullable: true sub_accounts: type: array readOnly: true title: Sub accounts description: The sub accounts of the account. items: properties: id: type: string title: Sub account ID description: The ID of the sub account. readOnly: true example: '12345' account_sub_name: type: string title: Sub Account Name description: The name of the sub account. readOnly: true example: Petty Cash last_reconciliation_date: type: string title: Last Reconciliation Date description: Reconciliation Date means the last calendar day of each Reconciliation Period. format: date example: '2020-09-30' nullable: true subsidiaries: type: array title: Subsidiaries description: The subsidiaries the account belongs to. items: properties: id: type: string title: Subsidiary ID description: The ID of the subsidiary. custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' LedgerAccounts: items: $ref: '#/components/schemas/LedgerAccount' type: array LedgerAccountsFilter: type: object x-apideck-schema-id: LedgerAccountsFilter example: updated_since: '2020-09-30T07:43:32.000Z' properties: updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' additionalProperties: false LedgerAccountsSort: type: object x-apideck-schema-id: LedgerAccountsSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: ledger_accounts.sort_by description: The field on which to sort the Ledger Accounts enum: - created_at - updated_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false LinkedCustomer: type: object x-apideck-schema-id: LinkedCustomer title: LinkedCustomer description: The customer this entity is linked to. x-apideck-weights: id: medium display_id: medium display_name: medium name: medium company_name: medium nullable: true properties: id: type: string title: Customer ID description: The ID of the customer this entity is linked to. example: '12345' display_id: type: string title: Display ID description: The display ID of the customer. example: CUST00101 nullable: true readOnly: true display_name: type: string title: Display Name description: The display name of the customer. example: Windsurf Shop nullable: true name: type: string title: Name description: The name of the customer. Deprecated, use display_name instead. example: Windsurf Shop deprecated: true company_name: type: string title: Company Name description: The company name of the customer. example: The boring company nullable: true readOnly: true email: type: string title: Email description: The email address of the customer. example: boring@boring.com LinkedInvoiceItem: type: object x-apideck-schema-id: LinkedInvoiceItem x-apideck-weights: id: medium code: medium name: medium properties: id: type: string title: Item ID description: ID of the linked item. A reference to the [invoice item](https://developers.apideck.com/apis/accounting/reference#tag/Invoice-Items) that was used to create this line item example: '12344' nullable: true code: type: string title: Item code description: User defined item code example: 120-C nullable: true name: type: string title: Item name description: User defined item name example: Model Y nullable: true LinkedLedgerAccount: type: object x-apideck-schema-id: LinkedLedgerAccount x-apideck-weights: id: medium nominal_code: medium code: medium name: medium nullable: true properties: id: title: Account ID description: The unique identifier for the account. type: string example: '123456' name: type: string title: Account Name description: The name of the account. example: Bank account readOnly: true nullable: true nominal_code: type: string title: Nominal Code description: The nominal code of the account. example: N091 nullable: true code: type: string title: Code description: The code assigned to the account. example: '453' nullable: true LinkedParentCustomer: type: object x-apideck-schema-id: LinkedParentCustomer title: LinkedParentCustomer description: The parent customer this entity is linked to. x-apideck-weights: id: critical nullable: true required: - id properties: id: type: string title: Customer ID description: The parent ID of the customer this entity is linked to. example: '12345' name: type: string title: Name description: The name of the parent customer. example: Windsurf Shop LinkedSupplier: type: object x-apideck-schema-id: LinkedSupplier title: LinkedSupplier description: The supplier this entity is linked to. x-apideck-weights: id: medium display_id: medium display_name: high company_name: edge-case address: low nullable: true properties: id: type: string title: Supplier ID description: The ID of the supplier this entity is linked to. example: '12345' display_id: type: string title: Display ID description: The display ID of the supplier. example: SUPP00101 nullable: true readOnly: true display_name: type: string title: Display Name description: The display name of the supplier. example: Windsurf Shop nullable: true company_name: type: string title: Company Name description: The company name of the supplier. example: The boring company nullable: true readOnly: true address: $ref: '#/components/schemas/Address' LinkedTaxRate: type: object x-apideck-schema-id: LinkedTaxRate x-apideck-weights: id: medium code: medium name: medium rate: medium properties: id: type: string title: The ID of the object. description: The ID of the object. example: '123456' nullable: true code: type: string title: Tax rate code description: Tax rate code example: N-T nullable: true readOnly: true name: type: string title: Name description: Name of the tax rate example: GST on Purchases nullable: true readOnly: true rate: type: number title: Rate description: Rate of the tax rate example: 10 nullable: true LinkedTrackingCategory: type: object x-apideck-schema-id: LinkedTrackingCategory x-apideck-weights: id: critical nullable: true properties: id: title: Tracking Category ID description: The unique identifier for the tracking category. type: string example: '123456' name: type: string title: Tracking Category Name description: The name of the tracking category. example: New York nullable: true DeprecatedLinkedTrackingCategory: type: object x-apideck-schema-id: DeprecatedLinkedTrackingCategory x-apideck-weights: id: critical nullable: true deprecated: true properties: id: title: Tracking Category ID description: The unique identifier for the tracking category. type: string example: '123456' name: type: string title: Tracking Category Name description: The name of the tracking category. example: New York nullable: true Links: type: object x-apideck-schema-id: Links description: Links to navigate to previous or next pages through the API properties: previous: type: string description: Link to navigate to the previous page through the API example: https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjE%3D nullable: true current: type: string description: Link to navigate to the current page through the API example: https://unify.apideck.com/crm/companies next: type: string description: Link to navigate to the previous page through the API example: https://unify.apideck.com/crm/companies?cursor=em9oby1jcm06OnBhZ2U6OjM nullable: true AccountingLocation: type: object x-apideck-schema-id: AccountingLocation x-apideck-weights: id: medium parent_id: low company_name: medium display_name: critical status: critical addresses: low subsidiaries: low additionalProperties: false properties: id: $ref: '#/components/schemas/Id' parent_id: $ref: '#/components/schemas/WritableId' company_name: $ref: '#/components/schemas/CompanyName' display_name: type: string title: Location display name description: The display name of the location. example: 11 UT - South Jordan nullable: true status: type: string title: Location status description: Based on the status some functionality is enabled or disabled. x-apideck-enum-id: location.status enum: - active - inactive example: active addresses: type: array items: $ref: '#/components/schemas/Address' subsidiaries: type: array items: $ref: '#/components/schemas/SubsidiaryReference' custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' Meta: type: object x-apideck-schema-id: Meta description: Response metadata properties: items_on_page: type: integer description: Number of items returned in the data property of the response example: 50 cursors: type: object description: Cursors to navigate to previous or next pages through the API properties: previous: type: string description: Cursor to navigate to the previous page of results through the API example: em9oby1jcm06OnBhZ2U6OjE= nullable: true current: type: string description: Cursor to navigate to the current page of results through the API example: em9oby1jcm06OnBhZ2U6OjI= nullable: true next: type: string description: Cursor to navigate to the next page of results through the API example: em9oby1jcm06OnBhZ2U6OjM= nullable: true MiddleName: type: string title: Middle name description: Middle name of the person. example: D. nullable: true NotFoundResponse: type: object x-apideck-schema-id: NotFound properties: status_code: type: number description: HTTP status code example: 404 error: type: string description: Contains an explanation of the status_code as defined in HTTP/1.1 standard (RFC 7231) example: Not Found type_name: type: string description: The type of error returned example: EntityNotFoundError message: type: string description: A human-readable message providing more details about the error. example: Unknown Widget x-speakeasy-error-message: true detail: anyOf: - type: string example: "Could not find widget with id: '123'" - type: object additionalProperties: true example: not_found: entity: widget id: '123' description: Contains parameter or domain specific information related to the error and why it occurred. ref: type: string description: Link to documentation of error type example: https://developers.apideck.com/errors#entitynotfounderror NotImplementedResponse: type: object x-apideck-schema-id: NotImplemented properties: status_code: type: number description: HTTP status code example: 501 error: type: string description: Contains an explanation of the status_code as defined in HTTP/1.1 standard (RFC 7231) example: Not Implemented type_name: type: string description: The type of error returned example: MappingError message: type: string description: A human-readable message providing more details about the error. example: Unmapped Attribute x-speakeasy-error-message: true detail: anyOf: - type: string example: Failed to retrieve Widget tokenUrl from 'components.securitySchemes.OAuth2.flows' - type: object additionalProperties: true description: Contains parameter or domain specific information related to the error and why it occurred. ref: type: string description: Link to documentation of error type example: https://developers.apideck.com/errors#mappingerror PassThroughBody: type: array description: The pass_through property allows passing service-specific, custom data or structured modifications in request body when creating or updating resources. items: type: object properties: service_id: type: string description: Identifier for the service to which this pass_through should be applied. operation_id: type: string description: Optional identifier for a workflow operation to which this pass_through should be applied. This is useful for Unify calls that are making more than one downstream request. extend_object: type: object additionalProperties: true description: Simple object allowing any properties for direct extension. extend_paths: type: array description: Array of objects for structured data modifications via paths. items: type: object properties: path: type: string description: JSONPath string specifying where to apply the value. example: $.nested.property value: description: The value to set at the specified path, can be any type. example: TaxClassificationRef: value: EUC-99990201-V1-00020000 required: - path - value additionalProperties: false required: - service_id additionalProperties: false writeOnly: true PassThroughQuery: type: object additionalProperties: true properties: example_downstream_property: type: string description: All passthrough query parameters are passed along to the connector as is (?pass_through[search]=leads becomes ?search=leads) example: search: San Francisco Payment: type: object x-apideck-schema-id: Payment x-apideck-weights: id: critical downstream_id: medium currency: critical currency_rate: medium total_amount: critical reference: medium payment_method: medium payment_method_reference: medium payment_method_id: edge-case accounts_receivable_account_type: edge-case accounts_receivable_account_id: edge-case account: critical transaction_date: critical customer: high supplier: high company_id: medium reconciled: low status: high type: high allocations: critical note: low number: medium tracking_categories: low custom_fields: medium row_version: edge-case display_id: low updated_by: edge-case created_by: edge-case created_at: medium updated_at: medium required: - id - total_amount - transaction_date x-apideck-strict-required: - total_amount - transaction_date - allocations additionalProperties: false properties: id: $ref: '#/components/schemas/Id' downstream_id: $ref: '#/components/schemas/DownstreamId' currency: $ref: '#/components/schemas/Currency' currency_rate: $ref: '#/components/schemas/CurrencyRate' total_amount: $ref: '#/components/schemas/TotalAmount' reference: $ref: '#/components/schemas/TransactionReference' payment_method: $ref: '#/components/schemas/PaymentMethod' payment_method_reference: $ref: '#/components/schemas/PaymentMethodReference' payment_method_id: $ref: '#/components/schemas/WritableId' accounts_receivable_account_type: deprecated: true type: string title: Type of accounts receivable account description: Type of accounts receivable account. example: Account nullable: true accounts_receivable_account_id: deprecated: true type: string title: Accounts receivable account id description: Unique identifier for the account to allocate payment to. example: '123456' nullable: true account: $ref: '#/components/schemas/LinkedLedgerAccount' transaction_date: $ref: '#/components/schemas/TransactionDate' customer: $ref: '#/components/schemas/LinkedCustomer' supplier: $ref: '#/components/schemas/DeprecatedLinkedSupplier' company_id: $ref: '#/components/schemas/AccountingCompanyId' reconciled: $ref: '#/components/schemas/IsReconciled' status: $ref: '#/components/schemas/PaymentStatus' type: $ref: '#/components/schemas/PaymentType' allocations: type: array items: $ref: '#/components/schemas/Allocation' note: $ref: '#/components/schemas/TransactionNote' number: $ref: '#/components/schemas/TransactionNumber' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' custom_fields: type: array items: $ref: '#/components/schemas/CustomField' row_version: $ref: '#/components/schemas/RowVersion' display_id: $ref: '#/components/schemas/DisplayId' custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' created_at: $ref: '#/components/schemas/CreatedAt' updated_at: $ref: '#/components/schemas/UpdatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' PaymentMethod: type: string title: Payment method description: Payment method used for the transaction, such as cash, credit card, bank transfer, or check nullable: true example: cash PaymentRequiredResponse: type: object x-apideck-schema-id: PaymentRequired properties: status_code: type: number description: HTTP status code example: 402 error: type: string description: Contains an explanation of the status_code as defined in HTTP/1.1 standard (RFC 7231) example: Payment Required type_name: type: string description: The type of error returned example: RequestLimitError message: type: string description: A human-readable message providing more details about the error. example: Request Limit Reached x-speakeasy-error-message: true detail: type: string description: Contains parameter or domain specific information related to the error and why it occurred. example: You have reached your limit of 2000 ref: type: string description: Link to documentation of error type example: https://developers.apideck.com/errors#requestlimiterror PaymentsFilter: type: object x-apideck-schema-id: PaymentsFilter x-graphql-type-name: PaymentsFilter example: updated_since: '2020-09-30T07:43:32.000Z' properties: updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' additionalProperties: false PaymentsSort: type: object x-apideck-schema-id: PaymentsSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: payments.sort_by description: The field on which to sort the Payments enum: - updated_at - created_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false PhoneNumber: type: object x-apideck-schema-id: PhoneNumber required: - number additionalProperties: false x-apideck-weights: number: critical type: critical id: edge-case country_code: edge-case area_code: edge-case extension: edge-case properties: id: type: string description: Unique identifier of the phone number example: '12345' nullable: true country_code: title: Country code description: The country code of the phone number, e.g. +1 type: string example: '1' nullable: true area_code: title: Area code description: The area code of the phone number, e.g. 323 type: string example: '323' nullable: true number: type: string title: Phone number description: The phone number example: 111-111-1111 minLength: 1 extension: type: string title: Phone extension description: The extension of the phone number example: '105' nullable: true type: type: string description: The type of phone number x-apideck-enum-id: phone_numbers.type enum: - primary - secondary - home - work - office - mobile - assistant - fax - direct-dial-in - personal - other example: primary nullable: true ProfitAndLoss: type: object x-apideck-schema-id: ProfitAndLoss x-apideck-circular-ref: true x-apideck-weights: id: medium report_name: medium start_date: low end_date: low currency: critical customer: low income: critical expenses: critical net_income: medium net_operating_income: medium gross_profit: medium additionalProperties: false required: - report_name - currency - income - expenses properties: id: $ref: '#/components/schemas/Id' report_name: type: string description: The name of the report title: Report Name example: ProfitAndLoss start_date: type: string description: The start date of the report title: Start Date pattern: ^\d{4}-\d{2}-\d{2}$ example: '2017-01-01' end_date: type: string description: The start date of the report title: Start Date pattern: ^\d{4}-\d{2}-\d{2}$ example: '2017-01-01' currency: type: string title: Currency example: USD customer_id: type: string description: Customer id title: Customer Id example: '123' income: x-apideck-weights: total: critical record: critical type: object required: - total - records example: total: 200000 records: - id: '123' name: Income 1 amount: 10000 - id: '456' name: Income 2 amount: 20000 properties: total: type: number description: Total income title: Total income nullable: true example: 100000 records: $ref: '#/components/schemas/ProfitAndLossRecords' expenses: x-apideck-weights: total: critical record: critical type: object required: - total - records example: total: 200000 records: - id: '123' name: Expense 1 amount: 10000 - id: '456' name: Expense 2 amount: 20000 properties: total: type: number description: Total expense title: Total expense nullable: true example: 100000 records: $ref: '#/components/schemas/ProfitAndLossRecords' net_income: x-apideck-weights: total: critical record: critical type: object required: - total - records example: total: 200000 nullable: true properties: total: type: number description: Total net income title: Total net income nullable: true example: 100000 records: $ref: '#/components/schemas/ProfitAndLossRecords' net_operating_income: x-apideck-weights: total: critical record: critical type: object required: - total - records example: total: 200000 nullable: true properties: total: type: number description: Total net operating income title: Total net operating income nullable: true example: 100000 records: $ref: '#/components/schemas/ProfitAndLossRecords' gross_profit: x-apideck-weights: total: critical record: critical type: object required: - total - records example: total: 200000 nullable: true properties: total: type: number description: Total gross profit title: Total gross profit nullable: true example: 100000 records: $ref: '#/components/schemas/ProfitAndLossRecords' custom_mappings: $ref: '#/components/schemas/CustomMappings' ProfitAndLossFilter: type: object x-apideck-schema-id: ProfitAndLossFilter example: customer_id: 123abc start_date: '2021-01-01' end_date: '2021-12-31' properties: customer_id: type: string title: Customer Id description: Filter by customer id example: 123abc start_date: type: string title: Start date description: Filter by start date. If start date is given, end date is required. example: '2021-01-01' end_date: type: string title: End date description: Filter by end date. If end date is given, start date is required. example: '2021-12-31' additionalProperties: false ProfitAndLossRecord: type: object x-apideck-schema-id: ProfitAndLossRecord x-apideck-weights: type: critical required: - type example: type: Record properties: id: type: string example: 123abc nullable: true title: type: string example: Income nullable: true type: type: string example: Record value: type: number example: 23992.34 nullable: true ProfitAndLossRecords: type: array x-apideck-schema-id: ProfitAndLossRecords title: ProfitAndLossRecords x-speakeasy-type-override: any nullable: true items: anyOf: - $ref: '#/components/schemas/ProfitAndLossSection' - $ref: '#/components/schemas/ProfitAndLossRecord' ProfitAndLossSection: type: object x-apideck-schema-id: ProfitAndLossSection x-apideck-weights: id: medium title: medium type: critical total: medium records: medium required: - type example: total: 200000 properties: id: type: string example: 123abc nullable: true title: type: string example: Income nullable: true type: type: string example: Section total: type: number example: 23992.34 nullable: true records: $ref: '#/components/schemas/ProfitAndLossRecords' PurchaseOrder: type: object x-apideck-schema-id: PurchaseOrder additionalProperties: false x-apideck-weights: id: critical downstream_id: low po_number: low reference: low supplier: high company_id: middle status: critical issued_date: edge-case delivery_date: medium expected_arrival_date: medium currency: medium currency_rate: low sub_total: high total_tax: high total: critical tax_inclusive: low line_items: critical shipping_address: medium ledger_account: edge-case template_id: low discount_percentage: low bank_account: low accounting_by_row: edge-case due_date: low payment_method: low tax_code: medium channel: low memo: low tracking_categories: low row_version: edge-case updated_by: low created_by: low created_at: high updated_at: high properties: id: $ref: '#/components/schemas/Id' downstream_id: $ref: '#/components/schemas/DownstreamId' po_number: type: string title: Purchase Order number description: A PO Number uniquely identifies a purchase order and is generally defined by the buyer. example: '90000117' nullable: true reference: type: string title: Purchase order reference description: Optional purchase order reference. example: '123456' nullable: true supplier: $ref: '#/components/schemas/LinkedSupplier' company_id: $ref: '#/components/schemas/AccountingCompanyId' status: type: string title: Purchase order status example: open x-apideck-enum-id: purchase-orders.status enum: - draft - open - closed - deleted - billed - other nullable: true issued_date: type: string title: Posted date description: Date purchase order was issued - YYYY-MM-DD. format: date example: '2020-09-30' nullable: true delivery_date: type: string title: Delivery date description: The date on which the purchase order is to be delivered - YYYY-MM-DD. format: date example: '2020-09-30' nullable: true expected_arrival_date: type: string title: Expected arrival date description: The date on which the order is expected to arrive - YYYY-MM-DD. format: date example: '2020-09-30' nullable: true currency: $ref: '#/components/schemas/Currency' currency_rate: $ref: '#/components/schemas/CurrencyRate' sub_total: title: Sub-total amount description: Sub-total amount, normally before tax. type: number example: 27500 nullable: true total_tax: type: number title: Total tax amount description: Total tax amount applied to this invoice. example: 2500 nullable: true total: type: number title: Total amount description: Total amount of invoice, including tax. example: 27500 nullable: true tax_inclusive: $ref: '#/components/schemas/TaxInclusive' line_items: type: array items: $ref: '#/components/schemas/InvoiceLineItem' shipping_address: $ref: '#/components/schemas/Address' ledger_account: $ref: '#/components/schemas/LinkedLedgerAccount' template_id: type: string title: Template description: Optional purchase order template example: '123456' nullable: true discount_percentage: $ref: '#/components/schemas/DiscountPercentage' bank_account: $ref: '#/components/schemas/BankAccount' accounting_by_row: $ref: '#/components/schemas/AccountingByRow' due_date: $ref: '#/components/schemas/DueDate' payment_method: $ref: '#/components/schemas/PaymentMethod' tax_code: $ref: '#/components/schemas/TaxCode' channel: $ref: '#/components/schemas/Channel' memo: type: string title: Memo description: Message for the supplier. This text appears on the Purchase Order. example: Thank you for the partnership and have a great day! nullable: true tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' PurchaseOrdersFilter: type: object x-apideck-schema-id: PurchaseOrdersFilter example: updated_since: '2020-09-30T07:43:32.000Z' supplier_id: '1234' properties: updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' supplier_id: type: string title: Supplier ID example: '1234' additionalProperties: false PurchaseOrdersSort: type: object x-apideck-schema-id: PurchaseOrdersSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: purchase_orders.sort_by description: The field on which to sort the Purchase Orders enum: - updated_at - created_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false Quantity: type: number title: Quantity example: 1 nullable: true RowVersion: type: string title: Row version description: A binary value used to detect updates to a object and prevent data conflicts. It is incremented each time an update is made to the object. example: 1-12345 nullable: true SalesTaxNumber: type: string title: Sales Tax Number example: 111.222.333 nullable: true SocialLink: type: object x-apideck-schema-id: SocialLink required: - url additionalProperties: false x-apideck-weights: id: edge-case url: critical type: critical properties: id: description: Unique identifier of the social link type: string example: '12345' nullable: true url: description: URL of the social link, e.g. https://www.twitter.com/apideck type: string example: https://www.twitter.com/apideck minLength: 1 type: description: Type of the social link, e.g. twitter type: string example: twitter nullable: true SortDirection: type: string x-apideck-schema-id: SortDirection description: The direction in which to sort the results x-apideck-enum-id: sort_direction enum: - asc - desc default: asc Subsidiary: type: object x-apideck-schema-id: Subsidiary x-apideck-weights: id: medium name: critical status: critical additionalProperties: false properties: id: $ref: '#/components/schemas/Id' parent_id: $ref: '#/components/schemas/WritableId' name: $ref: '#/components/schemas/CompanyName' status: type: string title: Subsidiary status description: Based on the status some functionality is enabled or disabled. x-apideck-enum-id: subsidiary.status enum: - active - inactive example: active custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' SubsidiaryReference: type: object x-apideck-schema-id: SubsidiaryReference x-apideck-weights: id: critical name: low additionalProperties: false properties: id: $ref: '#/components/schemas/Id' name: $ref: '#/components/schemas/CompanyName' Suffix: type: string title: Suffix example: Jr. nullable: true Supplier: type: object x-apideck-schema-id: Supplier x-apideck-weights: id: critical downstream_id: edge-case display_id: edge-case display_name: edge-case company_name: high company_id: middle title: high first_name: high middle_name: low last_name: high suffix: low individual: medium addresses: high phone_numbers: high emails: high websites: medium bank_accounts: high notes: low tax_rate: medium tax_number: medium currency: medium account: medium status: high payment_method: edge-case channel: edge-case updated_by: edge-case created_by: edge-case updated_at: medium created_at: medium row_version: edge-case additionalProperties: false required: - id x-apideck-strict-required: - emails - addresses - phone_numbers - status - updated_at x-apideck-strict-any-of: - required: - first_name - last_name - required: - company_name properties: id: $ref: '#/components/schemas/Id' downstream_id: $ref: '#/components/schemas/DownstreamId' display_id: type: string title: Display ID description: Display ID example: EMP00101 nullable: true display_name: type: string title: Display Name description: Display name example: Windsurf Shop nullable: true company_name: $ref: '#/components/schemas/CompanyName' company_id: $ref: '#/components/schemas/AccountingCompanyId' title: $ref: '#/components/schemas/Title' first_name: $ref: '#/components/schemas/FirstName' middle_name: $ref: '#/components/schemas/MiddleName' last_name: $ref: '#/components/schemas/LastName' suffix: $ref: '#/components/schemas/Suffix' individual: type: boolean title: Is individual description: Is this an individual or business supplier example: true nullable: true addresses: type: array items: $ref: '#/components/schemas/Address' phone_numbers: type: array items: $ref: '#/components/schemas/PhoneNumber' emails: type: array items: $ref: '#/components/schemas/Email' websites: type: array items: $ref: '#/components/schemas/Website' bank_accounts: type: array items: $ref: '#/components/schemas/BankAccount' notes: type: string title: Notes description: Some notes about this supplier example: Some notes about this supplier nullable: true tax_rate: $ref: '#/components/schemas/LinkedTaxRate' tax_number: $ref: '#/components/schemas/TaxNumber' currency: $ref: '#/components/schemas/Currency' account: $ref: '#/components/schemas/LinkedLedgerAccount' status: type: string title: Status description: Supplier status nullable: true example: active x-apideck-enum-id: suppliers.status enum: - active - inactive - archived - gdpr-erasure-request - unknown payment_method: $ref: '#/components/schemas/PaymentMethod' channel: $ref: '#/components/schemas/Channel' custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' row_version: $ref: '#/components/schemas/RowVersion' pass_through: $ref: '#/components/schemas/PassThroughBody' SuppliersFilter: type: object x-apideck-schema-id: SuppliersFilter example: company_name: SpaceX display_name: Elon Musk first_name: Elon last_name: Musk email: elon@musk.com updated_since: '2020-09-30T07:43:32.000Z' properties: company_name: type: string title: Company Name description: Company Name of supplier to search for example: SpaceX display_name: type: string title: Display Name description: Display Name of supplier to search for example: Techno King first_name: type: string title: First Name description: First name of supplier to search for example: Elon last_name: type: string title: Last Name description: Last name of supplier to search for example: Musk email: type: string title: Email description: Email of supplier to search for example: elon@spacex.com updated_since: type: string title: Updated since (timestamp) format: date-time example: '2020-09-30T07:43:32.000Z' additionalProperties: false SuppliersSort: type: object x-apideck-schema-id: SuppliersSort example: by: updated_at direction: desc properties: by: type: string x-apideck-enum-id: suppliers.sort_by description: The field on which to sort the Suppliers enum: - created_at - updated_at example: updated_at direction: $ref: '#/components/schemas/SortDirection' additionalProperties: false Tags: type: array x-apideck-schema-id: Tags items: type: string example: - New nullable: true CustomMappings: type: object x-apideck-schema-id: CustomMappings description: When custom mappings are configured on the resource, the result is included here. nullable: true readOnly: true TaxCode: type: string title: Tax Code description: Applicable tax id/code override if tax is not supplied on a line item basis. example: '1234' nullable: true TaxInclusive: type: boolean title: Tax inclusive description: Amounts are including tax example: true nullable: true TaxNumber: type: string title: Tax number example: US123945459 nullable: true TaxRate: type: object x-apideck-schema-id: TaxRate x-apideck-weights: id: critical name: high code: edge-case description: low effective_tax_rate: critical total_tax_rate: high tax_payable_account_id: high tax_remitted_account_id: medium components: medium type: high report_tax_type: edge-case original_tax_rate_id: edge-case status: high updated_by: edge-case created_by: edge-case updated_at: medium created_at: low row_version: edge-case additionalProperties: false x-apideck-strict-required: - effective_tax_rate x-apideck-strict-any-of: - required: - id - required: - name - required: - code properties: id: type: string description: ID assigned to identify this tax rate. example: '1234' nullable: true name: type: string title: Name description: Name assigned to identify this tax rate. example: GST on Purchases minLength: 1 code: type: string example: ABN title: Tax code description: Tax code assigned to identify this tax rate. nullable: true description: type: string title: Description description: Description of tax rate example: Reduced rate GST Purchases nullable: true effective_tax_rate: type: number title: Effective tax rate description: Effective tax rate example: 10 nullable: true total_tax_rate: type: number title: Total tax rate description: Not compounded sum of the components of a tax rate example: 10 nullable: true tax_payable_account_id: type: string title: Tax payable account id description: Unique identifier for the account for tax collected. example: '123456' nullable: true tax_remitted_account_id: type: string title: Tax remitted account id description: Unique identifier for the account for tax remitted. example: '123456' nullable: true components: type: array title: Tax components items: x-apideck-weights: id: medium name: medium rate: medium compound: medium properties: id: type: string title: TaxRate Id example: '10' nullable: true name: type: string example: GST minLength: 1 rate: type: number title: TaxRate example: 10 nullable: true compound: type: boolean title: Compound example: true nullable: true nullable: true type: type: string title: Tax Type description: Tax type used to indicate the source of tax collected or paid example: NONE nullable: true report_tax_type: type: string title: Report Tax Type description: Report Tax type to aggregate tax collected or paid for reporting purposes example: NONE nullable: true original_tax_rate_id: type: string title: Original tax rate ID description: ID of the original tax rate from which the new tax rate is derived. Helps to understand the relationship between corresponding tax rate entities. example: '12345' nullable: true status: type: string x-apideck-enum-id: tax-rates.status enum: - active - inactive - archived title: Tax rate status description: Tax rate status example: active nullable: true custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' TaxRatesFilter: type: object x-apideck-schema-id: TaxRatesFilter example: assets: true equity: true expenses: true liabilities: true revenue: true properties: assets: type: boolean title: Assets description: Boolean to describe if tax rate can be used for asset accounts example: true equity: type: boolean title: Equity description: Boolean to describe if tax rate can be used for equity accounts example: true expenses: type: boolean title: Expenses description: Boolean to describe if tax rate can be used for expense accounts example: true liabilities: type: boolean title: Liabilities description: Boolean to describe if tax rate can be used for liability accounts example: true revenue: type: boolean title: Revenue description: Boolean to describe if tax rate can be used for revenue accounts example: true additionalProperties: false Title: type: string title: Job title description: The job title of the person. example: CEO nullable: true TooManyRequestsResponse: type: object x-apideck-schema-id: TooManyRequests properties: status_code: type: number description: HTTP status code example: 429 error: type: string description: Contains an explanation of the status_code as defined in HTTP/1.1 standard (RFC 6585) example: Too Many Requests type_name: type: string description: The type of error returned example: ConnectorRateLimitError message: type: string description: A human-readable message providing more details about the error. example: Connector Rate Limit Error x-speakeasy-error-message: true detail: type: object properties: context: type: string error: type: object additionalProperties: true ref: type: string description: Link to documentation of error type example: https://developers.apideck.com/errors#connectorratelimiterror UnauthorizedResponse: type: object x-apideck-schema-id: Unauthorized properties: status_code: type: number description: HTTP status code example: 401 error: type: string description: Contains an explanation of the status_code as defined in HTTP/1.1 standard (RFC 7231) example: Unauthorized type_name: type: string description: The type of error returned example: UnauthorizedError message: type: string description: A human-readable message providing more details about the error. example: Unauthorized Request x-speakeasy-error-message: true detail: anyOf: - type: string example: Missing authentication - type: object additionalProperties: true example: statusCode: 401 error: Unauthorized message: Missing authentication description: Contains parameter or domain specific information related to the error and why it occurred. ref: type: string description: Link to documentation of error type example: https://developers.apideck.com/errors#unauthorizederror UnexpectedErrorResponse: type: object x-apideck-schema-id: Error properties: status_code: type: number description: HTTP status code example: 400 error: type: string description: Contains an explanation of the status_code as defined in HTTP/1.1 standard (RFC 7231) example: Bad Request type_name: type: string description: The type of error returned example: RequestHeadersValidationError message: type: string description: A human-readable message providing more details about the error. example: Invalid Params x-speakeasy-error-message: true detail: anyOf: - type: string example: 'Missing Header: x-apideck-consumer-id' - type: object additionalProperties: true example: missing: - x-apideck-consumer-id: required description: Contains parameter or domain specific information related to the error and why it occurred. ref: type: string description: Link to documentation of error type example: https://developers.apideck.com/errors#unauthorizederror UnifiedId: title: UnifiedId type: object x-apideck-schema-id: Id required: - id properties: id: title: Id description: The unique identifier of the resource type: string readOnly: true example: '12345' UnitOfMeasure: type: string title: Unit of measure description: 'Description of the unit type the item is sold as, ie: kg, hour.' example: pc. nullable: true UnitPrice: type: number title: Unit price example: 27500.5 nullable: true UnprocessableResponse: type: object x-apideck-schema-id: Unprocessable properties: status_code: type: number description: HTTP status code example: 422 error: type: string description: Contains an explanation of the status_code as defined in HTTP/1.1 standard (RFC 7231) example: Unprocessable Entity type_name: type: string description: The type of error returned example: InvalidStateError message: type: string description: A human-readable message providing more details about the error. example: Invalid State x-speakeasy-error-message: true detail: anyOf: - type: string example: Unprocessable request, please verify your request headers and body. - type: object additionalProperties: true example: error: Unprocessable message: Unprocessable request, please verify your request headers and body. description: Contains parameter or domain specific information related to the error and why it occurred. ref: type: string description: Link to documentation of error type example: https://developers.apideck.com/errors#invalidstateerror UpdateBillResponse: type: object x-apideck-schema-id: UpdateBillResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: bills operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdateCreditNoteResponse: type: object x-apideck-schema-id: UpdateCreditNoteResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: credit-notes operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdateCustomerResponse: type: object x-apideck-schema-id: UpdateCustomerResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: customers operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdateInvoiceItemsResponse: type: object x-apideck-schema-id: UpdateInvoiceItemsResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoice-items operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdateInvoiceResponse: type: object x-apideck-schema-id: UpdateInvoiceResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: invoices operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/InvoiceResponse' UpdateJournalEntryResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: journal-entries operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdateLedgerAccountResponse: type: object x-apideck-schema-id: UpdateLedgerAccountResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: ledger-accounts operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdatePaymentResponse: type: object x-apideck-schema-id: UpdatePaymentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdatePurchaseOrderResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: PurchaseOrders operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdateSubsidiaryResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: subsidiaries operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdateSupplierResponse: type: object x-apideck-schema-id: UpdateSupplierResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: suppliers operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdateTaxRateResponse: type: object x-apideck-schema-id: UpdateTaxRateResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: tax-rates operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' UpdatedAt: type: string title: Updated at (timestamp) description: The date and time when the object was last updated. format: date-time example: '2020-09-30T07:43:32.000Z' readOnly: true nullable: true UpdatedBy: type: string title: Updated by description: The user who last updated the object. example: '12345' readOnly: true nullable: true Website: type: object x-apideck-schema-id: Website required: - url additionalProperties: false x-apideck-weights: url: critical type: critical id: edge-case properties: id: description: Unique identifier for the website type: string example: '12345' nullable: true url: description: The website URL type: string example: http://example.com minLength: 1 type: description: The type of website type: string x-apideck-enum-id: websites.type enum: - primary - secondary - work - personal - other example: primary nullable: true WritableId: type: string title: ID description: A unique identifier for an object. example: '12345' readOnly: false nullable: true Attachment: type: object x-apideck-schema-id: Attachment x-apideck-weights: id: critical display_id: edge-case name: critical mime_type: medium size: medium reference: critical description: medium folder_id: edge-case updated_by: edge-case created_by: edge-case updated_at: medium created_at: medium additionalProperties: false properties: id: $ref: '#/components/schemas/Id' display_id: type: string description: The display id of the file example: sample ID nullable: true name: type: string description: The name of the file example: sample.jpg nullable: true mime_type: type: string description: The MIME type of the file. example: image/jpeg nullable: true size: type: integer x-apideck-schema-id: AttachmentSize description: The size of the file in bytes example: 1810673 nullable: true reference: $ref: '#/components/schemas/AttachmentReference' description: type: string description: Optional description of the file example: A sample image nullable: true parent_folder_id: type: string description: The folder id where this attachment belong to example: '123' nullable: true updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' AttachmentReference: type: object x-apideck-schema-id: AttachmentReference properties: type: $ref: '#/components/schemas/AttachmentReferenceType' id: $ref: '#/components/schemas/Id' additionalProperties: false AttachmentReferenceType: x-apideck-enum-id: attachment.reference_type type: string enum: - invoice - bill - expense GetAttachmentsResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: PurchaseOrders operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/Attachment' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' CreateAttachmentRequest: type: object x-apideck-schema-id: CreateAttachmentRequest additionalProperties: false required: - name properties: name: type: string description: The name of the file example: sample.jpg description: type: string description: Optional description of the file. example: My Personal Documents parent_folder_id: type: string description: The folder id where this attachment belong to example: '123' pass_through: $ref: '#/components/schemas/PassThroughBody' CreateAttachmentResponse: type: object x-apideck-schema-id: CreateAttachmentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: google-drive resource: type: string description: Unified API resource name example: files operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' DeleteAttachmentResponse: type: object x-apideck-schema-id: DeleteAttachmentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: google-drive resource: type: string description: Unified API resource name example: files operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' GetAttachmentResponse: type: object x-apideck-schema-id: GetAttachmentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/Attachment' Allocation: type: object x-apideck-schema-id: Allocation x-apideck-weights: id: medium type: medium code: medium amount: medium allocation_id: medium x-apideck-strict-any-of: - required: - id - required: - code properties: id: type: string title: Linked entity ID description: Unique identifier of entity this payment should be attributed to. example: '123456' type: type: string title: Allocation type description: Type of entity this payment should be attributed to. x-apideck-enum-id: allocations.type enum: - invoice - order - expense - credit_memo - over_payment - pre_payment - journal_entry - other - bill code: type: string example: N091 readOnly: true amount: type: number title: Amount description: Amount of payment that should be attributed to this allocation. If null, the total_amount will be used. example: 49.99 nullable: true allocation_id: type: string title: Allocation ID description: Unique identifier of the allocation example: '123456' TrackingCategory: type: object x-apideck-schema-id: TrackingCategory x-apideck-weights: id: medium parent_id: low name: critical status: critical code: low additionalProperties: false properties: id: $ref: '#/components/schemas/Id' parent_id: $ref: '#/components/schemas/WritableId' name: type: string description: The name of the tracking category. example: Department nullable: false code: type: string description: The code of the tracking category. example: '100' nullable: true status: type: string title: Tracking Category status description: Based on the status some functionality is enabled or disabled. x-apideck-enum-id: tracking_categories.status enum: - active - inactive example: active custom_mappings: $ref: '#/components/schemas/CustomMappings' row_version: $ref: '#/components/schemas/RowVersion' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' GetTrackingCategoryResponse: type: object x-apideck-schema-id: GetTrackingCategoryResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: tracking-categories operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/TrackingCategory' GetTrackingCategoriesResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: tracking-categories operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/TrackingCategory' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' CreateTrackingCategoryResponse: type: object x-apideck-schema-id: CreateTrackingCategoryResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: tracking-categories operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' UpdateTrackingCategoryResponse: type: object x-apideck-schema-id: UpdateTrackingCategoryResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: tracking-categories operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' DeleteTrackingCategoryResponse: type: object x-apideck-schema-id: DeleteTrackingCategoryResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: tracking-categories operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' LinkedTrackingCategories: type: array x-apideck-schema-id: LinkedTrackingCategories title: Linked tracking categories description: A list of linked tracking categories. nullable: true items: $ref: '#/components/schemas/LinkedTrackingCategory' LineNumber: title: Line number type: integer description: Line number of the resource example: 1 nullable: true AccountingPeriod: type: string title: Accounting period description: Accounting period example: 01-24 nullable: true TotalAmount: title: Total Amount description: The total amount of the transaction type: number example: 49.99 nullable: true TransactionReference: title: Transaction Reference description: 'Optional transaction reference message ie: Debit remittance detail.' type: string example: '123456' nullable: true PaymentMethodReference: type: string title: Payment method reference description: Optional reference message returned by payment method on processing nullable: true example: '123456' TransactionDate: title: Transaction Date description: The date of the transaction - YYYY:MM::DDThh:mm:ss.sTZD type: string format: date-time example: '2021-05-01T12:00:00.000Z' nullable: true DeprecatedLinkedSupplier: type: object x-apideck-schema-id: DeprecatedLinkedSupplier title: Linked Supplier description: The supplier this entity is linked to. x-apideck-weights: id: medium display_id: medium display_name: high company_name: edge-case address: low nullable: true deprecated: true properties: id: $ref: '#/components/schemas/Id' display_id: type: string title: Display ID description: The display ID of the supplier. example: SUPP00101 nullable: true readOnly: true display_name: type: string title: Display Name description: The display name of the supplier. example: Windsurf Shop nullable: true company_name: type: string title: Company Name description: The company name of the supplier. example: The boring company nullable: true readOnly: true address: $ref: '#/components/schemas/Address' IsReconciled: title: Is Reconciled description: Indicates if the transaction has been reconciled. type: boolean example: true nullable: true PaymentStatus: type: string title: Payment status description: Status of payment x-apideck-enum-id: payments.status enum: - authorised - paid - voided - deleted example: authorised PaymentType: type: string title: Payment Type description: Type of payment x-apideck-enum-id: payments.type enum: - accounts_receivable - accounts_payable - accounts_receivable_credit - accounts_payable_credit - accounts_receivable_overpayment - accounts_payable_overpayment - accounts_receivable_prepayment - accounts_payable_prepayment example: accounts_receivable TransactionNote: type: string title: Transaction note description: Note associated with the transaction example: Some notes about this transaction nullable: true TransactionNumber: type: string title: Transaction number description: Number associated with the transaction example: '123456' nullable: true GetBillPaymentResponse: type: object x-apideck-schema-id: GetBillPaymentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/BillPayment' GetBillPaymentsResponse: type: object x-apideck-schema-id: GetPaymentsResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/BillPayment' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' CreateBillPaymentResponse: type: object x-apideck-schema-id: CreateBillPaymentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' UpdateBillPaymentResponse: type: object x-apideck-schema-id: UpdateBillPaymentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' DeleteBillPaymentResponse: type: object x-apideck-schema-id: DeleteBillPaymentResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: xero resource: type: string description: Unified API resource name example: payments operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' BillPayment: type: object x-apideck-schema-id: BillPayment x-apideck-weights: id: critical downstream_id: medium currency: critical currency_rate: medium total_amount: critical reference: medium payment_method: medium payment_method_reference: medium payment_method_id: edge-case account: critical transaction_date: critical customer: high supplier: high company_id: medium reconciled: low status: high type: high allocations: critical note: low number: medium tracking_categories: low custom_fields: medium row_version: edge-case display_id: low updated_by: edge-case created_by: edge-case created_at: medium updated_at: medium required: - id - total_amount - transaction_date x-apideck-strict-required: - total_amount - transaction_date - allocations additionalProperties: false properties: id: $ref: '#/components/schemas/Id' downstream_id: $ref: '#/components/schemas/DownstreamId' currency: $ref: '#/components/schemas/Currency' currency_rate: $ref: '#/components/schemas/CurrencyRate' total_amount: $ref: '#/components/schemas/TotalAmount' reference: $ref: '#/components/schemas/TransactionReference' payment_method: $ref: '#/components/schemas/PaymentMethod' payment_method_reference: $ref: '#/components/schemas/PaymentMethodReference' payment_method_id: $ref: '#/components/schemas/WritableId' account: $ref: '#/components/schemas/LinkedLedgerAccount' transaction_date: $ref: '#/components/schemas/TransactionDate' supplier: $ref: '#/components/schemas/LinkedSupplier' company_id: $ref: '#/components/schemas/AccountingCompanyId' reconciled: $ref: '#/components/schemas/IsReconciled' status: $ref: '#/components/schemas/PaymentStatus' type: type: string title: Bill payment Type description: Type of payment x-apideck-enum-id: bill-payments.type enum: - accounts_payable_credit - accounts_payable_overpayment - accounts_payable_prepayment - accounts_payable example: accounts_payable allocations: type: array items: type: object x-apideck-schema-id: Allocation x-apideck-weights: id: medium type: medium code: medium amount: medium allocation_id: medium x-apideck-strict-any-of: - required: - id - required: - code properties: id: $ref: '#/components/schemas/WritableId' type: type: string title: Allocation type description: Type of entity this payment should be attributed to. example: bill x-apideck-enum-id: bill-payments.allocations.type enum: - bill - expense - credit_memo - over_payment - pre_payment - journal_entry - other code: type: string example: N091 readOnly: true amount: type: number title: Amount description: Amount of payment that should be attributed to this allocation. If null, the total_amount will be used. example: 49.99 nullable: true allocation_id: type: string title: Allocation ID description: Unique identifier of the allocation example: '123456' note: $ref: '#/components/schemas/TransactionNote' number: $ref: '#/components/schemas/TransactionNumber' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' custom_fields: type: array items: $ref: '#/components/schemas/CustomField' row_version: $ref: '#/components/schemas/RowVersion' display_id: $ref: '#/components/schemas/DisplayId' custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_by: $ref: '#/components/schemas/UpdatedBy' created_by: $ref: '#/components/schemas/CreatedBy' created_at: $ref: '#/components/schemas/CreatedAt' updated_at: $ref: '#/components/schemas/UpdatedAt' pass_through: $ref: '#/components/schemas/PassThroughBody' DisplayId: type: string title: Display id description: Id to be displayed. example: '123456' nullable: true CreateExpenseResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: Expenses operation: type: string description: Operation performed example: add data: $ref: '#/components/schemas/UnifiedId' DeleteExpenseResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: Expenses operation: type: string description: Operation performed example: delete data: $ref: '#/components/schemas/UnifiedId' GetExpenseResponse: type: object x-apideck-schema-id: GetExpenseResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: Expenses operation: type: string description: Operation performed example: one data: $ref: '#/components/schemas/Expense' GetExpensesResponse: type: object x-apideck-schema-id: GetExpensesResponse required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: Expenses operation: type: string description: Operation performed example: all data: type: array items: $ref: '#/components/schemas/Expense' meta: $ref: '#/components/schemas/Meta' links: $ref: '#/components/schemas/Links' Expense: type: object x-apideck-schema-id: Expense additionalProperties: false x-apideck-weights: id: critical transaction_date: critical account_id: critical supplier_id: high line_items: high currency: high type: high number: medium memo: medium customer_id: medium total_amount: medium currency_rate: edge-case company_id: edge-case updated_at: medium created_at: medium department_id: medium tax_rate: medium custom_fields: medium custom_mappings: low row_version: low pass_through: low required: - account_id - transaction_date - line_items x-apideck-strict-required: - account_id - transaction_date - line_items properties: id: $ref: '#/components/schemas/Id' number: type: string title: Number description: Number. example: OIT00546 nullable: true transaction_date: $ref: '#/components/schemas/TransactionDate' account_id: title: Account ID description: 'The unique identifier for the ledger account that this expense should be credited to. ' type: string example: '123456' customer_id: type: string title: Customer ID description: The ID of the customer this entity is linked to. Used for expenses that should be marked as billable to customers. example: '12345' supplier_id: type: string title: Supplier ID description: The ID of the supplier this entity is linked to. example: '12345' company_id: $ref: '#/components/schemas/AccountingCompanyId' department_id: type: string title: Department ID description: The ID of the department this expense is linked to. example: '12345' currency: $ref: '#/components/schemas/Currency' currency_rate: $ref: '#/components/schemas/CurrencyRate' type: type: string title: Expense type description: The type of expense. x-apideck-enum-id: expenses.type enum: - expense - refund example: expense nullable: true memo: type: string title: Memo description: The memo of the expense. example: For travel expenses incurred on 2024-05-15 nullable: true tax_rate: $ref: '#/components/schemas/LinkedTaxRate' total_amount: type: number title: Total amount description: The total amount of the expense line item. example: 275 nullable: true line_items: type: array minItems: 1 description: Expense line items linked to this expense. items: $ref: '#/components/schemas/ExpenseLineItem' custom_fields: type: array items: $ref: '#/components/schemas/CustomField' custom_mappings: $ref: '#/components/schemas/CustomMappings' updated_at: $ref: '#/components/schemas/UpdatedAt' created_at: $ref: '#/components/schemas/CreatedAt' row_version: $ref: '#/components/schemas/RowVersion' pass_through: $ref: '#/components/schemas/PassThroughBody' ExpenseLineItem: type: object x-apideck-schema-id: ExpenseLineItem additionalProperties: false x-apideck-weights: id: high description: medium total_amount: high tax_rate: medium tracking_categories: low account_id: critical customer_id: medium department_id: edge-case location_id: edge-case billable: edge-case required: - total_amount x-apideck-strict-required: - total_amount properties: id: $ref: '#/components/schemas/Id' tracking_categories: $ref: '#/components/schemas/LinkedTrackingCategories' account_id: title: Account ID description: The unique identifier for the ledger account. type: string example: '123456' customer_id: type: string title: Customer ID description: The ID of the customer this expense item is linked to. example: '12345' department_id: type: string title: Department ID description: The ID of the department this expense item is linked to. example: '12345' location_id: type: string title: Location ID description: The ID of the location this expense item is linked to. example: '12345' tax_rate: $ref: '#/components/schemas/LinkedTaxRate' description: type: string title: Description description: The expense line item description example: Travel US. nullable: true total_amount: type: number title: Total amount description: The total amount of the expense line item. example: 275 nullable: true billable: type: boolean title: Billable description: Boolean that indicates if the line item is billable or not. example: true UpdateExpenseResponse: type: object required: - status_code - status - service - resource - operation - data properties: status_code: type: integer description: HTTP Response Status Code example: 200 status: type: string description: HTTP Response Status example: OK service: type: string description: Apideck ID of service provider example: quickbooks resource: type: string description: Unified API resource name example: Expenses operation: type: string description: Operation performed example: update data: $ref: '#/components/schemas/UnifiedId' securitySchemes: apiKey: type: apiKey in: header name: Authorization description: | To use API you have to sign up and get your own API key. Unify API accounts have sandbox mode and live mode API keys. To change modes just use the appropriate key to get a live or test object. You can find your API keys on the unify settings of your Apideck app. Your Apideck application_id can also be found on the same page. Authenticate your API requests by including your test or live secret API key in the request header. - Bearer authorization header: `Authorization: Bearer "YOUR_API_KEY_HERE"` - Application id header: `x-apideck-app-id: "YOUR_APP_ID_HERE"` You should use the public keys on the SDKs and the secret keys to authenticate API requests. **Do not share or include your secret API keys on client side code.** Your API keys carry significant privileges. Please ensure to keep them 100% secure and be sure to not share your secret API keys in areas that are publicly accessible like GitHub. Learn how to set the Authorization header inside Postman https://learning.postman.com/docs/postman/sending-api-requests/authorization/#api-key Go to Unify to grab your API KEY https://app.apideck.com/unify/api-keys security: - apiKey: [] tags: - name: Bills description: '' x-apideck-resource-id: bills x-apideck-model: $ref: '#/components/schemas/Bill' - name: Company Info description: '' x-apideck-resource-id: company-info x-apideck-model: $ref: '#/components/schemas/CompanyInfo' - name: Credit Notes description: '' x-apideck-resource-id: credit-notes x-apideck-model: $ref: '#/components/schemas/CreditNote' - name: Customers description: '' x-apideck-resource-id: customers x-apideck-model: $ref: '#/components/schemas/Customer' - name: Invoices description: '' x-apideck-resource-id: invoices x-apideck-model: $ref: '#/components/schemas/Invoice' - name: Invoice Items description: Invoice items are stored from invoice lines to be used later on when creating new invoices. x-apideck-resource-id: invoice-items x-apideck-model: $ref: '#/components/schemas/InvoiceItem' - name: Ledger Accounts description: '' x-apideck-resource-id: ledger-accounts x-apideck-model: $ref: '#/components/schemas/LedgerAccount' - name: Payments description: '' x-apideck-resource-id: payments x-apideck-model: $ref: '#/components/schemas/Payment' - name: Suppliers description: '' x-apideck-resource-id: suppliers x-apideck-model: $ref: '#/components/schemas/Supplier' - name: Tax Rates description: '' x-apideck-resource-id: tax-rates x-apideck-model: $ref: '#/components/schemas/TaxRate' - name: Balance Sheet description: '' x-apideck-resource-id: balance-sheet x-apideck-model: $ref: '#/components/schemas/BalanceSheet' - name: Profit and Loss description: '' x-apideck-resource-id: profit-and-loss x-apideck-model: $ref: '#/components/schemas/ProfitAndLoss' - name: Journal Entries description: '' x-apideck-resource-id: journal-entries x-apideck-model: $ref: '#/components/schemas/JournalEntry' - name: Purchase Orders description: '' x-apideck-resource-id: purchase-orders x-apideck-model: $ref: '#/components/schemas/PurchaseOrder' - name: Subsidiaries description: '' x-apideck-resource-id: subsidiaries x-apideck-model: $ref: '#/components/schemas/Subsidiary' - name: Locations description: '' x-apideck-resource-id: locations x-apideck-model: $ref: '#/components/schemas/AccountingLocation' - name: Departments description: '' x-apideck-resource-id: departments x-apideck-model: $ref: '#/components/schemas/AccountingDepartment' - name: Attachments description: '' x-apideck-resource-id: attachments x-apideck-model: $ref: '#/components/schemas/Attachment' - name: Tracking Categories description: '' x-apideck-resource-id: tracking-categories x-apideck-model: $ref: '#/components/schemas/TrackingCategory' - name: Bill Payments description: '' x-apideck-resource-id: bill-payments x-apideck-model: $ref: '#/components/schemas/BillPayment' - name: Expenses description: '' x-apideck-resource-id: expenses x-apideck-model: $ref: '#/components/schemas/Expense' paths: /accounting/tax-rates: get: tags: - Tax Rates operationId: taxRatesAll summary: List Tax Rates description: | List Tax Rates. Note: Not all connectors return the actual rate/percentage value. In this case, only the tax code or reference is returned. Connectors Affected: Quickbooks parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/taxRatesFilter' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. - connector: quickbooks description: | In quickbooks, the tax rates resource does not support pagination. responses: '200': $ref: '#/components/responses/GetTaxRatesResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.taxRatesAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Tax Rates operationId: taxRatesAdd summary: Create Tax Rate description: Create Tax Rate parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: quickbooks description: | To create a tax rate, `effective_tax_rate`, `tax_payable_account_id`, `name` and a `component` is required. If `tax_payable_account_id` is unknown, make a proxy call to get list of TaxAgency. [TaxAgency doc](https://developer.intuit.com/app/developer/qbo/docs/api/accounting/all-entities/taxagency#query-a-taxagency) requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/TaxRate' responses: '201': $ref: '#/components/responses/CreateTaxRateResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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] } ] } ] } } try { const { data } = await apideck.accounting.taxRatesAdd(params) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/tax-rates/{id}: get: tags: - Tax Rates operationId: taxRatesOne summary: Get Tax Rate description: | Get Tax Rate. Note: Not all connectors return the actual rate/percentage value. In this case, only the tax code or reference is returned. Support will soon be added to return the actual rate/percentage by doing additional calls in the background to provide the full view of a given tax rate. Connectors Affected: Quickbooks parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetTaxRateResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.taxRatesOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Tax Rates operationId: taxRatesUpdate summary: Update Tax Rate description: Update Tax Rate parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/TaxRate' responses: '200': $ref: '#/components/responses/UpdateTaxRateResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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] } ] } ] } } try { const { data } = await apideck.accounting.taxRatesUpdate(params) console.log('API called successfully', data) } catch (error) { console.error(error) } delete: tags: - Tax Rates operationId: taxRatesDelete summary: Delete Tax Rate description: Delete Tax Rate parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteTaxRateResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.taxRatesDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/bills: get: tags: - Bills operationId: billsAll summary: List Bills description: List Bills parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/billsFilter' - $ref: '#/components/parameters/billsSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: clearbooks-uk description: Clearbooks does not support setting the pagination size. - connector: freshbooks description: The Freshbooks Bills api is currently in beta. - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. - connector: exact-online description: | Limit parameter for pagination is not supported for this resource. - connector: exact-online-nl description: | Limit parameter for pagination is not supported for this resource. - connector: exact-online-uk description: | Limit parameter for pagination is not supported for this resource. responses: '200': $ref: '#/components/responses/GetBillsResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.billsAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Bills operationId: billsAdd summary: Create Bill description: Create Bill parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: procountor-fi description: '' Procountor only accepts the following values for the language field: EN, FI, SV, ET, NO, and DA. Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: quickbooks description: | When creating a bill in QuickBooks, each line item must be accompanied by a type designation. If the type is set to "expense_item," an item ID is required. Conversely, if the type is "expense_account," a ledger account ID must be provided. Additionally, multicurrency needs to be enabled in your QBO account. If creating a bill in your default currency, you do not need to send the currency value as long as the supplier uses the same currency. For bills with suppliers using a different currency than your default, you must include the currency value, matching the supplier's configured currency. To change the currency of a customer or vendor, a new one must be created with the desired currency. Foreign currencies can only be sent to suppliers configured with that currency. - connector: netsuite description: | For creating or updating a bill in Netsuite, its required to provide the line type. - connector: microsoft-dynamics-365-business-central description: | If you encounter a '400 Bad Request' error indicating "Control 'fieldName' is read-only" it means the 'editable' property for this field in Microsoft Dynamics 365 Business Central is currently set to false. To resolve this issue and make the field writable, simply update the 'editable' property to true in Microsoft Dynamics 365 Business Central. - connector: zoho-books description: | The status of the bill will be "submitted" by default when creating a bill. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Bill' responses: '201': $ref: '#/components/responses/CreateBillResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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, 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] } ] } ], accounting_period: '01-24' } } try { const { data } = await apideck.accounting.billsAdd(params) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/bills/{id}: get: tags: - Bills operationId: billsOne summary: Get Bill description: Get Bill parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: The Freshbooks Bills api is currently in beta. responses: '200': $ref: '#/components/responses/GetBillResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.billsOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Bills operationId: billsUpdate summary: Update Bill description: Update Bill parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: procountor-fi description: '' Procountor only accepts the following values for the language field: EN, FI, SV, ET, NO, and DA. Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: Quickbooks description: Quickbooks requires the supplier.id to be sent in order to make update operations. - connector: zoho-books description: | The allowed values for the status field are "draft", "submitted" and "void" when using the update method. Please send status updates separately from other bill updates. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Bill' responses: '200': $ref: '#/components/responses/UpdateBillResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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, 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] } ] } ], accounting_period: '01-24' } } try { const { data } = await apideck.accounting.billsUpdate(params) console.log('API called successfully', data) } catch (error) { console.error(error) } delete: tags: - Bills operationId: billsDelete summary: Delete Bill description: Delete Bill parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: | Delete will set the bill to inactive and will soft delete it, meaning it will stop appearing in the list API call. However, it can still be found via the get by id call. responses: '200': $ref: '#/components/responses/DeleteBillResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.billsDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/invoices: get: tags: - Invoices operationId: invoicesAll summary: List Invoices description: List Invoices parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/invoicesFilter' - $ref: '#/components/parameters/invoicesSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: clearbooks-uk description: Clearbooks does not support setting the pagination size. - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. responses: '200': $ref: '#/components/responses/GetInvoicesResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.invoicesAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Invoices operationId: invoicesAdd summary: Create Invoice description: Create Invoice parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: quickbooks description: Quickbooks offers limited (regional) support for applying discount on a Line Item. Including discount_percentage or discount_amount applies to entire invoice. The default type for a Line Item is a sales item if no type has been provided. - connector: procountor-fi description: '' Procountor only accepts the following values for the language field: EN, FI, SV, ET, NO, and DA. Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: microsoft-dynamics-365-business-central description: | If you encounter a '400 Bad Request' error indicating "Control 'fieldName' is read-only" it means the 'editable' property for this field in Microsoft Dynamics 365 Business Central is currently set to false. To resolve this issue and make the field writable, simply update the 'editable' property to true in Microsoft Dynamics 365 Business Central. - connector: freshbooks description: | The status field can be set to either "submitted", "partially_paid", "paid" or "draft". The due_date and invoice_date fields are required for the invoice to be created. - connector: zoho-books description: | By default, the status of the invoice will be set to "draft". - connector: netsuite description: Netsuite only supports one tracking category at a time so only the first item in the tracking_categories list will be used. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Invoice' responses: '201': $ref: '#/components/responses/CreateInvoiceResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/invoices/{id}: get: tags: - Invoices operationId: invoicesOne summary: Get Invoice description: Get Invoice parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetInvoiceResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.invoicesOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Invoices operationId: invoicesUpdate summary: Update Invoice description: Update Invoice parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: quickbooks description: | Quickbooks offers limited (regional) support for applying discount on a Line Item. Including discount_percentage or discount_amount applies to entire invoice. The default type for a Line Item is a sales item if no type has been provided. When setting status to `void`, do not include any other fields in the request body. - connector: procountor-fi description: '' Procountor only accepts the following values for the language field: EN, FI, SV, ET, NO, and DA. Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: exact-online description: To configure the shipping address for invoices, it is recommended to update the customer resource. If there is a need to change this property, modifying the customer information is advised. - connector: xero description: For updating invoices, there are some limitations. Check out [here](https://developers.apideck.com/connectors/xero/docs/application_owner+oauth_credentials#1-limitations-and-rules-for-updating-xero-invoices) - connector: freshbooks description: | The status field can be set to either "submitted" or "draft". The other available statuses are set by the Freshbooks API and cannot be updated manually. The due_date and invoice_date fields are required for the due date to be updated. - connector: zoho-books description: | The allowed values for the status field are "draft", "submitted", and "void" when using the update method. Please ensure that status updates are sent separately from other invoice updates. - connector: netsuite description: Netsuite only supports one tracking category at a time so only the first item in the tracking_categories list will be used. - connector: sage-business-cloud-accounting description: | To fetch service items, you must include filter[type]=service in your request parameters requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Invoice' responses: '200': $ref: '#/components/responses/UpdateInvoiceResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Invoices operationId: invoicesDelete summary: Delete Invoice description: Delete Invoice parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: | Delete will set the invoice to inactive and will soft delete it, meaning it will stop appearing in the list API call. However, it can still be found via the get by id call. responses: '200': $ref: '#/components/responses/DeleteInvoiceResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.invoicesDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/ledger-accounts: get: tags: - Ledger Accounts operationId: ledgerAccountsAll summary: List Ledger Accounts description: List Ledger Accounts parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/ledgerAccountsFilter' - $ref: '#/components/parameters/ledgerAccountsSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. - connector: clearbooks-uk description: Clearbooks does not support setting the pagination size. responses: '200': $ref: '#/components/responses/GetLedgerAccountsResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.ledgerAccountsAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Ledger Accounts operationId: ledgerAccountsAdd summary: Create Ledger Account description: Create Ledger Account parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/LedgerAccount' responses: '201': $ref: '#/components/responses/CreateLedgerAccountResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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' } ], 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) } /accounting/ledger-accounts/{id}: get: tags: - Ledger Accounts operationId: ledgerAccountsOne summary: Get Ledger Account description: Get Ledger Account parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetLedgerAccountResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.ledgerAccountsOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Ledger Accounts operationId: ledgerAccountsUpdate summary: Update Ledger Account description: Update Ledger Account parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: zoho-books description: | For ledger accounts, please update the "active" status separately from other updates. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/LedgerAccount' responses: '200': $ref: '#/components/responses/UpdateLedgerAccountResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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' } ], 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) } delete: tags: - Ledger Accounts operationId: ledgerAccountsDelete summary: Delete Ledger Account description: Delete Ledger Account parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteLedgerAccountResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.ledgerAccountsDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/invoice-items: get: tags: - Invoice Items operationId: invoiceItemsAll summary: List Invoice Items description: List Invoice Items parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/invoiceItemsFilter' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. responses: '200': $ref: '#/components/responses/GetInvoiceItemsResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.invoiceItemsAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Invoice Items operationId: invoiceItemsAdd summary: Create Invoice Item description: Create Invoice Item parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: quickbooks description: | The `taxable` field is applicable to US companies only and should be sent in the request body if your QuickBooks account is in the US region. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/InvoiceItem' responses: '201': $ref: '#/components/responses/CreateInvoiceItemResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/invoice-items/{id}: get: tags: - Invoice Items operationId: invoiceItemsOne summary: Get Invoice Item description: Get Invoice Item parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' - $ref: '#/components/parameters/invoiceItemFilter' x-apideck-gotchas: - connector: sage-business-cloud-accounting description: | To fetch service items, you must include filter[type]=service in your request parameters security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetInvoiceItemResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.invoiceItemsOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Invoice Items operationId: invoiceItemsUpdate summary: Update Invoice Item description: Update Invoice Item parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: quickbooks description: | The `taxable` field is applicable to US companies only and should be sent in the request body if your QuickBooks account is in the US region. - connector: zoho-books description: | Please ensure that status updates are sent separately from other invoice item updates. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/InvoiceItem' responses: '200': $ref: '#/components/responses/UpdateInvoiceItemResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Invoice Items operationId: invoiceItemsDelete summary: Delete Invoice Item description: Delete Invoice Item parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: | Delete will set the invoice item to inactive and will soft delete it, meaning it will stop appearing in the list API call. However, it can still be found via the get by id call. responses: '200': $ref: '#/components/responses/DeleteInvoiceItemResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.invoiceItemsDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/credit-notes: get: tags: - Credit Notes operationId: creditNotesAll summary: List Credit Notes description: List Credit Notes parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/creditNotesFilter' - $ref: '#/components/parameters/creditNotesSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: clearbooks-uk description: Clearbooks does not support setting the pagination size. - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. responses: '200': $ref: '#/components/responses/GetCreditNotesResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.creditNotesAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Credit Notes operationId: creditNotesAdd summary: Create Credit Note description: Create Credit Note parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: xero description: For adding invoice allocations, use the proxy API. [Know more](https://developers.apideck.com/connectors/xero/docs/application_owner+oauth_credentials#2-curl-requests-for-adding-and-removing-allocations-from-xero-credit-note) - connector: zoho-books description: | By default, the status of the bill will be set to "authorised". - connector: netsuite description: Netsuite only supports one tracking category at a time so only the first item in the tracking_categories list will be used. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreditNote' responses: '201': $ref: '#/components/responses/CreateCreditNoteResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/credit-notes/{id}: get: tags: - Credit Notes operationId: creditNotesOne summary: Get Credit Note description: Get Credit Note parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetCreditNoteResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.creditNotesOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Credit Notes operationId: creditNotesUpdate summary: Update Credit Note description: Update Credit Note parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | - Netsuite doesn't support voiding credit notes via API. Options: 1) Remove allocations and delete, or 2) Create a reversing invoice for the same amount. - connector: xero description: | - Authorised Credit Note can only be updated to voided status and cannot be deleted once authorised. - Any invoice allocation and payment must be deleted before updating the authorised Credit Note to status voided. - To delete payments, use the payment ID from the raw data and delete it using the Delete Payment endpoint. - For adding and removing invoice allocations, use the proxy API. [Know more](https://developers.apideck.com/connectors/xero/docs/application_owner+oauth_credentials#2-curl-requests-for-adding-and-removing-allocations-from-xero-credit-note) - connector: zoho-books description: | Allowed values for the status are "draft", "authorised", and "voided" when using the update method. Please send status updates separately from other updates for Credit Notes. - connector: netsuite description: Netsuite only supports one tracking category at a time so only the first item in the tracking_categories list will be used. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreditNote' responses: '200': $ref: '#/components/responses/UpdateCreditNoteResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Credit Notes operationId: creditNotesDelete summary: Delete Credit Note description: Delete Credit Note parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: xero description: | Xero will only allow deleting a Credit Note if it is in draft status. Credit notes with "authorised" status cannot be deleted directly. Instead: - If the credit note is empty (i.e., has no invoice allocations and payments), its status can be updated to "voided" by update Credit Note endpoint. - If the credit note has invoice allocations and payments, these must be removed first. Once all invoice allocations and payments are deleted, the credit note's status can be updated to "Voided" by update Credit Note endpoint. [Know more](https://developers.apideck.com/connectors/xero/docs/application_owner+oauth_credentials#2-curl-requests-for-adding-and-removing-allocations-from-xero-credit-note) - connector: freshbooks description: | Delete will set the credit note to inactive and will soft delete it, meaning it will stop appearing in the list API call. However, it can still be found via the get by id call. responses: '200': $ref: '#/components/responses/DeleteCreditNoteResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.creditNotesDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/customers: get: tags: - Customers operationId: customersAll summary: List Customers description: List Customers parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/customersFilter' - $ref: '#/components/parameters/customersSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. - connector: clearbooks-uk description: Clearbooks does not support setting the pagination size. - connector: xero description: | In Xero, contacts are not specifically identified as customers or suppliers until an associated financial document is linked to them. This means that within the customer data response, you will find contacts in two categories: those who have been linked to an invoice and thus are recognized as customers, and those who have no invoices or bills associated, remaining uncategorized. For example, a contact is only considered a Customer if there is an invoice connected to them. Similarly, a contact is recognized as a Supplier only when a bill has been associated with their account. responses: '200': $ref: '#/components/responses/GetCustomersResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.customersAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Customers operationId: customersAdd summary: Create Customer description: Create Customer parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: procountor-fi description: '' Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_DEBIT, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: quickbooks description: QuickBooks supports only billing and shipping addresses. Therefore, when creating addresses, it is required to specify the type as 'billing' or 'shipping' in the address object within the addresses array. - connector: freshbooks description: | Freshbooks API set status to active by default for new customers. To change the status, you can use the Update Customer endpoint. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Customer' responses: '201': $ref: '#/components/responses/CreateCustomerResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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', 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) } /accounting/customers/{id}: get: tags: - Customers operationId: customersOne summary: Get Customer description: Get Customer parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetCustomerResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.customersOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Customers operationId: customersUpdate summary: Update Customer description: Update Customer parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: procountor-fi description: '' Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_DEBIT, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: quickbooks description: QuickBooks supports only billing and shipping addresses. Therefore, when creating or updating addresses, it is required to specify the type as 'billing' or 'shipping' in the address object within the addresses array. - connector: freshbooks description: | The status field can be updated to either "active" or "archived". - connector: zoho-books description: | The status field can be updated to either "active" or "inactive". Please send status updates separately from other updates for the customer. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Customer' responses: '200': $ref: '#/components/responses/UpdateCustomerResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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', 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) } delete: tags: - Customers operationId: customersDelete summary: Delete Customer description: Delete Customer parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: | Delete will set the customer to inactive and will soft delete it, meaning it will stop appearing in the list API call. However, it can still be found via the get by id call. responses: '200': $ref: '#/components/responses/DeleteCustomerResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.customersDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/suppliers: get: tags: - Suppliers operationId: suppliersAll summary: List Suppliers description: List Suppliers parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/suppliersFilter' - $ref: '#/components/parameters/suppliersSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: clearbooks-uk description: Clearbooks does not support setting the pagination size. - connector: procountor-fi description: | Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_DEBIT, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. - connector: xero description: | In Xero, contacts are not specifically identified as customers or suppliers until an associated financial document is linked to them. This means that within the customer data response, you will find contacts in two categories: those who have been linked to an invoice and thus are recognized as customers, and those who have no invoices or bills associated, remaining uncategorized. For example, a contact is only considered a Customer if there is an invoice connected to them. Similarly, a contact is recognized as a Supplier only when a bill has been associated with their account. responses: '200': $ref: '#/components/responses/GetSuppliersResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.suppliersAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Suppliers operationId: suppliersAdd summary: Create Supplier description: Create Supplier parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Supplier' x-apideck-gotchas: - connector: quickbooks description: QuickBooks only supports a single billing address. Therefore, the first item in the addresses array will always be mapped as the billing address, regardless of its original type. - connector: microsoft-dynamics-365-business-central description: | If you encounter a '400 Bad Request' error indicating "Control 'fieldName' is read-only" it means the 'editable' property for this field in Microsoft Dynamics 365 Business Central is currently set to false. To resolve this issue and make the field writable, simply update the 'editable' property to true in Microsoft Dynamics 365 Business Central. - connector: freshbooks description: | Freshbooks API set status to active by default for new suppliers. To change the status, you can use the Update Supplier endpoint. responses: '201': $ref: '#/components/responses/CreateSupplierResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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', 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.suppliersAdd(params) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/suppliers/{id}: get: tags: - Suppliers operationId: suppliersOne summary: Get Supplier description: Get Supplier parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetSupplierResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.suppliersOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Suppliers operationId: suppliersUpdate summary: Update Supplier description: Update Supplier parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: procountor-fi description: '' Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_DEBIT, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: quickbooks description: QuickBooks only supports a single billing address. Therefore, the first item in the addresses array will always be mapped as the billing address, regardless of its original type. - connector: freshbooks description: | The status field can be updated to either "active" or "archived". - connector: zoho-books description: | The status field can be updated to either "active" or "inactive". Please send status updates separately from other updates for the supplier. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Supplier' responses: '200': $ref: '#/components/responses/UpdateSupplierResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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', 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.suppliersUpdate(params) console.log('API called successfully', data) } catch (error) { console.error(error) } delete: tags: - Suppliers operationId: suppliersDelete summary: Delete Supplier description: Delete Supplier parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: | Delete will set the supplier to inactive and will soft delete it, meaning it will stop appearing in the list API call. responses: '200': $ref: '#/components/responses/DeleteSupplierResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.suppliersDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/payments: get: tags: - Payments operationId: paymentsAll summary: List Payments description: List Payments parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/paymentsFilter' - $ref: '#/components/parameters/paymentsSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. - connector: kashflow description: Kashflow only allows to retrieve payments by invoice, so in order to use this endpoint the filter[invoice_number] parameter is required. - connector: exact-online description: | Limit parameter for pagination is not supported for this resource. - connector: exact-online-nl description: | Limit parameter for pagination is not supported for this resource. - connector: exact-online-uk description: | Limit parameter for pagination is not supported for this resource. responses: '200': $ref: '#/components/responses/GetPaymentsResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.paymentsAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Payments operationId: paymentsAdd summary: Create Payment description: Create Payment parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Payment' x-apideck-gotchas: - connector: netsuite description: | The number property could be used to override the Netsuite tranId property. - connector: xero description: | Xero supports creating payments against multiple allocation types in a single request. However, the response will provide the ID of the first payment only. To access all payment IDs, inspect the raw data. - connector: quickbooks description: | Payment allocations in QuickBooks are processed asynchronously. While the allocations are included in the request, they may not appear in the immediate response. The allocations will be applied and become visible in subsequent list or get calls. responses: '201': $ref: '#/components/responses/CreatePaymentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/payments/{id}: get: tags: - Payments operationId: paymentsOne summary: Get Payment description: Get Payment parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetPaymentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.paymentsOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Payments operationId: paymentsUpdate summary: Update Payment description: Update Payment parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: xero description: | Xero doesn't support updating payments. To update a payment, you need to delete the existing payment and create a new one. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Payment' responses: '200': $ref: '#/components/responses/UpdatePaymentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Payments operationId: paymentsDelete summary: Delete Payment description: Delete Payment parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: | Delete will set the payment to inactive and will soft delete it, meaning it will stop appearing in the list API call. However, it can still be found via the get by id call. responses: '200': $ref: '#/components/responses/DeletePaymentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.paymentsDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/company-info: get: tags: - Company Info operationId: companyInfoOne summary: Get company info description: Get company info parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetCompanyInfoResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.companyInfoOne({}) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/balance-sheet: get: tags: - Balance Sheet operationId: balanceSheetOne summary: Get BalanceSheet description: Get BalanceSheet parameters: - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/balanceSheetFilter' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: quickbooks description: When using start and end date filters, QuickBooks requires both to be sent. However, the report only reflects the balance sheet situation as of the end date. responses: '200': $ref: '#/components/responses/GetBalanceSheetResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.balanceSheetOne({}) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/profit-and-loss: get: tags: - Profit and Loss operationId: profitAndLossOne summary: Get Profit and Loss description: Get Profit and Loss parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/profitAndLossFilter' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetProfitAndLossResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.profitAndLossOne({}) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/journal-entries: get: tags: - Journal Entries operationId: journalEntriesAll summary: List Journal Entries description: List Journal Entries parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/journalEntriesFilter' - $ref: '#/components/parameters/journalEntriesSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. - connector: xero description: Xero will return 100 items for each call, so the limit parameter is ignored. - connector: exact-online description: | Limit parameter for pagination is not supported for this resource. - connector: exact-online-nl description: | Limit parameter for pagination is not supported for this resource. - connector: exact-online-uk description: | Limit parameter for pagination is not supported for this resource. responses: '200': $ref: '#/components/responses/GetJournalEntriesResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.journalEntriesAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Journal Entries operationId: journalEntriesAdd summary: Create Journal Entry description: Create Journal Entry parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: procountor-fi description: | Procountor only accepts the following values for the tax_code field: SALES, PURCHASE. - connector: xero description: When creating journal entries, the returned ID is collected from Xero with a maximum of 100 new journal items per day. If more than 100 journal entries are created in a single day, the id returned will be of the manual journal. - connector: netsuite description: Netsuite only supports one tracking category at a time so only the first item in the tracking_categories list will be used. - connector: mrisoftware description: | MRI Software does not provide a proper ID for journal line items. Instead, each journal line item is identified by a combination of GLREFERENCE, PERIOD, and ITEM. These fields are mapped to unify with the properties number, accounting_period, and line_number, respectively. Additionally, MRI Software requires a GLSOURCE field, which is not supported by Unify. Therefore, it will be sent statically as "GL" (General Ledger). requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/JournalEntry' responses: '201': $ref: '#/components/responses/CreateJournalEntryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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', 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) } /accounting/journal-entries/{id}: get: tags: - Journal Entries operationId: journalEntriesOne summary: Get Journal Entry description: Get Journal Entry parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetJournalEntryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.journalEntriesOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Journal Entries operationId: journalEntriesUpdate summary: Update Journal Entry description: Update Journal Entry parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: procountor-fi description: | Procountor only accepts the following values for the tax_code field: SALES, PURCHASE. Procountor requires row_version to be set when updating a journal entry. The row_version should be equivalent to the current row_version of the resource - connector: netsuite description: Netsuite only supports one tracking category at a time so only the first item in the tracking_categories list will be used. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/JournalEntry' responses: '200': $ref: '#/components/responses/UpdateJournalEntryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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', 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) } delete: tags: - Journal Entries operationId: journalEntriesDelete summary: Delete Journal Entry description: Delete Journal Entry parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteJournalEntryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.journalEntriesDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/purchase-orders: get: tags: - Purchase Orders operationId: purchaseOrdersAll summary: List Purchase Orders description: List Purchase Orders parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/purchaseOrdersFilter' - $ref: '#/components/parameters/purchaseOrdersSort' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. responses: '200': $ref: '#/components/responses/GetPurchaseOrdersResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.purchaseOrdersAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Purchase Orders operationId: purchaseOrdersAdd summary: Create Purchase Order description: Create Purchase Order parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: xero description: "Xero accepts a shipping address as a string instead of separate fields. Ie: `23 Main Street\r\nCentral City\r\nMarineville\r\n1234\r\n`" - connector: procountor-fi description: | Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: microsoft-dynamics-365-business-central description: | If you encounter a '400 Bad Request' error indicating "Control 'fieldName' is read-only" it means the 'editable' property for this field in Microsoft Dynamics 365 Business Central is currently set to false. To resolve this issue and make the field writable, simply update the 'editable' property to true in Microsoft Dynamics 365 Business Central. - connector: zoho-books description: | By default, the status of the purchase order will be set to "draft". requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/PurchaseOrder' responses: '201': $ref: '#/components/responses/CreatePurchaseOrderResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/purchase-orders/{id}: get: tags: - Purchase Orders operationId: purchaseOrdersOne summary: Get Purchase Order description: Get Purchase Order parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetPurchaseOrderResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.purchaseOrdersOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Purchase Orders operationId: purchaseOrdersUpdate summary: Update Purchase Order description: Update Purchase Order parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: xero description: "Xero accepts a shipping address as a string instead of separate fields. Ie: `23 Main Street\r\nCentral City\r\nMarineville\r\n1234\r\n`" - connector: procountor-fi description: '' Procountor only accepts the following values for the payment_method field: BANK_TRANSFER, DIRECT_PAYMENT, CLEARING, CREDIT_CARD_CHARGE, FOREIGN_PAYMENT, OTHER, CASH, DOMESTIC_PAYMENT_PLUSGIRO, DOMESTIC_PAYMENT_BANKGIRO, DOMESTIC_PAYMENT_CREDITOR, DKLMPKRE, NETS. Procountor only accepts the following values for the channel field: EMAIL, MAIL, ELECTRONIC_INVOICE, EDIFACT, PAPER_INVOICE, NO_SENDING. - connector: zoho-books description: | Allowed values for the status are "draft", "open", "billed" and "deleted" when using the update method. Please send status updates separately from other updates for the supplier. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/PurchaseOrder' responses: '200': $ref: '#/components/responses/UpdatePurchaseOrderResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Purchase Orders operationId: purchaseOrdersDelete summary: Delete Purchase Order description: Delete Purchase Order parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeletePurchaseOrderResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.purchaseOrdersDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/subsidiaries: get: tags: - Subsidiaries operationId: subsidiariesAll summary: List Subsidiaries description: List Subsidiaries parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. responses: '200': $ref: '#/components/responses/GetSubsidiariesResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.subsidiariesAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Subsidiaries operationId: subsidiariesAdd summary: Create Subsidiary description: Create Subsidiary parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: null requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Subsidiary' responses: '201': $ref: '#/components/responses/CreateSubsidiaryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/subsidiaries/{id}: get: tags: - Subsidiaries operationId: subsidiariesOne summary: Get Subsidiary description: Get Subsidiary parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetSubsidiaryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.subsidiariesOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Subsidiaries operationId: subsidiariesUpdate summary: Update Subsidiary description: Update Subsidiary parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: null requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Subsidiary' responses: '200': $ref: '#/components/responses/UpdateSubsidiaryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Subsidiaries operationId: subsidiariesDelete summary: Delete Subsidiary description: Delete Subsidiary parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteSubsidiaryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.subsidiariesDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/locations: get: tags: - Locations operationId: locationsAll summary: List Locations description: List Locations parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/fields' - $ref: '#/components/parameters/accountingLocationsFilter' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. responses: '200': $ref: '#/components/responses/GetAccountingLocationsResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.locationsAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Locations operationId: locationsAdd summary: Create Location description: Create Location parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: null requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/AccountingLocation' responses: '201': $ref: '#/components/responses/CreateAccountingLocationResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/locations/{id}: get: tags: - Locations operationId: locationsOne summary: Get Location description: Get Location parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetAccountingLocationResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.locationsOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Locations operationId: locationsUpdate summary: Update Location description: Update Location parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: null requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/AccountingLocation' responses: '200': $ref: '#/components/responses/UpdateAccountingLocationResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Locations operationId: locationsDelete summary: Delete Location description: Delete Location parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteAccountingLocationResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.locationsDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/departments: get: tags: - Departments operationId: departmentsAll summary: List Departments description: List Departments parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/fields' - $ref: '#/components/parameters/accountingDepartmentsFilter' security: - apiKey: [] x-apideck-gotchas: - connector: netsuite description: | The minimun page size accepted for Netsuite is 5. The cursor for Netsuite expires if they have not been used within 15 minutes after its creation. responses: '200': $ref: '#/components/responses/GetAccountingDepartmentsResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.departmentsAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Departments operationId: departmentsAdd summary: Create Department description: Create Department parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: null requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/AccountingDepartment' responses: '201': $ref: '#/components/responses/CreateAccountingDepartmentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/departments/{id}: get: tags: - Departments operationId: departmentsOne summary: Get Department description: Get Department parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetAccountingDepartmentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.departmentsOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Departments operationId: departmentsUpdate summary: Update Department description: Update Department parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: null requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/AccountingDepartment' responses: '200': $ref: '#/components/responses/UpdateAccountingDepartmentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Departments operationId: departmentsDelete summary: Delete Department description: Delete Department parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteAccountingDepartmentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.departmentsDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/attachments/{reference_type}/{reference_id}: get: tags: - Attachments operationId: attachmentsAll summary: List Attachments description: List Attachments parameters: - $ref: '#/components/parameters/referenceType' - $ref: '#/components/parameters/referenceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetAttachmentsResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } post: tags: - Attachments operationId: attachmentsUpload summary: Upload attachment description: Upload attachment x-sdk-exclude: true servers: - url: https://upload.apideck.com parameters: - $ref: '#/components/parameters/referenceType' - $ref: '#/components/parameters/referenceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/attachmentMetadata' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/contentType' security: - apiKey: [] requestBody: content: '*/*': schema: type: string format: binary x-api-deck-gotchas: - connector: quickbooks description: Quickbooks limits attachment uploads to 100MB. - connector: xero description: Xero limits to 10 attachments per resource (invoices/bills) of 3.5MB each. responses: '201': $ref: '#/components/responses/CreateAttachmentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID', contentType: 'REPLACE_WITH_CONTENT_TYPE', metadata: 'REPLACE_WITH_METADATA' }) const params = { referenceType: 'invoice', referenceId: '123456', attachmentsUpload: 'string' } try { const { data } = await apideck.accounting.attachmentsUpload(params) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/attachments/{reference_type}/{reference_id}/{id}: get: tags: - Attachments operationId: attachmentsOne summary: Get Attachment description: Get Attachment parameters: - $ref: '#/components/parameters/referenceType' - $ref: '#/components/parameters/referenceId' - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetAttachmentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Attachments operationId: attachmentsDelete summary: Delete Attachment description: Delete Attachment parameters: - $ref: '#/components/parameters/referenceType' - $ref: '#/components/parameters/referenceId' - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteAttachmentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/attachments/{reference_type}/{reference_id}/{id}/download: get: tags: - Attachments operationId: attachmentsDownload summary: Download Attachment description: Download Attachment parameters: - $ref: '#/components/parameters/referenceType' - $ref: '#/components/parameters/referenceId' - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetAttachmentDownloadResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/tracking-categories: get: tags: - Tracking Categories operationId: trackingCategoriesAll summary: List Tracking Categories description: List Tracking Categories parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: sage-intacct description: The Parent ID field refers to the parent tracking category code. - connector: xero description: Returns tracking category options only. IDs and names are concatenated as "CategoryName - OptionName". The provided ID can be used to link to the correct tracking category to invoices, bills, etc. responses: '200': $ref: '#/components/responses/GetTrackingCategoriesResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.trackingCategoriesAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Tracking Categories operationId: trackingCategoriesAdd summary: Create Tracking Category description: Create Tracking Category parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: sage-intacct description: When creating a category with parent ID please use the tracking category code. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/TrackingCategory' responses: '201': $ref: '#/components/responses/CreateTrackingCategoryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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] } ] } ] } } try { const { data } = await apideck.accounting.trackingCategoriesAdd(params) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/tracking-categories/{id}: get: tags: - Tracking Categories operationId: trackingCategoriesOne summary: Get Tracking Category description: Get Tracking Category parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] x-apideck-gotchas: - connector: sage-intacct description: The Parent ID field refers to the parent tracking category code. responses: '200': $ref: '#/components/responses/GetTrackingCategoryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.trackingCategoriesOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Tracking Categories operationId: trackingCategoriesUpdate summary: Update Tracking Category description: Update Tracking Category parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/TrackingCategory' security: - apiKey: [] x-apideck-gotchas: - connector: sage-intacct description: When updating the Parent ID field please use the tracking category code. responses: '200': $ref: '#/components/responses/UpdateTrackingCategoryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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] } ] } ] } } try { const { data } = await apideck.accounting.trackingCategoriesUpdate(params) console.log('API called successfully', data) } catch (error) { console.error(error) } delete: tags: - Tracking Categories operationId: trackingCategoriesDelete summary: Delete Tracking Category description: Delete Tracking Category parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteTrackingCategoryResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.trackingCategoriesDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/bill-payments: get: tags: - Bill Payments operationId: billPaymentsAll summary: List Bill Payments description: List Bill Payments parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/paymentsFilter' - $ref: '#/components/parameters/paymentsSort' - $ref: '#/components/parameters/passThrough' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetBillPaymentsResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.billPaymentsAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Bill Payments operationId: billPaymentsAdd summary: Create Bill Payment description: Create Bill Payment parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: quickbooks description: | Payment method is required and must be `Check` or `CreditCard`. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/BillPayment' responses: '201': $ref: '#/components/responses/CreateBillPaymentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } /accounting/bill-payments/{id}: get: tags: - Bill Payments operationId: billPaymentsOne summary: Get Bill Payment description: Get Bill Payment parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/fields' security: - apiKey: [] responses: '200': $ref: '#/components/responses/GetBillPaymentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.billPaymentsOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Bill Payments operationId: billPaymentsUpdate summary: Update Bill Payment description: Update Bill Payment parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: | The `transaction_date` field is required. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/BillPayment' responses: '200': $ref: '#/components/responses/UpdateBillPaymentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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) } delete: tags: - Bill Payments operationId: billPaymentsDelete summary: Delete Bill Payment description: Delete Bill Payment parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: freshbooks description: | Delete will set the payment to inactive and will soft delete it, meaning it will stop appearing in the list API call. However, it can still be found via the get by id call. responses: '200': $ref: '#/components/responses/DeleteBillPaymentResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.billPaymentsDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } /accounting/expenses: get: tags: - Expenses operationId: expensesAll summary: List Expenses description: List Expenses parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/cursor' - $ref: '#/components/parameters/limit' security: - apiKey: [] x-apideck-gotchas: - connector: xero description: In Xero, both suppliers (also used for employees) and customers are identified using the same contact ID, which maps to both `supplier_id` and `customer_id`. To accurately determine the contact type, use the suppliers and customers endpoints. responses: '200': $ref: '#/components/responses/GetExpensesResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.expensesAll({}) console.log('API called successfully', data) } catch (error) { console.error(error) } post: tags: - Expenses operationId: expensesAdd summary: Create Expense description: Create Expense parameters: - $ref: '#/components/parameters/raw' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' security: - apiKey: [] x-apideck-gotchas: - connector: xero description: When creating an expense for Xero, ensure the `account_id` corresponds to a 'bank' or 'credit_card' account type. Using other account types may result in errors or unexpected behavior. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Expense' responses: '201': $ref: '#/components/responses/CreateExpenseResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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', 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) } /accounting/expenses/{id}: get: tags: - Expenses operationId: expensesOne summary: Get Expense description: Get Expense parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] x-apideck-gotchas: - connector: xero description: In Xero, both suppliers (also used for employees) and customers are identified using the same contact ID, which maps to both `supplier_id` and `customer_id`. To accurately determine the contact type, use the suppliers and customers endpoints. responses: '200': $ref: '#/components/responses/GetExpenseResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.expensesOne({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } patch: tags: - Expenses operationId: expensesUpdate summary: Update Expense description: Update Expense parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Expense' responses: '200': $ref: '#/components/responses/UpdateExpenseResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | 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', 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) } delete: tags: - Expenses operationId: expensesDelete summary: Delete Expense description: Delete Expense parameters: - $ref: '#/components/parameters/id' - $ref: '#/components/parameters/consumerId' - $ref: '#/components/parameters/applicationId' - $ref: '#/components/parameters/serviceId' - $ref: '#/components/parameters/raw' security: - apiKey: [] responses: '200': $ref: '#/components/responses/DeleteExpenseResponse' '400': $ref: '#/components/responses/BadRequestResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '402': $ref: '#/components/responses/PaymentRequiredResponse' '404': $ref: '#/components/responses/NotFoundResponse' '422': $ref: '#/components/responses/UnprocessableResponse' default: $ref: '#/components/responses/UnexpectedErrorResponse' x-apideck-api: accounting x-codeSamples: - lang: TypeScript label: Node source: | import { Apideck } from '@apideck/node' const apideck = new Apideck({ apiKey: 'REPLACE_WITH_API_KEY', appId: 'REPLACE_WITH_APP_ID', consumerId: 'REPLACE_WITH_CONSUMER_ID' }) try { const { data } = await apideck.accounting.expensesDelete({ id: 'id_example' }) console.log('API called successfully', data) } catch (error) { console.error(error) } x-webhooks: x-sdk-exclude: true CustomerCreated: post: summary: Customer Created operationId: customerCreated x-apideck-event-type: accounting.customer.created parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.customer.created unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/customers/123456ASDF entity_type: customer occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a customer has been created. CustomerUpdated: post: summary: Customer Updated operationId: customerUpdated x-apideck-event-type: accounting.customer.updated parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.customer.updated unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/customers/123456ASDF entity_type: customer occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a customer has been updated. CustomerDeleted: post: summary: Customer Deleted operationId: customerDeleted x-apideck-event-type: accounting.customer.deleted parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.customer.deleted unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/customers/123456ASDF entity_type: customer occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a customer has been deleted. InvoiceCreated: post: summary: Invoice Created operationId: invoiceCreated x-apideck-event-type: accounting.invoice.created parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.invoice.created unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/invoices/123456ASDF entity_type: invoice occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when an invoice has been created. InvoiceUpdated: post: summary: Invoice Updated operationId: invoiceUpdated x-apideck-event-type: accounting.invoice.updated parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.invoice.updated unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/invoices/123456ASDF entity_type: invoice occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when an invoice has been updated. InvoiceDeleted: post: summary: Invoice Deleted operationId: invoiceDeleted x-apideck-event-type: accounting.invoice.deleted parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.invoice.deleted unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/invoices/123456ASDF entity_type: invoice occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when an invoice has been deleted. InvoiceItemCreated: post: summary: Invoice Item Created operationId: invoiceItemCreated x-apideck-event-type: accounting.invoice_item.created parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.invoice_item.created unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/invoice_items/123456ASDF entity_type: invoice_item occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when an invoice has been item created. InvoiceItemUpdated: post: summary: Invoice Item Updated operationId: invoiceItemUpdated x-apideck-event-type: accounting.invoice_item.updated parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.invoice_item.updated unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/invoice_items/123456ASDF entity_type: invoice_item occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when an invoice has been item updated. InvoiceItemDeleted: post: summary: Invoice Item Deleted operationId: invoiceItemDeleted x-apideck-event-type: accounting.invoice_item.deleted parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.invoice_item.deleted unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/invoice_items/123456ASDF entity_type: invoice_item occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when an invoice has been item deleted. LedgerAccountCreated: post: summary: Ledger Account Created operationId: ledgerAccountCreated x-apideck-event-type: accounting.ledger_account.created parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.ledger_account.created unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/ledger_accounts/123456ASDF entity_type: ledger_account occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a ledger has been account created. LedgerAccountUpdated: post: summary: Ledger Account Updated operationId: ledgerAccountUpdated x-apideck-event-type: accounting.ledger_account.updated parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.ledger_account.updated unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/ledger_accounts/123456ASDF entity_type: ledger_account occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a ledger has been account updated. LedgerAccountDeleted: post: summary: Ledger Account Deleted operationId: ledgerAccountDeleted x-apideck-event-type: accounting.ledger_account.deleted parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.ledger_account.deleted unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/ledger_accounts/123456ASDF entity_type: ledger_account occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a ledger has been account deleted. TaxRateCreated: post: summary: Tax Rate Created operationId: taxRateCreated x-apideck-event-type: accounting.tax_rate.created parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.tax_rate.created unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/tax_rates/123456ASDF entity_type: tax_rate occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a tax has been rate created. TaxRateUpdated: post: summary: Tax Rate Updated operationId: taxRateUpdated x-apideck-event-type: accounting.tax_rate.updated parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.tax_rate.updated unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/tax_rates/123456ASDF entity_type: tax_rate occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a tax has been rate updated. TaxRateDeleted: post: summary: Tax Rate Deleted operationId: taxRateDeleted x-apideck-event-type: accounting.tax_rate.deleted parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.tax_rate.deleted unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/tax_rates/123456ASDF entity_type: tax_rate occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a tax has been rate deleted. PurchaseOrderCreated: post: summary: Purchase Order Created operationId: purchaseOrderCreated x-apideck-event-type: accounting.purchase_order.created parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.purchase_order.created unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/purchase_orders/123456ASDF entity_type: purchase_order occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a purchase has been order created. PurchaseOrderDeleted: post: summary: Purchase order Deleted operationId: purchaseOrderDeleted x-apideck-event-type: accounting.purchase-order.deleted parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.purchase-order.deleted unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/purchase-orders/123456ASDF entity_type: purchase-order occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a purchase order has been deleted. PurchaseOrderUpdated: post: summary: Purchase order Updated operationId: purchaseOrderUpdated x-apideck-event-type: accounting.purchase-order.updated parameters: - name: x-apideck-event-type in: header required: true description: The type of event that was triggered schema: $ref: '#/components/schemas/AccountingEventType' - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 tags: - Webhook Events requestBody: content: application/json: schema: type: object properties: payload: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.purchase-order.updated unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/purchase-orders/123456ASDF entity_type: purchase-order occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully. security: [] description: Event broadcast when a purchase order has been updated. ExpenseUpdated: post: summary: Expense Updated description: Event broadcast when an expense has been updated. operationId: expenseUpdated x-apideck-event-type: accounting.expense.updated tags: - Webhook Events requestBody: content: application/json: schema: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.expense.updated unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/expenses/123456ASDF entity_type: expense occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully parameters: - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 security: [] ExpenseDeleted: post: summary: Expense Deleted description: Event broadcast when an expense has been deleted. operationId: expenseDeleted x-apideck-event-type: accounting.expense.deleted tags: - Webhook Events requestBody: content: application/json: schema: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.expense.deleted unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/expenses/123456ASDF entity_type: expense occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully parameters: - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 security: [] ExpenseCreated: post: summary: Expense Created description: Event broadcast when an expense has been created. operationId: expenseCreated x-apideck-event-type: accounting.expense.created tags: - Webhook Events requestBody: content: application/json: schema: $ref: '#/components/schemas/AccountingWebhookEvent' example: payload: event_type: accounting.expense.created unified_api: accounting service_id: xero consumer_id: test_user_id event_id: d290f1ee-6c54-4b01-90e6-d701748f0851 entity_id: 123456ASDF entity_url: https://unify.apideck.com/accounting/expenses/123456ASDF entity_type: expense occurred_at: '2020-01-01T00:00:00.000Z' responses: '200': description: Return a 200 status to indicate that the data was received successfully parameters: - name: x-apideck-idempotency-key in: header required: true description: An idempotency key is a unique value generated to recognize subsequent retries/duplicates of the same request. schema: type: string format: uuid example: d290f1ee-6c54-4b01-90e6-d701748f0851 security: []