{"files":{"SKILL.md":"---\nname: sync-for-commerce\ndescription: \"Sync for Commerce API skill. Use when working with Sync for Commerce for config, companies, sync. Covers 22 endpoints.\"\nversion: 1.0.0\ngenerator: lapsh\n---\n\n# Sync for Commerce\nAPI version: 1.1\n\n## Auth\nApiKey Authorization in header\n\n## Base URL\nhttps://api.codat.io\n\n## Setup\n1. Set your API key in the appropriate header\n2. GET /companies -- list companies\n3. POST /companies -- create first company\n\n## Endpoints\n22 endpoints across 5 groups. See references/api-spec.lap for full details.\n\n### Config\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /config/sync/commerce/{commerceKey}/{accountingKey}/start | Start new sync flow |\n| GET | /config/companies/{companyId}/sync/commerce | Get company configuration |\n| POST | /config/companies/{companyId}/sync/commerce | Set configuration |\n| GET | /config/integrations | List integrations |\n| GET | /config/integrations/{platformKey}/branding | Get branding for an integration |\n\n### Companies\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /companies | List companies |\n| POST | /companies | Create company |\n| GET | /companies/{companyId}/connections | List connections |\n| POST | /companies/{companyId}/connections | Create connection |\n| PATCH | /companies/{companyId}/connections/{connectionId} | Update connection |\n| PUT | /companies/{companyId}/connections/{connectionId}/authorization | Update authorization |\n| POST | /companies/{companyId}/sync/commerce/latest | Initiate new sync |\n| GET | /companies/{companyId}/sync/commerce/syncs/lastSuccessful/status | Last successful sync |\n| GET | /companies/{companyId}/sync/commerce/syncs/latest/status | Latest sync status |\n| GET | /companies/{companyId}/sync/commerce/syncs/{syncId}/status | Get sync status |\n| GET | /companies/{companyId}/sync/commerce/syncs/list/status | List sync statuses |\n\n### Sync\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /sync/commerce/config/ui/text | Get preferences for text fields |\n| PATCH | /sync/commerce/config/ui/text | Update preferences for text fields |\n| POST | /sync/commerce/config/ui/accounts/platform/{platformKey} | Update visible accounts |\n\n### Clients\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /clients/{clientId}/config/ui/accounts/platform/{platformKey} | List visible accounts |\n\n### Meta\n| Method | Path | Description |\n|--------|------|-------------|\n| POST | /meta/companies/{companyId}/sync/commerce/historic | Initiate sync for specific range |\n| GET | /meta/companies/{companyId}/sync/commerce/status | Get sync status |\n\n## Common Questions\nMatch user requests to endpoints in references/api-spec.lap. Key patterns:\n- \"List all start?\" -> GET /config/sync/commerce/{commerceKey}/{accountingKey}/start\n- \"Search companies?\" -> GET /companies\n- \"Create a company?\" -> POST /companies\n- \"Search connections?\" -> GET /companies/{companyId}/connections\n- \"Create a connection?\" -> POST /companies/{companyId}/connections\n- \"Partially update a connection?\" -> PATCH /companies/{companyId}/connections/{connectionId}\n- \"List all commerce?\" -> GET /config/companies/{companyId}/sync/commerce\n- \"Create a commerce?\" -> POST /config/companies/{companyId}/sync/commerce\n- \"Search integrations?\" -> GET /config/integrations\n- \"List all branding?\" -> GET /config/integrations/{platformKey}/branding\n- \"List all text?\" -> GET /sync/commerce/config/ui/text\n- \"Get platform details?\" -> GET /clients/{clientId}/config/ui/accounts/platform/{platformKey}\n- \"Create a latest?\" -> POST /companies/{companyId}/sync/commerce/latest\n- \"Create a historic?\" -> POST /meta/companies/{companyId}/sync/commerce/historic\n- \"List all status?\" -> GET /meta/companies/{companyId}/sync/commerce/status\n- \"How to authenticate?\" -> See Auth section above\n\n## Response Tips\n- Check response schemas in references/api-spec.lap for field details\n- Paginated endpoints accept limit/offset or cursor parameters\n- Create/update endpoints return the modified resource on success\n- Error responses include status codes and descriptions in the spec\n\n## References\n- Full spec: See references/api-spec.lap for complete endpoint details, parameter tables, and response schemas\n\n> Generated from the official API spec by [LAP](https://lap.sh)\n","references/api-spec.lap":"@lap v0.3\n# Machine-readable API spec. Each @endpoint block is one API call.\n@api Sync for Commerce\n@base https://api.codat.io\n@version 1.1\n@auth ApiKey Authorization in header\n@endpoints 22\n@hint download_for_search\n@toc config(5), companies(11), sync(3), clients(1), meta(2)\n\n@group config\n@endpoint GET /config/sync/commerce/{commerceKey}/{accountingKey}/start\n@desc Start new sync flow\n@required {commerceKey: str # Commerce platform key, accountingKey: str # Accounting platform key}\n@optional {merchantIdentifier: str # Identifier for your merchant, can be the merchant name or Codat company id.}\n@returns(200) {url: str} # Success\n@errors {400: The request made is not valid., 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@group companies\n@endpoint GET /companies\n@desc List companies\n@optional {page: int(int32)=1 # Page number. [Read more](https://docs.codat.io/using-the-api/paging)., pageSize: int(int32)=100 # Number of records to return in a page. [Read more](https://docs.codat.io/using-the-api/paging)., query: str # Codat query string. [Read more](https://docs.codat.io/using-the-api/querying)., orderBy: str # Field to order results by. [Read more](https://docs.codat.io/using-the-api/ordering-results).}\n@returns(200) Success\n@errors {400: Your `query` parameter was not correctly formed, 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint POST /companies\n@desc Create company\n@required {name: str # Name of company being connected.}\n@optional {description: str # Additional information about the company. This can be used to store foreign IDs, references, etc., tags: map # A collection of user-defined key-value pairs that store custom metadata against the company.}\n@returns(200) Success\n@errors {400: The request made is not valid., 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n@example_request {\"name\":\"string\"}\n\n@endpoint GET /companies/{companyId}/connections\n@desc List connections\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@optional {page: int(int32)=1 # Page number. [Read more](https://docs.codat.io/using-the-api/paging)., pageSize: int(int32)=100 # Number of records to return in a page. [Read more](https://docs.codat.io/using-the-api/paging)., query: str # Codat query string. [Read more](https://docs.codat.io/using-the-api/querying)., orderBy: str # Field to order results by. [Read more](https://docs.codat.io/using-the-api/ordering-results).}\n@returns(200) OK\n@errors {400: Your `query` parameter was not correctly formed, 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint POST /companies/{companyId}/connections\n@desc Create connection\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@optional {platformKey: str # A unique 4-letter key to represent a platform in each integration. View [accounting](https://docs.codat.io/integrations/accounting/overview#platform-keys), [banking](https://docs.codat.io/integrations/banking/overview#platform-keys), and [commerce](https://docs.codat.io/integrations/commerce/overview#platform-keys) platform keys.}\n@returns(200) {id: str(uuid), integrationId: str(uuid), integrationKey: str, sourceId: str(uuid), sourceType: str, platformName: str, linkUrl: str(uri), status: str, lastSync: str, created: str, dataConnectionErrors: [map]?, connectionInfo: map?} # OK\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint PATCH /companies/{companyId}/connections/{connectionId}\n@desc Update connection\n@required {companyId: str(uuid) # Unique identifier for a company., connectionId: str(uuid) # Unique identifier for a connection.}\n@optional {status: str(PendingAuth/Linked/Unlinked/Deauthorized) # The current authorization status of the data connection.}\n@returns(200) {id: str(uuid), integrationId: str(uuid), integrationKey: str, sourceId: str(uuid), sourceType: str, platformName: str, linkUrl: str(uri), status: str, lastSync: str, created: str, dataConnectionErrors: [map]?, connectionInfo: map?} # Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint PUT /companies/{companyId}/connections/{connectionId}/authorization\n@desc Update authorization\n@returns(200) {id: str(uuid), integrationId: str(uuid), integrationKey: str, sourceId: str(uuid), sourceType: str, platformName: str, linkUrl: str(uri), status: str, lastSync: str, created: str, dataConnectionErrors: [map]?, connectionInfo: map?} # OK\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@group config\n@endpoint GET /config/companies/{companyId}/sync/commerce\n@desc Get company configuration\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@returns(200) {companyId: str(uuid), accountingSoftwareCompanyName: str, enable: bool, configured: bool, schedule: map{selectedFrequency: str, frequencyOptions: [str], startDate: str, syncHour: int, timeZone: str}, configuration: map{countryCode: str, mapSettings: map{outputFormat: str}, sales: map{syncSales: bool, accounts: map?, invoiceStatus: map{selectedInvoiceStatus: str?, invoiceStatusOptions: [str]?}, salesCustomer: map{selectedCustomerId: str?, customerOptions: [map]?}, taxRates: map?, newTaxRates: map{accountingTaxRateOptions: [map]?, commerceTaxRateOptions: [map]?, taxRateMappings: [map]?, selectedDefaultZeroTaxRateId: str?, defaultZeroTaxRateOptions: [map]?}, grouping: map{groupingPeriod: map, groupingLevels: map}}, payments: map{syncPayments: bool, accounts: map?}, newPayments: map{syncPayments: bool, accounts: map?}, fees: map{feesSupplier: map{selectedSupplierId: str?, supplierOptions: [map]?}, syncFees: bool, accounts: map?}}} # Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint POST /config/companies/{companyId}/sync/commerce\n@desc Set configuration\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@returns(200) {companyId: str(uuid), accountingSoftwareCompanyName: str, enable: bool, configured: bool, schedule: map{selectedFrequency: str, frequencyOptions: [str], startDate: str, syncHour: int, timeZone: str}, configuration: map{countryCode: str, mapSettings: map{outputFormat: str}, sales: map{syncSales: bool, accounts: map?, invoiceStatus: map{selectedInvoiceStatus: str?, invoiceStatusOptions: [str]?}, salesCustomer: map{selectedCustomerId: str?, customerOptions: [map]?}, taxRates: map?, newTaxRates: map{accountingTaxRateOptions: [map]?, commerceTaxRateOptions: [map]?, taxRateMappings: [map]?, selectedDefaultZeroTaxRateId: str?, defaultZeroTaxRateOptions: [map]?}, grouping: map{groupingPeriod: map, groupingLevels: map}}, payments: map{syncPayments: bool, accounts: map?}, newPayments: map{syncPayments: bool, accounts: map?}, fees: map{feesSupplier: map{selectedSupplierId: str?, supplierOptions: [map]?}, syncFees: bool, accounts: map?}}} # Success\n@errors {400: The request made is not valid., 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 409: The data type's dataset has not been requested or is still syncing., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint GET /config/integrations\n@desc List integrations\n@optional {page: int(int32)=1 # Page number. [Read more](https://docs.codat.io/using-the-api/paging)., pageSize: int(int32)=100 # Number of records to return in a page. [Read more](https://docs.codat.io/using-the-api/paging)., query: str # Codat query string. [Read more](https://docs.codat.io/using-the-api/querying)., orderBy: str # Field to order results by. [Read more](https://docs.codat.io/using-the-api/ordering-results).}\n@returns(200) Success\n@errors {400: Your `query` parameter was not correctly formed, 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint GET /config/integrations/{platformKey}/branding\n@desc Get branding for an integration\n@required {platformKey: str # A unique 4-letter key to represent a platform in each integration.}\n@returns(200) {logo: map{full: map{image: map{src: str(uri), alt: str}}, square: map{image: map{src: str(uri), alt: str}}}, button: map{default: map{image: map{src: str(uri), alt: str}}, hover: map{image: map{src: str(uri), alt: str}}}, sourceId: str(uuid)} # Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@group sync\n@endpoint GET /sync/commerce/config/ui/text\n@desc Get preferences for text fields\n@required {locale: str(en-us/fr-fr) # Localization identifier for English (US) or French.}\n@returns(200) Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint PATCH /sync/commerce/config/ui/text\n@desc Update preferences for text fields\n@required {locale: str(en-us/fr-fr) # Localization identifier for English (US) or French.}\n@returns(200) Success\n@errors {400: The request made is not valid., 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@group clients\n@endpoint GET /clients/{clientId}/config/ui/accounts/platform/{platformKey}\n@desc List visible accounts\n@returns(200) {visibleAccounts: [str]?} # Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@group sync\n@endpoint POST /sync/commerce/config/ui/accounts/platform/{platformKey}\n@desc Update visible accounts\n@required {platformKey: str # A unique 4-letter key to represent a platform in each integration.}\n@optional {visibleAccounts: [str] # Visible accounts on sync flow.}\n@returns(200) {visibleAccounts: [str]?} # Success\n@errors {400: The request made is not valid., 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@group companies\n@endpoint POST /companies/{companyId}/sync/commerce/latest\n@desc Initiate new sync\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@optional {syncTo: str # In Codat's data model, dates and times are represented using the ISO 8601 standard. Date and time fields are formatted as strings; for example:  ``` 2020-10-08T22:40:50Z 2021-01-01T00:00:00 ```    When syncing data that contains `DateTime` fields from Codat, make sure you support the following cases when reading time information:  - Coordinated Universal Time (UTC): `2021-11-15T06:00:00Z` - Unqualified local time: `2021-11-15T01:00:00` - UTC time offsets: `2021-11-15T01:00:00-05:00`  > Time zones >  > Not all dates from Codat will contain information about time zones.   > Where it is not available from the underlying platform, Codat will return these as times local to the business whose data has been synced.}\n@returns(200) {syncDateRangeUtc: map{start: str, finish: str}, companyId: str(guid), commerceSyncId: str(guid), syncStatusCode: int(int32), syncStatus: str?, errorMessage: str?, syncExceptionMessage: str?, syncUtc: str, dataConnections: [map]?, dataPushed: bool} # Success\n@errors {400: The request made is not valid., 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@group meta\n@endpoint POST /meta/companies/{companyId}/sync/commerce/historic\n@desc Initiate sync for specific range\n@required {companyId: str(uuid) # Unique identifier for a company., dateRange: map{start!: str, finish!: str}}\n@returns(200) {syncDateRangeUtc: map{start: str, finish: str}, companyId: str(guid), commerceSyncId: str(guid), syncStatusCode: int(int32), syncStatus: str?, errorMessage: str?, syncExceptionMessage: str?, syncUtc: str, dataConnections: [map]?, dataPushed: bool} # Success\n@errors {400: The request made is not valid., 401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint GET /meta/companies/{companyId}/sync/commerce/status\n@desc Get sync status\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@returns(200) {companyId: str(uuid), commerceSyncId: str(guid), syncId: str(uuid), syncStatusCode: int(int32), syncStatus: str?, errorMessage: str?, syncExceptionMessage: str?, syncUtc: str, dataPushed: bool, dataConnections: [map]?} # Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@group companies\n@endpoint GET /companies/{companyId}/sync/commerce/syncs/lastSuccessful/status\n@desc Last successful sync\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@returns(200) {companyId: str?, syncId: str?, syncStatusCode: int(int32), syncStatus: str?, errorMessage: str?, syncExceptionMessage: str?, syncUtc: str, dataPushed: bool} # Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint GET /companies/{companyId}/sync/commerce/syncs/latest/status\n@desc Latest sync status\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@returns(200) {companyId: str?, syncId: str?, syncStatusCode: int(int32), syncStatus: str?, errorMessage: str?, syncExceptionMessage: str?, syncUtc: str, dataPushed: bool} # Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint GET /companies/{companyId}/sync/commerce/syncs/{syncId}/status\n@desc Get sync status\n@required {companyId: str(uuid) # Unique identifier for a company., syncId: str(uuid) # Unique identifier for a sync.}\n@returns(200) {companyId: str?, syncId: str?, syncStatusCode: int(int32), syncStatus: str?, errorMessage: str?, syncExceptionMessage: str?, syncUtc: str, dataPushed: bool} # Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endpoint GET /companies/{companyId}/sync/commerce/syncs/list/status\n@desc List sync statuses\n@required {companyId: str(uuid) # Unique identifier for a company.}\n@returns(200) Success\n@errors {401: Your API request was not properly authorized., 402: An account limit has been exceeded. The type of limit is described in the error property:  - You have exceeded the 50-company limit that applies to a Free plan. Delete any companies you no longer need and retry the request. - The requested sync schedule is not allowed. You requested an hourly sync schedule but this functionality is not included in the Free plan. - Your Free account is older than 365 days and has expired. Contact support@codat.io., 403: You are using an outdated API key or a key not associated with that resource., 404: One or more of the resources you referenced could not be found. This might be because your company or data connection id is wrong, or was already deleted., 429: Too many requests were made in a given amount of time. Wait a short period and then try again., 500: There is a problem with our server. Please try again later., 503: The Codat API is temporarily offline for maintenance. Please try again later.}\n\n@endgroup\n\n@end\n"}}