diff --git a/airbyte-config/init/src/main/resources/seed/source_definitions.yaml b/airbyte-config/init/src/main/resources/seed/source_definitions.yaml index 8005d32f48f3f..4cb1349174bb6 100644 --- a/airbyte-config/init/src/main/resources/seed/source_definitions.yaml +++ b/airbyte-config/init/src/main/resources/seed/source_definitions.yaml @@ -1547,6 +1547,13 @@ documentationUrl: https://docs.airbyte.com/integrations/sources/visma-economic sourceType: api releaseStage: alpha +- name: Xero + sourceDefinitionId: 6fd1e833-dd6e-45ec-a727-ab917c5be892 + dockerRepository: airbyte/source-xero + dockerImageTag: 0.1.0 + documentationUrl: https://docs.airbyte.com/integrations/sources/xero + sourceType: api + releaseStage: alpha - name: xkcd sourceDefinitionId: 80fddd16-17bd-4c0c-bf4a-80df7863fc9d dockerRepository: airbyte/source-xkcd diff --git a/airbyte-config/init/src/main/resources/seed/source_specs.yaml b/airbyte-config/init/src/main/resources/seed/source_specs.yaml index d3cec32bc48a7..6a3ff98507f42 100644 --- a/airbyte-config/init/src/main/resources/seed/source_specs.yaml +++ b/airbyte-config/init/src/main/resources/seed/source_specs.yaml @@ -14320,6 +14320,76 @@ supportsNormalization: false supportsDBT: false supported_destination_sync_modes: [] +- dockerImage: "airbyte/source-xero:0.1.0" + spec: + documentationUrl: "https://docs.airbyte.io/integrations/sources/xero" + connectionSpecification: + $schema: "http://json-schema.org/draft-07/schema#" + title: "Xero Spec" + type: "object" + required: + - "authentication" + - "start_date" + - "scopes" + - "tenant_id" + - "client_id" + - "client_secret" + additionalProperties: true + properties: + client_id: + title: "Client ID" + type: "string" + description: "Enter your Xero application's Client ID" + client_secret: + title: "Client Secret" + type: "string" + description: "Enter your Xero application's Client Secret" + airbyte_secret: true + tenant_id: + title: "Tenant ID" + type: "string" + description: "Enter your Xero organization's Tenant ID" + scopes: + title: "Scopes" + type: "string" + description: "Enter your required list of scopes (delimited by comma)" + authentication: + type: "object" + title: "Authentication" + description: "Type and additional credentials of the Xero API connection" + oneOf: + - title: "Authenticate via Xero (OAuth) (unsupported yet)" + type: "object" + required: + - "auth_type" + - "refresh_token" + properties: + auth_type: + type: "string" + const: "oauth" + refresh_token: + title: "Refresh Token" + type: "string" + description: "Enter your Xero application's refresh token" + airbyte_secret: true + - title: "Custom Connections Authentication" + type: "object" + required: + - "auth_type" + properties: + auth_type: + type: "string" + const: "custom_connection" + start_date: + type: "string" + pattern: "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}Z$" + description: "UTC date and time in the format YYYY-MM-DDTHH:mm:ssZ. Any\ + \ data with created_at before this data will not be synced." + examples: + - "2022-03-01T00:00:00Z" + supportsNormalization: false + supportsDBT: false + supported_destination_sync_modes: [] - dockerImage: "airbyte/source-xkcd:0.1.1" spec: documentationUrl: "https://docs.airbyte.io/integrations/sources/xkcd" diff --git a/airbyte-integrations/connectors/source-xero/.dockerignore b/airbyte-integrations/connectors/source-xero/.dockerignore new file mode 100644 index 0000000000000..190409539bdc9 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/.dockerignore @@ -0,0 +1,6 @@ +* +!Dockerfile +!main.py +!source_xero +!setup.py +!secrets diff --git a/airbyte-integrations/connectors/source-xero/Dockerfile b/airbyte-integrations/connectors/source-xero/Dockerfile new file mode 100644 index 0000000000000..b9bb395fd1501 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/Dockerfile @@ -0,0 +1,38 @@ +FROM python:3.9.13-alpine3.15 as base + +# build and load all requirements +FROM base as builder +WORKDIR /airbyte/integration_code + +# upgrade pip to the latest version +RUN apk --no-cache upgrade \ + && pip install --upgrade pip \ + && apk --no-cache add tzdata build-base + + +COPY setup.py ./ +# install necessary packages to a temporary folder +RUN pip install --prefix=/install . + +# build a clean environment +FROM base +WORKDIR /airbyte/integration_code + +# copy all loaded and built libraries to a pure basic image +COPY --from=builder /install /usr/local +# add default timezone settings +COPY --from=builder /usr/share/zoneinfo/Etc/UTC /etc/localtime +RUN echo "Etc/UTC" > /etc/timezone + +# bash is installed for more convenient debugging. +RUN apk --no-cache add bash + +# copy payload code only +COPY main.py ./ +COPY source_xero ./source_xero + +ENV AIRBYTE_ENTRYPOINT "python /airbyte/integration_code/main.py" +ENTRYPOINT ["python", "/airbyte/integration_code/main.py"] + +LABEL io.airbyte.version=0.1.0 +LABEL io.airbyte.name=airbyte/source-xero diff --git a/airbyte-integrations/connectors/source-xero/README.md b/airbyte-integrations/connectors/source-xero/README.md new file mode 100644 index 0000000000000..464447527fcf3 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/README.md @@ -0,0 +1,132 @@ +# Xero Source + +This is the repository for the Xero source connector, written in Python. +For information about how to use this connector within Airbyte, see [the documentation](https://docs.airbyte.io/integrations/sources/xero). + +## Local development + +### Prerequisites +**To iterate on this connector, make sure to complete this prerequisites section.** + +#### Minimum Python version required `= 3.9.0` + +#### Build & Activate Virtual Environment and install dependencies +From this connector directory, create a virtual environment: +``` +python -m venv .venv +``` + +This will generate a virtualenv for this module in `.venv/`. Make sure this venv is active in your +development environment of choice. To activate it from the terminal, run: +``` +source .venv/bin/activate +pip install -r requirements.txt +pip install '.[tests]' +``` +If you are in an IDE, follow your IDE's instructions to activate the virtualenv. + +Note that while we are installing dependencies from `requirements.txt`, you should only edit `setup.py` for your dependencies. `requirements.txt` is +used for editable installs (`pip install -e`) to pull in Python dependencies from the monorepo and will call `setup.py`. +If this is mumbo jumbo to you, don't worry about it, just put your deps in `setup.py` but install using `pip install -r requirements.txt` and everything +should work as you expect. + +#### Building via Gradle +You can also build the connector in Gradle. This is typically used in CI and not needed for your development workflow. + +To build using Gradle, from the Airbyte repository root, run: +``` +./gradlew :airbyte-integrations:connectors:source-xero:build +``` + +#### Create credentials +**If you are a community contributor**, follow the instructions in the [documentation](https://docs.airbyte.io/integrations/sources/xero) +to generate the necessary credentials. Then create a file `secrets/config.json` conforming to the `source_xero/spec.yaml` file. +Note that any directory named `secrets` is gitignored across the entire Airbyte repo, so there is no danger of accidentally checking in sensitive information. +See `integration_tests/sample_config.json` for a sample config file. + +**If you are an Airbyte core member**, copy the credentials in Lastpass under the secret name `source xero test creds` +and place them into `secrets/config.json`. + +### Locally running the connector +``` +python main.py spec +python main.py check --config secrets/config.json +python main.py discover --config secrets/config.json +python main.py read --config secrets/config.json --catalog integration_tests/configured_catalog.json +``` + +### Locally running the connector docker image + +#### Build +First, make sure you build the latest Docker image: +``` +docker build . -t airbyte/source-xero:dev +``` + +You can also build the connector image via Gradle: +``` +./gradlew :airbyte-integrations:connectors:source-xero:airbyteDocker +``` +When building via Gradle, the docker image name and tag, respectively, are the values of the `io.airbyte.name` and `io.airbyte.version` `LABEL`s in +the Dockerfile. + +#### Run +Then run any of the connector commands as follows: +``` +docker run --rm airbyte/source-xero:dev spec +docker run --rm -v $(pwd)/secrets:/secrets airbyte/source-xero:dev check --config /secrets/config.json +docker run --rm -v $(pwd)/secrets:/secrets airbyte/source-xero:dev discover --config /secrets/config.json +docker run --rm -v $(pwd)/secrets:/secrets -v $(pwd)/integration_tests:/integration_tests airbyte/source-xero:dev read --config /secrets/config.json --catalog /integration_tests/configured_catalog.json +``` +## Testing +Make sure to familiarize yourself with [pytest test discovery](https://docs.pytest.org/en/latest/goodpractices.html#test-discovery) to know how your test files and methods should be named. +First install test dependencies into your virtual environment: +``` +pip install .[tests] +``` +### Unit Tests +To run unit tests locally, from the connector directory run: +``` +python -m pytest unit_tests +``` + +### Integration Tests +There are two types of integration tests: Acceptance Tests (Airbyte's test suite for all source connectors) and custom integration tests (which are specific to this connector). +#### Custom Integration tests +Place custom tests inside `integration_tests/` folder, then, from the connector root, run +``` +python -m pytest integration_tests +``` +#### Acceptance Tests +Customize `acceptance-test-config.yml` file to configure tests. See [Source Acceptance Tests](https://docs.airbyte.io/connector-development/testing-connectors/source-acceptance-tests-reference) for more information. +If your connector requires to create or destroy resources for use during acceptance tests create fixtures for it and place them inside integration_tests/acceptance.py. +To run your integration tests with acceptance tests, from the connector root, run +``` +python -m pytest integration_tests -p integration_tests.acceptance +``` +To run your integration tests with docker + +### Using gradle to run tests +All commands should be run from airbyte project root. +To run unit tests: +``` +./gradlew :airbyte-integrations:connectors:source-xero:unitTest +``` +To run acceptance and custom integration tests: +``` +./gradlew :airbyte-integrations:connectors:source-xero:integrationTest +``` + +## Dependency Management +All of your dependencies should go in `setup.py`, NOT `requirements.txt`. The requirements file is only used to connect internal Airbyte dependencies in the monorepo for local development. +We split dependencies between two groups, dependencies that are: +* required for your connector to work need to go to `MAIN_REQUIREMENTS` list. +* required for the testing need to go to `TEST_REQUIREMENTS` list + +### Publishing a new version of the connector +You've checked out the repo, implemented a million dollar feature, and you're ready to share your changes with the world. Now what? +1. Make sure your changes are passing unit and integration tests. +1. Bump the connector version in `Dockerfile` -- just increment the value of the `LABEL io.airbyte.version` appropriately (we use [SemVer](https://semver.org/)). +1. Create a Pull Request. +1. Pat yourself on the back for being an awesome contributor. +1. Someone from Airbyte will take a look at your PR and iterate with you to merge it into master. diff --git a/airbyte-integrations/connectors/source-xero/acceptance-test-config.yml b/airbyte-integrations/connectors/source-xero/acceptance-test-config.yml new file mode 100644 index 0000000000000..561ba6e64d519 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/acceptance-test-config.yml @@ -0,0 +1,24 @@ +# See [Source Acceptance Tests](https://docs.airbyte.com/connector-development/testing-connectors/source-acceptance-tests-reference) +# for more information about how to configure these tests +connector_image: airbyte/source-xero:dev +tests: + spec: + - spec_path: "source_xero/spec.yaml" + connection: + - config_path: "integration_tests/sample_config.json" + status: "succeed" + - config_path: "integration_tests/invalid_config.json" + status: "failed" + discovery: + - config_path: "integration_tests/sample_config.json" + basic_read: + - config_path: "integration_tests/sample_config.json" + configured_catalog_path: "integration_tests/configured_catalog.json" + empty_streams: ["manual_journals", "credit_notes", "overpayments", "bank_transfers", "purchase_orders", "prepayments"] + incremental: + - config_path: "integration_tests/sample_config.json" + configured_catalog_path: "integration_tests/configured_catalog.json" + future_state_path: "integration_tests/abnormal_state.json" + full_refresh: + - config_path: "integration_tests/sample_config.json" + configured_catalog_path: "integration_tests/configured_catalog.json" diff --git a/airbyte-integrations/connectors/source-xero/acceptance-test-docker.sh b/airbyte-integrations/connectors/source-xero/acceptance-test-docker.sh new file mode 100644 index 0000000000000..c51577d10690c --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/acceptance-test-docker.sh @@ -0,0 +1,16 @@ +#!/usr/bin/env sh + +# Build latest connector image +docker build . -t $(cat acceptance-test-config.yml | grep "connector_image" | head -n 1 | cut -d: -f2-) + +# Pull latest acctest image +docker pull airbyte/source-acceptance-test:latest + +# Run +docker run --rm -it \ + -v /var/run/docker.sock:/var/run/docker.sock \ + -v /tmp:/tmp \ + -v $(pwd):/test_input \ + airbyte/source-acceptance-test \ + --acceptance-test-config /test_input + diff --git a/airbyte-integrations/connectors/source-xero/build.gradle b/airbyte-integrations/connectors/source-xero/build.gradle new file mode 100644 index 0000000000000..53f3682cb2d2e --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/build.gradle @@ -0,0 +1,9 @@ +plugins { + id 'airbyte-python' + id 'airbyte-docker' + id 'airbyte-source-acceptance-test' +} + +airbytePython { + moduleDirectory 'source_xero' +} diff --git a/airbyte-integrations/connectors/source-xero/integration_tests/__init__.py b/airbyte-integrations/connectors/source-xero/integration_tests/__init__.py new file mode 100644 index 0000000000000..1100c1c58cf51 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/integration_tests/__init__.py @@ -0,0 +1,3 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# diff --git a/airbyte-integrations/connectors/source-xero/integration_tests/abnormal_state.json b/airbyte-integrations/connectors/source-xero/integration_tests/abnormal_state.json new file mode 100644 index 0000000000000..d74620ed0246b --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/integration_tests/abnormal_state.json @@ -0,0 +1,44 @@ +{ + "bank_transactions": { + "date": "2033-10-28T11:08:03+00:00" + }, + "contacts": { + "date": "2033-10-30T10:47:59+00:00" + }, + "credit_notes": { + "date": "2033-10-28T11:06:20+00:00" + }, + "invoices": { + "date": "2033-10-28T16:36:42+00:00" + }, + "manual_journals": { + "date": "2033-10-28T12:08:59+00:00" + }, + "overpayments": { + "date": "2033-10-28T12:30:01+00:00" + }, + "prepayments": { + "date": "2033-10-18T11:51:45+00:00" + }, + "purchase_orders": { + "date": "2033-10-18T11:51:45+00:00" + }, + "accounts": { + "date": "2033-10-18T11:51:45+00:00" + }, + "bank_transfers": { + "date": "2033-10-28T07:28:42+00:00" + }, + "employees": { + "date": "2033-10-18T11:51:45+00:00" + }, + "items": { + "date": "2033-10-18T11:51:45+00:00" + }, + "payments": { + "date": "2033-10-28T16:36:42+00:00" + }, + "users": { + "date": "2033-08-30T09:53:59+00:00" + } +} \ No newline at end of file diff --git a/airbyte-integrations/connectors/source-xero/integration_tests/acceptance.py b/airbyte-integrations/connectors/source-xero/integration_tests/acceptance.py new file mode 100644 index 0000000000000..950b53b59d416 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/integration_tests/acceptance.py @@ -0,0 +1,14 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + + +import pytest + +pytest_plugins = ("source_acceptance_test.plugin",) + + +@pytest.fixture(scope="session", autouse=True) +def connector_setup(): + """This fixture is a placeholder for external resources that acceptance test might require.""" + yield diff --git a/airbyte-integrations/connectors/source-xero/integration_tests/configured_catalog.json b/airbyte-integrations/connectors/source-xero/integration_tests/configured_catalog.json new file mode 100644 index 0000000000000..933ec4fe4e2be --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/integration_tests/configured_catalog.json @@ -0,0 +1,30441 @@ +{ + "streams": [ + { + "stream": { + "name": "bank_transactions", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "BankAccount": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "DateString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "BankTransactionID": { + "type": [ + "string" + ] + }, + "PrepaymentID": { + "type": [ + "null", + "string" + ] + }, + "OverpaymentID": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ExternalLinkProviderName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "BankTransactionID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "contacts", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "ContactID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "credit_notes", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CreditNoteID": { + "type": [ + "string" + ] + }, + "CreditNoteNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "CreditNoteID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "invoices", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ExpectedPaymentDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "PaymentType": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Account": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "CreditNote": { + "type": [ + "null", + "object" + ], + "properties": { + "CreditNoteNumber": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PrepaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayment": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "OverpaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "BankAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "PaymentID": { + "type": [ + "string" + ] + }, + "HasAccount": { + "type": [ + "null", + "boolean" + ] + }, + "BatchPaymentID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "CreditNotes": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CreditNoteID": { + "type": [ + "string" + ] + }, + "CreditNoteNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "PrepaymentID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + } + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "PaymentType": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Account": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "CreditNote": { + "type": [ + "null", + "object" + ], + "properties": { + "CreditNoteNumber": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PrepaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayment": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "OverpaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "BankAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "PaymentID": { + "type": [ + "string" + ] + }, + "HasAccount": { + "type": [ + "null", + "boolean" + ] + }, + "BatchPaymentID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "OverpaymentID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + } + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "PaymentType": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Account": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "CreditNote": { + "type": [ + "null", + "object" + ], + "properties": { + "CreditNoteNumber": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PrepaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayment": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "OverpaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "BankAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "PaymentID": { + "type": [ + "string" + ] + }, + "HasAccount": { + "type": [ + "null", + "boolean" + ] + }, + "BatchPaymentID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "DateString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true + } + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "InvoiceID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "manual_journals", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Narration": { + "type": [ + "null", + "string" + ] + }, + "JournalLines": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountID": { + "type": [ + "null", + "string" + ] + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "IsBlank": { + "type": [ + "null", + "boolean" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "ShowOnCashBasisReports": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ManualJournalID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "ManualJournalID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "overpayments", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "OverpaymentID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + } + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "PaymentType": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Account": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "CreditNote": { + "type": [ + "null", + "object" + ], + "properties": { + "CreditNoteNumber": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PrepaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayment": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "OverpaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "BankAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "PaymentID": { + "type": [ + "string" + ] + }, + "HasAccount": { + "type": [ + "null", + "boolean" + ] + }, + "BatchPaymentID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "DateString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "OverpaymentID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "prepayments", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "PrepaymentID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + } + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "PaymentType": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Account": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "CreditNote": { + "type": [ + "null", + "object" + ], + "properties": { + "CreditNoteNumber": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PrepaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayment": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "OverpaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "BankAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "PaymentID": { + "type": [ + "string" + ] + }, + "HasAccount": { + "type": [ + "null", + "boolean" + ] + }, + "BatchPaymentID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "PrepaymentID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "purchase_orders", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DeliveryDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "PurchaseOrderNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "DeliveryAddress": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "Telephone": { + "type": [ + "null", + "string" + ] + }, + "DeliveryInstructions": { + "type": [ + "null", + "string" + ] + }, + "ExpectedArrivalDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "PurchaseOrderID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DeliveryDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedArrivalDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "PurchaseOrderID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "accounts", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "AccountID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "bank_transfers", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "FromBankAccount": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "ToBankAccount": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "DateString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "BankTransferID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FromBankTransactionID": { + "type": [ + "null", + "string" + ] + }, + "ToBankTransactionID": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CreatedDateUTCString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "CreatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "BankTransferID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "employees", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "ExternalLink": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "EmployeeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "EmployeeID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "items", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "ItemID": { + "type": [ + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "IsSold": { + "type": [ + "null", + "boolean" + ] + }, + "IsPurchased": { + "type": [ + "null", + "boolean" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "PurchaseDescription": { + "type": [ + "null", + "string" + ] + }, + "PurchaseDetails": { + "properties": { + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "COGSAccountCode": { + "type": [ + "null", + "string" + ] + }, + "UnitPrice": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + } + }, + "type": [ + "null", + "object" + ], + "additionalProperties": true + }, + "SalesDetails": { + "properties": { + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "UnitPrice": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + } + }, + "type": [ + "null", + "object" + ], + "additionalProperties": true + }, + "IsTrackedAsInventory": { + "type": [ + "null", + "boolean" + ] + }, + "InventoryAssetAccountCode": { + "type": [ + "null", + "string" + ] + }, + "TotalCostPool": { + "type": [ + "null", + "number" + ] + }, + "QuantityOnHand": { + "type": [ + "null", + "number" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "ItemID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "payments", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "PaymentType": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Account": { + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "Invoice": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "CreditNote": { + "type": [ + "null", + "object" + ], + "properties": { + "CreditNoteNumber": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PrepaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayment": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "OverpaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "BankAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "PaymentID": { + "type": [ + "string" + ] + }, + "HasAccount": { + "type": [ + "null", + "boolean" + ] + }, + "BatchPaymentID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "PaymentID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream":{ + "name": "users", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "UserID": { + "type": [ + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsSubscriber": { + "type": [ + "null", + "boolean" + ] + }, + "OrganisationRole": { + "type": [ + "null", + "string" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh", + "incremental" + ], + "source_defined_cursor": true, + "default_cursor_field": [ + "UpdatedDateUTC" + ], + "source_defined_primary_key": [ + [ + "UserID" + ] + ] + }, + "sync_mode": "incremental", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "branding_themes", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh" + ], + "source_defined_primary_key": [ + [ + "BrandingThemeID" + ] + ] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "contact_groups", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh" + ], + "source_defined_primary_key": [ + [ + "ContactGroupID" + ] + ] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "currencies", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh" + ], + "source_defined_primary_key": [ + [ + "Code" + ] + ] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "organisations", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "APIKey": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "LegalName": { + "type": [ + "null", + "string" + ] + }, + "PaysTax": { + "type": [ + "null", + "boolean" + ] + }, + "Version": { + "type": [ + "null", + "string" + ] + }, + "OrganisationType": { + "type": [ + "null", + "string" + ] + }, + "BaseCurrency": { + "type": [ + "null", + "string" + ] + }, + "CountryCode": { + "type": [ + "null", + "string" + ] + }, + "IsDemoCompany": { + "type": [ + "null", + "boolean" + ] + }, + "OrganisationStatus": { + "type": [ + "null", + "string" + ] + }, + "RegistrationNumber": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "FinancialYearEndDay": { + "type": [ + "null", + "integer" + ] + }, + "FinancialYearEndMonth": { + "type": [ + "null", + "integer" + ] + }, + "SalesTaxBasis": { + "type": [ + "null", + "string" + ] + }, + "SalesTaxPeriod": { + "type": [ + "null", + "string" + ] + }, + "DefaultSalesTax": { + "type": [ + "null", + "string" + ] + }, + "DefaultPurchasesTax": { + "type": [ + "null", + "string" + ] + }, + "PeriodLockDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "EndOfYearLockDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Timezone": { + "type": [ + "null", + "string" + ] + }, + "OrganisationEntityType": { + "type": [ + "null", + "string" + ] + }, + "ShortCode": { + "type": [ + "null", + "string" + ] + }, + "OrganisationID": { + "type": [ + "string" + ] + }, + "LineOfBusiness": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Phones": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "ExternalLinks": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "LinkType": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh" + ], + "source_defined_primary_key": [ + [ + "OrganisationID" + ] + ] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "repeating_invoices", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "ContactGroups": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": {}, + "additionalProperties": true + } + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + } + }, + "additionalProperties": true + }, + "Schedule": { + "type": [ + "null", + "object" + ], + "properties": { + "Unit": { + "type": [ + "null", + "string" + ] + }, + "DueDateType": { + "type": [ + "null", + "string" + ] + }, + "StartDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "DueDate": { + "type": [ + "null", + "integer" + ] + }, + "EndDate": { + "type": [ + "null", + "string" + ] + }, + "NextScheduledDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Period": { + "type": [ + "null", + "integer" + ] + } + }, + "additionalProperties": true + }, + "LineItems": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RepeatingInvoiceID": { + "type": [ + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh" + ], + "source_defined_primary_key": [ + [ + "RepeatingInvoiceID" + ] + ] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "tax_rates", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Name": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "string" + ] + }, + "TaxComponents": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Name": { + "type": [ + "null", + "string" + ] + }, + "IsCompound": { + "type": [ + "null", + "boolean" + ] + }, + "IsNonRecoverable": { + "type": [ + "null", + "boolean" + ] + }, + "Rate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + } + }, + "additionalProperties": true + } + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ReportTaxType": { + "type": [ + "null", + "string" + ] + }, + "CanApplyToAssets": { + "type": [ + "null", + "boolean" + ] + }, + "CanApplyToEquity": { + "type": [ + "null", + "boolean" + ] + }, + "CanApplyToExpenses": { + "type": [ + "null", + "boolean" + ] + }, + "CanApplyToLiabilities": { + "type": [ + "null", + "boolean" + ] + }, + "CanApplyToRevenue": { + "type": [ + "null", + "boolean" + ] + }, + "DisplayTaxRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "EffectiveRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh" + ], + "source_defined_primary_key": [ + [ + "Name" + ] + ] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + }, + { + "stream": { + "name": "tracking_categories", + "json_schema": { + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "supported_sync_modes": [ + "full_refresh" + ], + "source_defined_primary_key": [ + [ + "TrackingCategoryID" + ] + ] + }, + "sync_mode": "full_refresh", + "destination_sync_mode": "append" + } + ] +} \ No newline at end of file diff --git a/airbyte-integrations/connectors/source-xero/integration_tests/invalid_config.json b/airbyte-integrations/connectors/source-xero/integration_tests/invalid_config.json new file mode 100644 index 0000000000000..92a19e286cfb6 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/integration_tests/invalid_config.json @@ -0,0 +1,10 @@ +{ + "client_id" : "client_id", + "client_secret" : "client_secret", + "tenant_id" : "tenant_id", + "scopes" : "scope1, scope2", + "authentication" : { + "auth_type" : null + }, + "start_date" : "2020-01-01T00:00:00Z" +} diff --git a/airbyte-integrations/connectors/source-xero/integration_tests/sample_config.json b/airbyte-integrations/connectors/source-xero/integration_tests/sample_config.json new file mode 100644 index 0000000000000..c3b06eafc9885 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/integration_tests/sample_config.json @@ -0,0 +1,10 @@ +{ + "client_id" : "389D15E4EE7D4EC09F91F2926EDE5B9B", + "client_secret" : "rumSF2vR4wGY-bhNOTqo1lttMgi0h_XobxyrKYBzrRUxj9nR", + "tenant_id" : "22b6dfc8-a47d-4e3d-a4ab-a30f22a5681d", + "scopes" : "accounting.attachments accounting.contacts accounting.transactions assets.read accounting.attachments.read accounting.contacts.read accounting.settings accounting.settings.read accounting.journals.read accounting.budgets.read accounting.reports.tenninetynine.read accounting.reports.read assets accounting.transactions.read", + "authentication" : { + "auth_type" : "custom_connection" + }, + "start_date" : "2021-01-01T00:00:00Z" +} \ No newline at end of file diff --git a/airbyte-integrations/connectors/source-xero/integration_tests/sample_state.json b/airbyte-integrations/connectors/source-xero/integration_tests/sample_state.json new file mode 100644 index 0000000000000..ce86cbe02c845 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/integration_tests/sample_state.json @@ -0,0 +1,36 @@ +{ + "bank_transactions": { + "date": "2021-10-28T11:08:03+00:00" + }, + "contacts": { + "date": "2021-10-30T10:47:59+00:00" + }, + "credit_notes": { + "date": "2021-10-28T11:06:20+00:00" + }, + "invoices": { + "date": "2021-10-28T16:36:42+00:00" + }, + "manual_journals": { + "date": "2021-10-28T12:08:59+00:00" + }, + "overpayments": { + "date": "2021-10-29T12:30:01+00:00" + }, + "prepayments": {}, + "purchase_orders": {}, + "accounts": { + "date": "2021-10-18T11:51:45+00:00" + }, + "bank_transfers": { + "date": "2021-10-28T07:28:42+00:00" + }, + "employees": {}, + "items": {}, + "payments": { + "date": "2021-10-28T16:36:42+00:00" + }, + "users": { + "date": "2021-08-30T09:53:59+00:00" + } +} \ No newline at end of file diff --git a/airbyte-integrations/connectors/source-xero/main.py b/airbyte-integrations/connectors/source-xero/main.py new file mode 100644 index 0000000000000..621db168b0f05 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/main.py @@ -0,0 +1,13 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + + +import sys + +from airbyte_cdk.entrypoint import launch +from source_xero import SourceXero + +if __name__ == "__main__": + source = SourceXero() + launch(source, sys.argv[1:]) diff --git a/airbyte-integrations/connectors/source-xero/requirements.txt b/airbyte-integrations/connectors/source-xero/requirements.txt new file mode 100644 index 0000000000000..0411042aa0911 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/requirements.txt @@ -0,0 +1,2 @@ +-e ../../bases/source-acceptance-test +-e . diff --git a/airbyte-integrations/connectors/source-xero/setup.py b/airbyte-integrations/connectors/source-xero/setup.py new file mode 100644 index 0000000000000..b1169baf208ea --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/setup.py @@ -0,0 +1,29 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + + +from setuptools import find_packages, setup + +MAIN_REQUIREMENTS = [ + "airbyte-cdk~=0.2", +] + +TEST_REQUIREMENTS = [ + "pytest~=6.1", + "pytest-mock~=3.6.1", + "source-acceptance-test", +] + +setup( + name="source_xero", + description="Source implementation for Xero.", + author="Airbyte", + author_email="contact@airbyte.io", + packages=find_packages(), + install_requires=MAIN_REQUIREMENTS, + package_data={"": ["*.json", "*.yaml", "schemas/*.json", "schemas/shared/*.json"]}, + extras_require={ + "tests": TEST_REQUIREMENTS, + }, +) diff --git a/airbyte-integrations/connectors/source-xero/source_xero/__init__.py b/airbyte-integrations/connectors/source-xero/source_xero/__init__.py new file mode 100644 index 0000000000000..0acbe42f5ac6f --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/__init__.py @@ -0,0 +1,8 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + + +from .source import SourceXero + +__all__ = ["SourceXero"] diff --git a/airbyte-integrations/connectors/source-xero/source_xero/bootstrap.md b/airbyte-integrations/connectors/source-xero/source_xero/bootstrap.md new file mode 100644 index 0000000000000..b5cf4bcf4a2c1 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/bootstrap.md @@ -0,0 +1,7 @@ +# Xero + +The Xero source connector interacts with [Xero Accounting API](https://developer.xero.com/documentation/api/accounting/overview), which provides all accounting data such as invoices, contacts, bank transactions etc. + +Unfortunately, it requires [Xero Custom Connections](https://developer.xero.com/documentation/guides/oauth2/custom-connections/) subscription to work as default Xero OAuth2 Authentication supports only short-lived access_tokens with frequently updated refresh_tokens. + +For testing and development purposes you can use [Xero demo company](https://developer.xero.com/documentation/development-accounts/#accessing-the-xero-demo-company) with Xero Custom Connections free of charge. diff --git a/airbyte-integrations/connectors/source-xero/source_xero/oauth.py b/airbyte-integrations/connectors/source-xero/source_xero/oauth.py new file mode 100644 index 0000000000000..32444ded4418d --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/oauth.py @@ -0,0 +1,75 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + +import base64 +import logging +from typing import Any, List, Mapping, MutableMapping, Tuple + +import pendulum +import requests +from airbyte_cdk.sources.streams.http.requests_native_auth import Oauth2Authenticator + +logger = logging.getLogger("airbyte") + + +class XeroCustomConnectionsOauth2Authenticator(Oauth2Authenticator): + """ + Generates OAuth2.0 access tokens from an OAuth2.0 refresh token and client credentials. + The generated access token is attached to each request via the Authorization header. + """ + + def __init__( + self, + token_refresh_endpoint: str, + client_id: str, + client_secret: str, + scopes: List[str] = None, + token_expiry_date: pendulum.DateTime = None, + access_token_name: str = "access_token", + expires_in_name: str = "expires_in", + ): + self.token_refresh_endpoint = token_refresh_endpoint + self.client_secret = client_secret + self.client_id = client_id + self.scopes = scopes + self.access_token_name = access_token_name + self.expires_in_name = expires_in_name + + self._token_expiry_date = token_expiry_date or pendulum.now().subtract(days=1) + self._access_token = None + + def __call__(self, request): + request.headers.update(self.get_auth_header()) + return request + + def get_auth_header(self) -> Mapping[str, Any]: + return {"Authorization": f"Bearer {self.get_access_token()}"} + + def token_has_expired(self) -> bool: + return pendulum.now() > self._token_expiry_date + + def get_refresh_request_body(self) -> Mapping[str, Any]: + payload: MutableMapping[str, Any] = { + "grant_type": "client_credentials", + } + + if self.scopes: + payload["scopes"] = self.scopes + + return payload + + def get_refresh_request_headers(self) -> Mapping[str, Any]: + headers: MutableMapping[str, Any] = { + "Authorization": "Basic " + str(base64.b64encode(bytes(self.client_id + ":" + self.client_secret, "utf-8")), "utf-8") + } + + return headers + + def refresh_access_token(self) -> Tuple[str, int]: + response = requests.request( + method="POST", url=self.token_refresh_endpoint, data=self.get_refresh_request_body(), headers=self.get_refresh_request_headers() + ) + response.raise_for_status() + response_json = response.json() + return response_json[self.access_token_name], response_json[self.expires_in_name] diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/accounts.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/accounts.json new file mode 100644 index 0000000000000..4ce607f07f924 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/accounts.json @@ -0,0 +1,117 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/addresses.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/addresses.json new file mode 100644 index 0000000000000..04add4f490e8b --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/addresses.json @@ -0,0 +1,69 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/allocations.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/allocations.json new file mode 100644 index 0000000000000..9fa51522dc3df --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/allocations.json @@ -0,0 +1,27 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Invoice": { + "$ref": "nested_invoice.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/attachments.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/attachments.json new file mode 100644 index 0000000000000..5f7f5a6672386 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/attachments.json @@ -0,0 +1,15 @@ +{ + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + }, + "additionalProperties": true + } +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/bank_transactions.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/bank_transactions.json new file mode 100644 index 0000000000000..14f3cb3614f02 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/bank_transactions.json @@ -0,0 +1,148 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "line_items.json" + } + }, + "BankAccount": { + "$ref": "accounts.json" + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "DateString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "BankTransactionID": { + "type": [ + "string" + ] + }, + "PrepaymentID": { + "type": [ + "null", + "string" + ] + }, + "OverpaymentID": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ExternalLinkProviderName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/bank_transfers.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/bank_transfers.json new file mode 100644 index 0000000000000..debf58bdf47db --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/bank_transfers.json @@ -0,0 +1,82 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "FromBankAccount": { + "$ref": "accounts.json" + }, + "ToBankAccount": { + "$ref": "accounts.json" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "DateString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "BankTransferID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FromBankTransactionID": { + "type": [ + "null", + "string" + ] + }, + "ToBankTransactionID": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CreatedDateUTCString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/branding_themes.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/branding_themes.json new file mode 100644 index 0000000000000..fef5eb7184ee8 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/branding_themes.json @@ -0,0 +1,33 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/contact_groups.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/contact_groups.json new file mode 100644 index 0000000000000..0953fcc4eb4df --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/contact_groups.json @@ -0,0 +1,32 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/contacts.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/contacts.json new file mode 100644 index 0000000000000..ea664a6b88852 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/contacts.json @@ -0,0 +1,351 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "$ref": "addresses.json" + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "$ref": "phones.json" + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "tracking_categories.json" + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "tracking_categories.json" + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "$ref": "payment_terms.json" + }, + "ContactGroups": { + "items": { + "$ref": "contact_groups.json" + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "$ref": "branding_themes.json" + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "$ref": "attachments.json" + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "$ref": "validation_errors.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/credit_notes.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/credit_notes.json new file mode 100644 index 0000000000000..8f2b55ee4445c --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/credit_notes.json @@ -0,0 +1,185 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "$ref": "line_items.json" + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CreditNoteID": { + "type": [ + "string" + ] + }, + "CreditNoteNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "items": { + "$ref": "allocations.json" + }, + "type": [ + "null", + "array" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/currencies.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/currencies.json new file mode 100644 index 0000000000000..de82cfd1a53cc --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/currencies.json @@ -0,0 +1,20 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/customers.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/customers.json new file mode 100644 index 0000000000000..2368f4c779e55 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/customers.json @@ -0,0 +1,25 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema#", + "type": "object", + "properties": { + "id": { + "type": [ + "null", + "string" + ] + }, + "name": { + "type": [ + "null", + "string" + ] + }, + "signup_date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + } +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/employees.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/employees.json new file mode 100644 index 0000000000000..c6a2d0c8e74d1 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/employees.json @@ -0,0 +1,45 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "ExternalLink": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "EmployeeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/expense_claims.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/expense_claims.json new file mode 100644 index 0000000000000..ec9e403e4dccb --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/expense_claims.json @@ -0,0 +1,86 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "User": { + "$ref": "users.json" + }, + "Receipts": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "receipts.json" + } + }, + "ExpenseClaimID": { + "type": [ + "string" + ] + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "payments.json" + } + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "PaymentDueDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/invoices.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/invoices.json new file mode 100644 index 0000000000000..9613ca69ddfc1 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/invoices.json @@ -0,0 +1,268 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "line_items.json" + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ExpectedPaymentDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "payments.json" + } + }, + "CreditNotes": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "credit_notes.json" + } + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "prepayments.json" + } + }, + "Overpayments": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "overpayments.json" + } + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/items.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/items.json new file mode 100644 index 0000000000000..faec07beea07f --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/items.json @@ -0,0 +1,145 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "ItemID": { + "type": [ + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "IsSold": { + "type": [ + "null", + "boolean" + ] + }, + "IsPurchased": { + "type": [ + "null", + "boolean" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "PurchaseDescription": { + "type": [ + "null", + "string" + ] + }, + "PurchaseDetails": { + "properties": { + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "COGSAccountCode": { + "type": [ + "null", + "string" + ] + }, + "UnitPrice": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + } + }, + "type": [ + "null", + "object" + ], + "additionalProperties": true + }, + "SalesDetails": { + "properties": { + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "UnitPrice": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + } + }, + "type": [ + "null", + "object" + ], + "additionalProperties": true + }, + "IsTrackedAsInventory": { + "type": [ + "null", + "boolean" + ] + }, + "InventoryAssetAccountCode": { + "type": [ + "null", + "string" + ] + }, + "TotalCostPool": { + "type": [ + "null", + "number" + ] + }, + "QuantityOnHand": { + "type": [ + "null", + "number" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/journals.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/journals.json new file mode 100644 index 0000000000000..a0e432dd185fc --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/journals.json @@ -0,0 +1,142 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "JournalID": { + "type": [ + "string" + ] + }, + "JournalDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "JournalNumber": { + "type": [ + "null", + "integer" + ] + }, + "CreatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "SourceID": { + "type": [ + "null", + "string" + ] + }, + "SourceType": { + "type": [ + "null", + "string" + ] + }, + "JournalLines": { + "items": { + "properties": { + "JournalLineID": { + "type": [ + "null", + "string" + ] + }, + "AccountType": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "null", + "string" + ] + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "TaxName": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "GrossAmount": { + "type": [ + "null", + "number" + ] + }, + "NetAmount": { + "type": [ + "null", + "number" + ] + }, + "AccountName": { + "type": [ + "null", + "string" + ] + }, + "TaxAmount": { + "type": [ + "null", + "number" + ] + }, + "TrackingCategories": { + "items": { + "$ref": "tracking_categories.json" + }, + "type": [ + "null", + "array" + ] + } + }, + "type": [ + "null", + "object" + ], + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/line_items.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/line_items.json new file mode 100644 index 0000000000000..12eae7f0ddd03 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/line_items.json @@ -0,0 +1,87 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "$ref": "tracking_categories.json" + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/linked_transactions.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/linked_transactions.json new file mode 100644 index 0000000000000..9096e1c97c061 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/linked_transactions.json @@ -0,0 +1,69 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "LinkedTransactionID": { + "type": [ + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "SourceTransactionID": { + "type": [ + "null", + "string" + ] + }, + "SourceLineItemID": { + "type": [ + "null", + "string" + ] + }, + "SourceTransactionTypeCode": { + "type": [ + "null", + "string" + ] + }, + "ContactID": { + "type": [ + "null", + "string" + ] + }, + "TargetTransactionID": { + "type": [ + "null", + "string" + ] + }, + "TargetLineItemID": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/manual_journals.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/manual_journals.json new file mode 100644 index 0000000000000..ee7c6ac19e8db --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/manual_journals.json @@ -0,0 +1,134 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Narration": { + "type": [ + "null", + "string" + ] + }, + "JournalLines": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountID": { + "type": [ + "null", + "string" + ] + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "IsBlank": { + "type": [ + "null", + "boolean" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Tracking": { + "items": { + "$ref": "tracking_categories.json" + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true + } + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "ShowOnCashBasisReports": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ManualJournalID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/nested_invoice.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/nested_invoice.json new file mode 100644 index 0000000000000..afc3e4f81a910 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/nested_invoice.json @@ -0,0 +1,218 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "line_items.json" + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/organisations.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/organisations.json new file mode 100644 index 0000000000000..3c91c5c6e7d2f --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/organisations.json @@ -0,0 +1,215 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "APIKey": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "LegalName": { + "type": [ + "null", + "string" + ] + }, + "PaysTax": { + "type": [ + "null", + "boolean" + ] + }, + "Version": { + "type": [ + "null", + "string" + ] + }, + "OrganisationType": { + "type": [ + "null", + "string" + ] + }, + "BaseCurrency": { + "type": [ + "null", + "string" + ] + }, + "CountryCode": { + "type": [ + "null", + "string" + ] + }, + "IsDemoCompany": { + "type": [ + "null", + "boolean" + ] + }, + "OrganisationStatus": { + "type": [ + "null", + "string" + ] + }, + "RegistrationNumber": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "FinancialYearEndDay": { + "type": [ + "null", + "integer" + ] + }, + "FinancialYearEndMonth": { + "type": [ + "null", + "integer" + ] + }, + "SalesTaxBasis": { + "type": [ + "null", + "string" + ] + }, + "SalesTaxPeriod": { + "type": [ + "null", + "string" + ] + }, + "DefaultSalesTax": { + "type": [ + "null", + "string" + ] + }, + "DefaultPurchasesTax": { + "type": [ + "null", + "string" + ] + }, + "PeriodLockDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "EndOfYearLockDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Timezone": { + "type": [ + "null", + "string" + ] + }, + "OrganisationEntityType": { + "type": [ + "null", + "string" + ] + }, + "ShortCode": { + "type": [ + "null", + "string" + ] + }, + "OrganisationID": { + "type": [ + "string" + ] + }, + "LineOfBusiness": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "addresses.json" + } + }, + "Phones": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "phones.json" + } + }, + "ExternalLinks": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "LinkType": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "PaymentTerms": { + "$ref": "payment_terms.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/overpayments.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/overpayments.json new file mode 100644 index 0000000000000..cd9995a50a0cc --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/overpayments.json @@ -0,0 +1,155 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "$ref": "line_items.json" + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "OverpaymentID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "allocations.json" + } + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "payments.json" + } + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "DateString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/payment_terms.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/payment_terms.json new file mode 100644 index 0000000000000..e7c16ff52c4e4 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/payment_terms.json @@ -0,0 +1,51 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/payments.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/payments.json new file mode 100644 index 0000000000000..18efc6d2bc4fd --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/payments.json @@ -0,0 +1,154 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "PaymentType": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Account": { + "$ref": "accounts.json" + }, + "Invoice": { + "$ref": "nested_invoice.json" + }, + "CreditNote": { + "type": [ + "null", + "object" + ], + "properties": { + "CreditNoteNumber": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PrepaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayment": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "OverpaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "BankAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "PaymentID": { + "type": [ + "string" + ] + }, + "HasAccount": { + "type": [ + "null", + "boolean" + ] + }, + "BatchPaymentID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/phones.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/phones.json new file mode 100644 index 0000000000000..9b251c4f7307c --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/phones.json @@ -0,0 +1,33 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/prepayments.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/prepayments.json new file mode 100644 index 0000000000000..99efb81a6bce3 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/prepayments.json @@ -0,0 +1,155 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "$ref": "line_items.json" + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "PrepaymentID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "allocations.json" + } + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "payments.json" + } + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/purchase_orders.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/purchase_orders.json new file mode 100644 index 0000000000000..bc40f0baff60f --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/purchase_orders.json @@ -0,0 +1,205 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DeliveryDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "PurchaseOrderNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "line_items.json" + } + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "DeliveryAddress": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "Telephone": { + "type": [ + "null", + "string" + ] + }, + "DeliveryInstructions": { + "type": [ + "null", + "string" + ] + }, + "ExpectedArrivalDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "PurchaseOrderID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DeliveryDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedArrivalDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/quotes.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/quotes.json new file mode 100644 index 0000000000000..1124838ef2b42 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/quotes.json @@ -0,0 +1,151 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ExpiryDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "line_items.json" + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "QuoteID": { + "type": [ + "null", + "string" + ] + }, + "QuoteNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Title": { + "type": [ + "null", + "string" + ] + }, + "Summary": { + "type": [ + "null", + "string" + ] + }, + "Terms": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategory": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "tracking_categories.json" + } + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/receipts.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/receipts.json new file mode 100644 index 0000000000000..2de37403dd7c8 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/receipts.json @@ -0,0 +1,115 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Contact": { + "$ref": "contacts.json" + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "line_items.json" + } + }, + "User": { + "$ref": "users.json" + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "ReceiptID": { + "type": [ + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ReceiptNumber": { + "type": [ + "null", + "integer" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "ValidationErrors": { + "$ref": "validation_errors.json" + }, + "Attachments": { + "$ref": "attachments.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/repeating_invoices.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/repeating_invoices.json new file mode 100644 index 0000000000000..89459cea7fd4c --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/repeating_invoices.json @@ -0,0 +1,159 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Schedule": { + "type": [ + "null", + "object" + ], + "properties": { + "Unit": { + "type": [ + "null", + "string" + ] + }, + "DueDateType": { + "type": [ + "null", + "string" + ] + }, + "StartDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "DueDate": { + "type": [ + "null", + "integer" + ] + }, + "EndDate": { + "type": [ + "null", + "string" + ] + }, + "NextScheduledDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Period": { + "type": [ + "null", + "integer" + ] + } + }, + "additionalProperties": true + }, + "LineItems": { + "items": { + "$ref": "line_items.json" + }, + "type": [ + "null", + "array" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RepeatingInvoiceID": { + "type": [ + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/accounts.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/accounts.json new file mode 100644 index 0000000000000..4ce607f07f924 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/accounts.json @@ -0,0 +1,117 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Code": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "ReportingCodeName": { + "type": [ + "null", + "string" + ] + }, + "SystemAccount": { + "type": [ + "null", + "string" + ] + }, + "BankAccountType": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "Description": { + "type": [ + "null", + "string" + ] + }, + "Class": { + "type": [ + "null", + "string" + ] + }, + "AccountID": { + "type": [ + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ShowInExpenseClaims": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "ReportingCode": { + "type": [ + "null", + "string" + ] + }, + "EnablePaymentsToAccount": { + "type": [ + "null", + "boolean" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/addresses.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/addresses.json new file mode 100644 index 0000000000000..04add4f490e8b --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/addresses.json @@ -0,0 +1,69 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Region": { + "type": [ + "null", + "string" + ] + }, + "AddressLine1": { + "type": [ + "null", + "string" + ] + }, + "AddressLine2": { + "type": [ + "null", + "string" + ] + }, + "AddressLine3": { + "type": [ + "null", + "string" + ] + }, + "AddressLine4": { + "type": [ + "null", + "string" + ] + }, + "AttentionTo": { + "type": [ + "null", + "string" + ] + }, + "City": { + "type": [ + "null", + "string" + ] + }, + "PostalCode": { + "type": [ + "null", + "string" + ] + }, + "Country": { + "type": [ + "null", + "string" + ] + }, + "AddressType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/allocations.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/allocations.json new file mode 100644 index 0000000000000..9fa51522dc3df --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/allocations.json @@ -0,0 +1,27 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Invoice": { + "$ref": "nested_invoice.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/attachments.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/attachments.json new file mode 100644 index 0000000000000..5f7f5a6672386 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/attachments.json @@ -0,0 +1,15 @@ +{ + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + }, + "additionalProperties": true + } +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/branding_themes.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/branding_themes.json new file mode 100644 index 0000000000000..fef5eb7184ee8 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/branding_themes.json @@ -0,0 +1,33 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "CreatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "SortOrder": { + "type": [ + "null", + "integer" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/contact_groups.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/contact_groups.json new file mode 100644 index 0000000000000..0953fcc4eb4df --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/contact_groups.json @@ -0,0 +1,32 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "ContactGroupID": { + "type": [ + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/contacts.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/contacts.json new file mode 100644 index 0000000000000..ea664a6b88852 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/contacts.json @@ -0,0 +1,351 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "ContactID": { + "type": [ + "string" + ] + }, + "ContactNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountNumber": { + "type": [ + "null", + "string" + ] + }, + "ContactStatus": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "SkypeUserName": { + "type": [ + "null", + "string" + ] + }, + "BankAccountDetails": { + "type": [ + "null", + "string" + ] + }, + "TaxNumber": { + "type": [ + "null", + "string" + ] + }, + "AccountsReceivableTaxType": { + "type": [ + "null", + "string" + ] + }, + "AccountsPayableTaxType": { + "type": [ + "null", + "string" + ] + }, + "Addresses": { + "items": { + "$ref": "addresses.json" + }, + "type": [ + "null", + "array" + ] + }, + "Phones": { + "items": { + "$ref": "phones.json" + }, + "type": [ + "null", + "array" + ] + }, + "IsSupplier": { + "type": [ + "null", + "boolean" + ] + }, + "IsCustomer": { + "type": [ + "null", + "boolean" + ] + }, + "DefaultCurrency": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ContactPersons": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "IncludeInEmails": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + } + }, + "XeroNetworkKey": { + "type": [ + "null", + "string" + ] + }, + "SalesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "PurchasesDefaultAccountCode": { + "type": [ + "null", + "string" + ] + }, + "SalesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "tracking_categories.json" + } + }, + "PurchasesTrackingCategories": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "tracking_categories.json" + } + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryOption": { + "type": [ + "null", + "string" + ] + }, + "PaymentTerms": { + "$ref": "payment_terms.json" + }, + "ContactGroups": { + "items": { + "$ref": "contact_groups.json" + }, + "type": [ + "null", + "array" + ] + }, + "Website": { + "type": [ + "null", + "string" + ] + }, + "BrandingTheme": { + "$ref": "branding_themes.json" + }, + "BatchPayments": { + "type": [ + "null", + "object" + ], + "properties": { + "Details": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "Code": { + "type": [ + "null", + "string" + ] + }, + "BankAccountNumber": { + "type": [ + "null", + "string" + ] + }, + "BankAccountName": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Discount": { + "type": [ + "null", + "number" + ] + }, + "Balances": { + "type": [ + "null", + "object" + ], + "properties": { + "AccountsReceivable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + }, + "AccountsPayable": { + "type": [ + "null", + "object" + ], + "properties": { + "Outstanding": { + "type": [ + "null", + "number" + ] + }, + "Overdue": { + "type": [ + "null", + "number" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Attachments": { + "$ref": "attachments.json" + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "ValidationErrors": { + "$ref": "validation_errors.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/credit_notes.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/credit_notes.json new file mode 100644 index 0000000000000..8f2b55ee4445c --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/credit_notes.json @@ -0,0 +1,185 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "$ref": "line_items.json" + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CreditNoteID": { + "type": [ + "string" + ] + }, + "CreditNoteNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "items": { + "$ref": "allocations.json" + }, + "type": [ + "null", + "array" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/line_items.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/line_items.json new file mode 100644 index 0000000000000..12eae7f0ddd03 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/line_items.json @@ -0,0 +1,87 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Description": { + "type": [ + "null", + "string" + ] + }, + "Quantity": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UnitAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AccountCode": { + "type": [ + "null", + "string" + ] + }, + "ItemCode": { + "type": [ + "null", + "string" + ] + }, + "LineItemID": { + "type": [ + "string" + ] + }, + "TaxType": { + "type": [ + "null", + "string" + ] + }, + "LineAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TaxAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DiscountRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Tracking": { + "items": { + "$ref": "tracking_categories.json" + }, + "type": [ + "null", + "array" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/nested_invoice.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/nested_invoice.json new file mode 100644 index 0000000000000..afc3e4f81a910 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/nested_invoice.json @@ -0,0 +1,218 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "DueDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "line_items.json" + } + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "InvoiceID": { + "type": [ + "string" + ] + }, + "InvoiceNumber": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "SentToContact": { + "type": [ + "null", + "boolean" + ] + }, + "ExpectedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "PlannedPaymentDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "AmountDue": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AmountPaid": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "FullyPaidOnDate": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "AmountCredited": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DueDateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsDiscounted": { + "type": [ + "null", + "boolean" + ] + }, + "HasErrors": { + "type": [ + "null", + "boolean" + ] + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/overpayments.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/overpayments.json new file mode 100644 index 0000000000000..cd9995a50a0cc --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/overpayments.json @@ -0,0 +1,155 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "$ref": "line_items.json" + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "OverpaymentID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "allocations.json" + } + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "payments.json" + } + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "DateString": { + "type": [ + "null", + "string" + ], + "format": "date-time" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/payment_terms.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/payment_terms.json new file mode 100644 index 0000000000000..e7c16ff52c4e4 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/payment_terms.json @@ -0,0 +1,51 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Sales": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + }, + "Bills": { + "type": [ + "null", + "object" + ], + "properties": { + "Day": { + "type": [ + "null", + "integer" + ] + }, + "Type": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/payments.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/payments.json new file mode 100644 index 0000000000000..18efc6d2bc4fd --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/payments.json @@ -0,0 +1,154 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Amount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "IsReconciled": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "PaymentType": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Account": { + "$ref": "accounts.json" + }, + "Invoice": { + "$ref": "nested_invoice.json" + }, + "CreditNote": { + "type": [ + "null", + "object" + ], + "properties": { + "CreditNoteNumber": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + }, + "Prepayments": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "PrepaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "Overpayment": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "OverpaymentID": { + "type": [ + "string" + ] + } + }, + "additionalProperties": true + } + }, + "BankAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + }, + "PaymentID": { + "type": [ + "string" + ] + }, + "HasAccount": { + "type": [ + "null", + "boolean" + ] + }, + "BatchPaymentID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/phones.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/phones.json new file mode 100644 index 0000000000000..9b251c4f7307c --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/phones.json @@ -0,0 +1,33 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "PhoneNumber": { + "type": [ + "null", + "string" + ] + }, + "PhoneAreaCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneCountryCode": { + "type": [ + "null", + "string" + ] + }, + "PhoneType": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/prepayments.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/prepayments.json new file mode 100644 index 0000000000000..99efb81a6bce3 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/prepayments.json @@ -0,0 +1,155 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Date": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "LineItems": { + "items": { + "$ref": "line_items.json" + }, + "type": [ + "null", + "array" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "PrepaymentID": { + "type": [ + "string" + ] + }, + "CurrencyRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "RemainingCredit": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "AppliedAmount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Allocations": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "allocations.json" + } + }, + "Payments": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "payments.json" + } + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "DateString": { + "format": "date-time", + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/receipts.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/receipts.json new file mode 100644 index 0000000000000..2de37403dd7c8 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/receipts.json @@ -0,0 +1,115 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Date": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Contact": { + "$ref": "contacts.json" + }, + "LineItems": { + "type": [ + "null", + "array" + ], + "items": { + "$ref": "line_items.json" + } + }, + "User": { + "$ref": "users.json" + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "ReceiptID": { + "type": [ + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ReceiptNumber": { + "type": [ + "null", + "integer" + ] + }, + "UpdatedDateUTC": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "Url": { + "type": [ + "null", + "string" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + }, + "ValidationErrors": { + "$ref": "validation_errors.json" + }, + "Attachments": { + "$ref": "attachments.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/repeating_invoices.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/repeating_invoices.json new file mode 100644 index 0000000000000..89459cea7fd4c --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/repeating_invoices.json @@ -0,0 +1,159 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Type": { + "type": [ + "null", + "string" + ] + }, + "Contact": { + "$ref": "contacts.json" + }, + "Schedule": { + "type": [ + "null", + "object" + ], + "properties": { + "Unit": { + "type": [ + "null", + "string" + ] + }, + "DueDateType": { + "type": [ + "null", + "string" + ] + }, + "StartDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "DueDate": { + "type": [ + "null", + "integer" + ] + }, + "EndDate": { + "type": [ + "null", + "string" + ] + }, + "NextScheduledDate": { + "type": [ + "null", + "string" + ], + "format": "date-time" + }, + "Period": { + "type": [ + "null", + "integer" + ] + } + }, + "additionalProperties": true + }, + "LineItems": { + "items": { + "$ref": "line_items.json" + }, + "type": [ + "null", + "array" + ] + }, + "LineAmountTypes": { + "type": [ + "null", + "string" + ] + }, + "Reference": { + "type": [ + "null", + "string" + ] + }, + "BrandingThemeID": { + "type": [ + "null", + "string" + ] + }, + "CurrencyCode": { + "type": [ + "null", + "string" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "SubTotal": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalTax": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "TotalDiscount": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "Total": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "RepeatingInvoiceID": { + "type": [ + "string" + ] + }, + "HasAttachments": { + "type": [ + "null", + "boolean" + ] + }, + "ID": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/tracking_categories.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/tracking_categories.json new file mode 100644 index 0000000000000..1d1b4f7652120 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/tracking_categories.json @@ -0,0 +1,107 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/users.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/users.json new file mode 100644 index 0000000000000..b839e20f3c349 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/users.json @@ -0,0 +1,54 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "UserID": { + "type": [ + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsSubscriber": { + "type": [ + "null", + "boolean" + ] + }, + "OrganisationRole": { + "type": [ + "null", + "string" + ] + }, + "ValidationErrors": { + "$ref": "validation_errors.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/validation_errors.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/validation_errors.json new file mode 100644 index 0000000000000..f58523cf54921 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/shared/validation_errors.json @@ -0,0 +1,21 @@ +{ + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/tax_rates.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/tax_rates.json new file mode 100644 index 0000000000000..1880205662438 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/tax_rates.json @@ -0,0 +1,119 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Name": { + "type": [ + "null", + "string" + ] + }, + "TaxType": { + "type": [ + "string" + ] + }, + "TaxComponents": { + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Name": { + "type": [ + "null", + "string" + ] + }, + "IsCompound": { + "type": [ + "null", + "boolean" + ] + }, + "IsNonRecoverable": { + "type": [ + "null", + "boolean" + ] + }, + "Rate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + } + }, + "additionalProperties": true + } + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "ReportTaxType": { + "type": [ + "null", + "string" + ] + }, + "CanApplyToAssets": { + "type": [ + "null", + "boolean" + ] + }, + "CanApplyToEquity": { + "type": [ + "null", + "boolean" + ] + }, + "CanApplyToExpenses": { + "type": [ + "null", + "boolean" + ] + }, + "CanApplyToLiabilities": { + "type": [ + "null", + "boolean" + ] + }, + "CanApplyToRevenue": { + "type": [ + "null", + "boolean" + ] + }, + "DisplayTaxRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + }, + "EffectiveRate": { + "type": [ + "null", + "number" + ], + "minimum": -1e+33, + "maximum": 1e+33 + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/tracking_categories.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/tracking_categories.json new file mode 100644 index 0000000000000..1d1b4f7652120 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/tracking_categories.json @@ -0,0 +1,107 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "Status": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryID": { + "type": [ + "string" + ] + }, + "Option": { + "type": [ + "null", + "string" + ] + }, + "TrackingCategoryName": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "TrackingOptionName": { + "type": [ + "null", + "string" + ] + }, + "Options": { + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "IsActive": { + "type": [ + "null", + "boolean" + ] + }, + "IsDeleted": { + "type": [ + "null", + "boolean" + ] + }, + "TrackingOptionID": { + "type": [ + "null", + "string" + ] + }, + "IsArchived": { + "type": [ + "null", + "boolean" + ] + }, + "Status": { + "type": [ + "null", + "string" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + }, + "HasValidationErrors": { + "type": [ + "null", + "boolean" + ] + } + }, + "additionalProperties": true + }, + "type": [ + "null", + "array" + ] + }, + "Name": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/users.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/users.json new file mode 100644 index 0000000000000..b839e20f3c349 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/users.json @@ -0,0 +1,54 @@ +{ + "type": [ + "null", + "object" + ], + "properties": { + "UserID": { + "type": [ + "string" + ] + }, + "EmailAddress": { + "type": [ + "null", + "string" + ] + }, + "FirstName": { + "type": [ + "null", + "string" + ] + }, + "LastName": { + "type": [ + "null", + "string" + ] + }, + "UpdatedDateUTC": { + "format": "date-time", + "type": [ + "null", + "string" + ] + }, + "IsSubscriber": { + "type": [ + "null", + "boolean" + ] + }, + "OrganisationRole": { + "type": [ + "null", + "string" + ] + }, + "ValidationErrors": { + "$ref": "validation_errors.json" + } + }, + "additionalProperties": true +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/schemas/validation_errors.json b/airbyte-integrations/connectors/source-xero/source_xero/schemas/validation_errors.json new file mode 100644 index 0000000000000..f58523cf54921 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/schemas/validation_errors.json @@ -0,0 +1,21 @@ +{ + "type": [ + "null", + "array" + ], + "items": { + "type": [ + "null", + "object" + ], + "properties": { + "Message": { + "type": [ + "null", + "string" + ] + } + }, + "additionalProperties": true + } +} diff --git a/airbyte-integrations/connectors/source-xero/source_xero/source.py b/airbyte-integrations/connectors/source-xero/source_xero/source.py new file mode 100644 index 0000000000000..eeaf6b44e757f --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/source.py @@ -0,0 +1,95 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + +from typing import Any, List, Mapping, Tuple + +import pendulum +from airbyte_cdk.models import SyncMode +from airbyte_cdk.sources import AbstractSource +from airbyte_cdk.sources.streams import Stream + +from .oauth import XeroCustomConnectionsOauth2Authenticator +from .streams import ( + Accounts, + BankTransactions, + BankTransfers, + BrandingThemes, + ContactGroups, + Contacts, + CreditNotes, + Currencies, + Employees, + Invoices, + Items, + ManualJournals, + Organisations, + Overpayments, + Payments, + Prepayments, + PurchaseOrders, + RepeatingInvoices, + TaxRates, + TrackingCategories, + Users, +) + + +class SourceXero(AbstractSource): + config = None + + def check_connection(self, logger, config) -> Tuple[bool, any]: + self.config = config + stream_kwargs = self.get_stream_kwargs(config) + + organisations_stream = Organisations(**stream_kwargs) + organisations_gen = organisations_stream.read_records(sync_mode=SyncMode.full_refresh) + + organisation = next(organisations_gen) + + return organisation["OrganisationID"] == config.get("tenant_id"), None + + def streams(self, config: Mapping[str, Any]) -> List[Stream]: + self.config = config + stream_kwargs = self.get_stream_kwargs(config) + incremental_kwargs = {**stream_kwargs, "start_date": pendulum.parse(config.get("start_date"))} + streams = [ + BankTransactions(**incremental_kwargs), + Contacts(**incremental_kwargs), + CreditNotes(**incremental_kwargs), + Invoices(**incremental_kwargs), + ManualJournals(**incremental_kwargs), + Overpayments(**incremental_kwargs), + Prepayments(**incremental_kwargs), + PurchaseOrders(**incremental_kwargs), + Accounts(**incremental_kwargs), + BankTransfers(**incremental_kwargs), + Employees(**incremental_kwargs), + Items(**incremental_kwargs), + Payments(**incremental_kwargs), + Users(**incremental_kwargs), + BrandingThemes(**stream_kwargs), + ContactGroups(**stream_kwargs), + Currencies(**stream_kwargs), + Organisations(**stream_kwargs), + RepeatingInvoices(**stream_kwargs), + TaxRates(**stream_kwargs), + TrackingCategories(**stream_kwargs), + ] + return streams + + @staticmethod + def get_stream_kwargs(config: Mapping[str, Any]) -> Mapping[str, Any]: + authentication = config.get("authentication") + stream_kwargs = dict() + if authentication.get("auth_type") == "custom_connection": + stream_kwargs["authenticator"] = XeroCustomConnectionsOauth2Authenticator( + token_refresh_endpoint="https://identity.xero.com/connect/token", + client_secret=config.get("client_secret"), + client_id=config.get("client_id"), + scopes=config.get("scopes"), + ) + elif authentication.get("auth_type") == "oauth": + raise Exception("Config validation error. OAuth connection is not supported yet.") + + return stream_kwargs diff --git a/airbyte-integrations/connectors/source-xero/source_xero/spec.yaml b/airbyte-integrations/connectors/source-xero/source_xero/spec.yaml new file mode 100644 index 0000000000000..1eeab8b1e795d --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/spec.yaml @@ -0,0 +1,67 @@ +documentationUrl: https://docs.airbyte.io/integrations/sources/xero +connectionSpecification: + $schema: http://json-schema.org/draft-07/schema# + title: Xero Spec + type: object + required: + - authentication + - start_date + - scopes + - tenant_id + - client_id + - client_secret + additionalProperties: true + + properties: + client_id: + title: Client ID + type: string + description: "Enter your Xero application's Client ID" + client_secret: + title: Client Secret + type: string + description: "Enter your Xero application's Client Secret" + airbyte_secret: true + tenant_id: + title: Tenant ID + type: string + description: "Enter your Xero organization's Tenant ID" + scopes: + title: Scopes + type: string + description: "Enter your required list of scopes (delimited by comma)" + authentication: + type: object + title: Authentication + description: >- + Type and additional credentials of the Xero API connection + oneOf: + - title: Authenticate via Xero (OAuth) (unsupported yet) + type: object + required: + - auth_type + - refresh_token + properties: + auth_type: + type: string + const: oauth + refresh_token: + title: Refresh Token + type: string + description: "Enter your Xero application's refresh token" + airbyte_secret: true + - title: Custom Connections Authentication + type: object + required: + - auth_type + properties: + auth_type: + type: string + const: custom_connection + + start_date: + type: string + pattern: "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}Z$" + description: "UTC date and time in the format YYYY-MM-DDTHH:mm:ssZ. Any data with created_at before this data will not be synced." + examples: + - "2022-03-01T00:00:00Z" diff --git a/airbyte-integrations/connectors/source-xero/source_xero/streams.py b/airbyte-integrations/connectors/source-xero/source_xero/streams.py new file mode 100644 index 0000000000000..e092bda4479db --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/source_xero/streams.py @@ -0,0 +1,242 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + +import decimal +import re +from abc import ABC +from datetime import date, datetime, time, timedelta, timezone +from typing import Any, Iterable, Mapping, MutableMapping, Optional + +import pendulum +import requests +from airbyte_cdk.sources.streams.http import HttpStream + + +def parse_date(value): + # Xero datetimes can be .NET JSON date strings which look like + # "/Date(1419937200000+0000)/" + # https://developer.xero.com/documentation/api/requests-and-responses + pattern = r"Date\((\-?\d+)([-+])?(\d+)?\)" + match = re.search(pattern, value) + + iso8601pattern = r"((\d{4})-([0-2]\d)-0?([0-3]\d)T([0-5]\d):([0-5]\d):([0-6]\d))" + + if not match: + iso8601match = re.search(iso8601pattern, value) + if iso8601match: + try: + return datetime.strptime(value) + except Exception: + return None + else: + return None + + millis_timestamp, offset_sign, offset = match.groups() + if offset: + if offset_sign == "+": + offset_sign = 1 + else: + offset_sign = -1 + offset_hours = offset_sign * int(offset[:2]) + offset_minutes = offset_sign * int(offset[2:]) + else: + offset_hours = 0 + offset_minutes = 0 + + return datetime.fromtimestamp((int(millis_timestamp) / 1000), tz=timezone.utc) + timedelta(hours=offset_hours, minutes=offset_minutes) + + +def _json_load_object_hook(_dict): + """Hook for json.parse(...) to parse Xero date formats.""" + # This was taken from the pyxero library and modified + # to format the dates according to RFC3339 + for key, value in _dict.items(): + if isinstance(value, str): + value = parse_date(value) + if value: + if type(value) is date: + value = datetime.combine(value, time.min) + value = value.replace(tzinfo=timezone.utc) + _dict[key] = datetime.isoformat(value, timespec="seconds") + return _dict + + +class XeroStream(HttpStream, ABC): + url_base = "https://api.xero.com/api.xro/2.0/" + page_size = 100 + current_page = 1 + pagination = False + + def next_page_token(self, response: requests.Response) -> Optional[Mapping[str, Any]]: + records = response.json().get(self.data_field) or [] + if not self.pagination: + return None + if len(records) == self.page_size: + self.current_page += 1 + return {"has_next_page": True} + return None + + def request_params( + self, stream_state: Mapping[str, Any], stream_slice: Mapping[str, any] = None, next_page_token: Mapping[str, Any] = None + ) -> MutableMapping[str, Any]: + params = {} + if self.pagination: + params["page"] = self.current_page + return params + + def request_headers( + self, stream_state: Mapping[str, Any], stream_slice: Mapping[str, Any] = None, next_page_token: Mapping[str, Any] = None + ) -> Mapping[str, Any]: + headers = {"Accept": "application/json"} + return headers + + def parse_response(self, response: requests.Response, **kwargs) -> Iterable[Mapping]: + records = response.json(object_hook=_json_load_object_hook, parse_float=decimal.Decimal).get(self.data_field) or [] + for record in records: + record = record.get(self.data_field) or record + if self.primary_key in record and record[self.primary_key] is None: + record[self.primary_key] = 0 + yield record + + def path(self, **kwargs) -> str: + class_name = self.__class__.__name__ + return f"{class_name[0].lower()}{class_name[1:]}" + + @property + def data_field(self, **kwargs) -> str: + class_name = self.__class__.__name__ + re.sub(r"(? str: + return "UpdatedDateUTC" + + def request_headers( + self, stream_state: Mapping[str, Any], stream_slice: Mapping[str, Any] = None, next_page_token: Mapping[str, Any] = None + ) -> Mapping[str, Any]: + request_headers = super().request_headers(stream_state, stream_slice, next_page_token) + stream_date = stream_state.get("date") or self.start_date + if isinstance(stream_date, str): + stream_date = pendulum.parse(stream_date) + request_headers["If-Modified-Since"] = stream_date.strftime("%Y-%m-%dT%H:%M:%S") + + return request_headers + + def get_updated_state(self, current_stream_state: MutableMapping[str, Any], latest_record: Mapping[str, Any]) -> Mapping[str, Any]: + latest_state = latest_record.get(self.cursor_field) + current_state = current_stream_state.get(self.cursor_field) or latest_state + if current_state: + return {"date": max(latest_state, current_state)} + return {} + + +class BankTransactions(IncrementalXeroStream): + primary_key = "BankTransactionID" + pagination = True + + +class Contacts(IncrementalXeroStream): + primary_key = "ContactID" + pagination = True + + +class CreditNotes(IncrementalXeroStream): + primary_key = "CreditNoteID" + pagination = True + + +class Invoices(IncrementalXeroStream): + primary_key = "InvoiceID" + pagination = True + + +class ManualJournals(IncrementalXeroStream): + primary_key = "ManualJournalID" + pagination = True + + +class Overpayments(IncrementalXeroStream): + primary_key = "OverpaymentID" + pagination = True + + +class Prepayments(IncrementalXeroStream): + primary_key = "PrepaymentID" + pagination = True + + +class PurchaseOrders(IncrementalXeroStream): + primary_key = "PurchaseOrderID" + pagination = True + + +class Accounts(IncrementalXeroStream): + primary_key = "AccountID" + + +class BankTransfers(IncrementalXeroStream): + primary_key = "BankTransferID" + pagination = True + + @property + def cursor_field(self) -> str: + return "CreatedDateUTC" + + +class Employees(IncrementalXeroStream): + primary_key = "EmployeeID" + pagination = True + + +class Items(IncrementalXeroStream): + primary_key = "ItemID" + + +class Payments(IncrementalXeroStream): + primary_key = "PaymentID" + pagination = True + + +class Users(IncrementalXeroStream): + primary_key = "UserID" + + +class BrandingThemes(XeroStream): + primary_key = "BrandingThemeID" + + +class ContactGroups(XeroStream): + primary_key = "ContactGroupID" + + +class Currencies(XeroStream): + primary_key = "Code" + + +class Organisations(XeroStream): + primary_key = "OrganisationID" + + def path(self, **kwargs) -> str: + return "Organisation" + + +class RepeatingInvoices(XeroStream): + primary_key = "RepeatingInvoiceID" + + +class TaxRates(XeroStream): + primary_key = "Name" + + +class TrackingCategories(XeroStream): + primary_key = "TrackingCategoryID" diff --git a/airbyte-integrations/connectors/source-xero/unit_tests/__init__.py b/airbyte-integrations/connectors/source-xero/unit_tests/__init__.py new file mode 100644 index 0000000000000..1100c1c58cf51 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/unit_tests/__init__.py @@ -0,0 +1,3 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# diff --git a/airbyte-integrations/connectors/source-xero/unit_tests/conftest.py b/airbyte-integrations/connectors/source-xero/unit_tests/conftest.py new file mode 100644 index 0000000000000..ddcc4bad4d8f9 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/unit_tests/conftest.py @@ -0,0 +1,48 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + +from pytest import fixture + + +@fixture(name="config") +def config_fixture(): + return { + "client_id": "client_id", + "client_secret": "client_secret", + "tenant_id": "tenant_id", + "scopes": "scope1, scope2", + "authentication": {"auth_type": "custom_connection"}, + "start_date": "2020-01-01T00:00:00Z", + } + + +@fixture(name="mock_response") +def mock_response(): + return { + "data": [{"gid": "gid", "resource_type": "resource_type", "name": "name"}], + "next_page": {"offset": "offset", "path": "path", "uri": "uri"}, + } + + +@fixture(name="mock_stream") +def mock_stream_fixture(requests_mock): + def _mock_stream(path, response=None): + if response is None: + response = {} + + url = f"https://api.xero.com/api.xro/2.0/{path}" + requests_mock.get(url, json=response) + requests_mock.get("https://identity.xero.com/connect/token", json={}) + + return _mock_stream + + +@fixture(name="mock_auth") +def mock_auth_fixture(requests_mock): + def _mock_auth(response=None): + if response is None: + response = {} + requests_mock.post("https://identity.xero.com/connect/token", json=response) + + return _mock_auth diff --git a/airbyte-integrations/connectors/source-xero/unit_tests/test_incremental_streams.py b/airbyte-integrations/connectors/source-xero/unit_tests/test_incremental_streams.py new file mode 100644 index 0000000000000..adf8361290d18 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/unit_tests/test_incremental_streams.py @@ -0,0 +1,55 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + +import datetime + +from airbyte_cdk.models import SyncMode +from pytest import fixture +from source_xero.streams import IncrementalXeroStream + + +@fixture +def patch_incremental_base_class(mocker): + # Mock abstract methods to enable instantiating abstract class + mocker.patch.object(IncrementalXeroStream, "path", "v0/example_endpoint") + mocker.patch.object(IncrementalXeroStream, "primary_key", "test_primary_key") + mocker.patch.object(IncrementalXeroStream, "__abstractmethods__", set()) + + +def test_cursor_field(patch_incremental_base_class): + stream = IncrementalXeroStream(start_date=datetime.datetime.now()) + expected_cursor_field = "UpdatedDateUTC" + assert stream.cursor_field == expected_cursor_field + + +def test_get_updated_state(patch_incremental_base_class): + stream = IncrementalXeroStream(start_date=datetime.datetime.now()) + date = datetime.datetime.now().replace(microsecond=0) + inputs = {"current_stream_state": {"date": "2022-01-01"}, "latest_record": {"UpdatedDateUTC": date.isoformat()}} + expected_state = {"date": date.isoformat()} + assert stream.get_updated_state(**inputs) == expected_state + + +def test_stream_slices(patch_incremental_base_class): + stream = IncrementalXeroStream(start_date=datetime.datetime.now()) + inputs = {"sync_mode": SyncMode.incremental, "cursor_field": [], "stream_state": {}} + expected_stream_slice = [None] + assert stream.stream_slices(**inputs) == expected_stream_slice + + +def test_supports_incremental(patch_incremental_base_class, mocker): + mocker.patch.object(IncrementalXeroStream, "cursor_field", "dummy_field") + stream = IncrementalXeroStream(start_date=datetime.datetime.now()) + assert stream.supports_incremental + + +def test_source_defined_cursor(patch_incremental_base_class): + stream = IncrementalXeroStream(start_date=datetime.datetime.now()) + assert stream.source_defined_cursor + + +def test_stream_checkpoint_interval(patch_incremental_base_class): + stream = IncrementalXeroStream(start_date=datetime.datetime.now()) + expected_checkpoint_interval = 100 + assert stream.state_checkpoint_interval == expected_checkpoint_interval diff --git a/airbyte-integrations/connectors/source-xero/unit_tests/test_source.py b/airbyte-integrations/connectors/source-xero/unit_tests/test_source.py new file mode 100644 index 0000000000000..1601871e7b9c1 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/unit_tests/test_source.py @@ -0,0 +1,22 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + +from unittest.mock import MagicMock + +from source_xero.source import SourceXero + + +def test_check_connection(mock_auth, mock_stream, mock_response, config): + mock_stream("Organisation", response={"Organisations": [{"OrganisationID": "tenant_id"}]}) + mock_auth({"access_token": "TOKEN", "expires_in": 123}) + source = SourceXero() + logger_mock, config_mock = MagicMock(), config + assert source.check_connection(logger_mock, config_mock) == (True, None) + + +def test_streams(config): + source = SourceXero() + streams = source.streams(config) + expected_streams_number = 21 + assert len(streams) == expected_streams_number diff --git a/airbyte-integrations/connectors/source-xero/unit_tests/test_streams.py b/airbyte-integrations/connectors/source-xero/unit_tests/test_streams.py new file mode 100644 index 0000000000000..936bc53efeaa4 --- /dev/null +++ b/airbyte-integrations/connectors/source-xero/unit_tests/test_streams.py @@ -0,0 +1,95 @@ +# +# Copyright (c) 2022 Airbyte, Inc., all rights reserved. +# + +import datetime +from http import HTTPStatus +from unittest.mock import MagicMock + +import pytest +from source_xero.streams import XeroStream, parse_date + + +@pytest.fixture +def patch_base_class(mocker): + mocker.patch.object(XeroStream, "path", "v0/example_endpoint") + mocker.patch.object(XeroStream, "primary_key", "test_primary_key") + mocker.patch.object(XeroStream, "__abstractmethods__", set()) + + +def test_request_params(patch_base_class): + stream = XeroStream() + inputs = {"stream_slice": None, "stream_state": None, "next_page_token": None} + expected_params = {} + assert stream.request_params(**inputs) == expected_params + + +def test_next_page_token(patch_base_class): + stream = XeroStream() + inputs = {"response": MagicMock()} + expected_token = None + assert stream.next_page_token(**inputs) == expected_token + + stream.page_size = 1 + stream.pagination = True + response = MagicMock() + response.json.return_value = {"XeroStream": [{}]} + inputs = {"response": response} + expected_token = {"has_next_page": True} + assert stream.next_page_token(**inputs) == expected_token + + +def test_parse_response(patch_base_class): + stream = XeroStream() + response = MagicMock() + response.json.return_value = {"XeroStream": [{"key": "value"}]} + inputs = {"response": response} + expected_parsed_object = {"key": "value"} + assert next(stream.parse_response(**inputs)) == expected_parsed_object + + +def test_request_headers(patch_base_class): + stream = XeroStream() + inputs = {"stream_slice": None, "stream_state": None, "next_page_token": None} + expected_headers = {"Accept": "application/json"} + assert stream.request_headers(**inputs) == expected_headers + + +def test_http_method(patch_base_class): + stream = XeroStream() + expected_method = "GET" + assert stream.http_method == expected_method + + +@pytest.mark.parametrize( + ("http_status", "should_retry"), + [ + (HTTPStatus.OK, False), + (HTTPStatus.BAD_REQUEST, False), + (HTTPStatus.TOO_MANY_REQUESTS, True), + (HTTPStatus.INTERNAL_SERVER_ERROR, True), + ], +) +def test_should_retry(patch_base_class, http_status, should_retry): + response_mock = MagicMock() + response_mock.status_code = http_status + stream = XeroStream() + assert stream.should_retry(response_mock) == should_retry + + +def test_backoff_time(patch_base_class): + response_mock = MagicMock() + stream = XeroStream() + expected_backoff_time = None + assert stream.backoff_time(response_mock) == expected_backoff_time + + +def test_parse_date(): + # 11/10/2020 00:00:00 +3 (11/10/2020 21:00:00 GMT/UTC) + assert parse_date("/Date(1602363600000+0300)/") == datetime.datetime(2020, 10, 11, 0, 0, tzinfo=datetime.timezone.utc) + # 02/02/2020 10:31:51.5 +3 (02/02/2020 07:31:51.5 GMT/UTC) + assert parse_date("/Date(1580628711500+0300)/") == datetime.datetime(2020, 2, 2, 10, 31, 51, 500000, tzinfo=datetime.timezone.utc) + # 07/02/2022 20:12:55 GMT/UTC + assert parse_date("/Date(1656792775000)/") == datetime.datetime(2022, 7, 2, 20, 12, 55, tzinfo=datetime.timezone.utc) + # Not a date + assert parse_date("not a date") is None diff --git a/docs/integrations/sources/xero.md b/docs/integrations/sources/xero.md new file mode 100644 index 0000000000000..1aeb70d9f3cfa --- /dev/null +++ b/docs/integrations/sources/xero.md @@ -0,0 +1,58 @@ +# Airbyte Source Connector for Xero + +This is a setup guide for the Xero source connector which ingests data from the Accounting API. + +## Prerequisites + +First of all you should create an application in [Xero development center](https://developer.xero.com/app/manage/). The only supported integration type is to use [Xero Custom Connections](https://developer.xero.com/documentation/guides/oauth2/custom-connections/developer) so you should choose it on creating your Xero App. +After creating an application, on configuration screen, authorize user for your Xero Organisation. Also, issue new Client Secret and remember it - it will be required for setting up Xero connector in your Airbyte instance. + +## Supported streams + +[Accounts](https://developer.xero.com/documentation/api/accounting/accounts) +[BankTransactions](https://developer.xero.com/documentation/api/accounting/banktransactions) +[BankTransfers](https://developer.xero.com/documentation/api/accounting/banktransfers) +[BrandingThemes](https://developer.xero.com/documentation/api/accounting/brandingthemes) +[ContactGroups](https://developer.xero.com/documentation/api/accounting/contactgroups) +[Contacts](https://developer.xero.com/documentation/api/accounting/contacts) +[CreditNotes](https://developer.xero.com/documentation/api/accounting/creditnotes) +[Currencies](https://developer.xero.com/documentation/api/accounting/currencies) +[Employees](https://developer.xero.com/documentation/api/accounting/employees) +[Invoices](https://developer.xero.com/documentation/api/accounting/invoices) +[Items](https://developer.xero.com/documentation/api/accounting/items) +[ManualJournals](https://developer.xero.com/documentation/api/accounting/manualjournals) +[Organisation](https://developer.xero.com/documentation/api/accounting/organisation) +[Overpayments](https://developer.xero.com/documentation/api/accounting/overpayments) +[Payments](https://developer.xero.com/documentation/api/accounting/payments) +[Prepayments](https://developer.xero.com/documentation/api/accounting/prepayments) +[PurchaseOrders](https://developer.xero.com/documentation/api/accounting/purchaseorders) +[RepeatingInvoices](https://developer.xero.com/documentation/api/accounting/repeatinginvoices) +[TaxRates](https://developer.xero.com/documentation/api/accounting/taxrates) +[TrackingCategories](https://developer.xero.com/documentation/api/accounting/trackingcategories) +[Users](https://developer.xero.com/documentation/api/accounting/users) + +### Dates transformation + +As Xero uses .NET, some date fields in records could be in [.NET JSON date format](https://developer.xero.com/documentation/api/accounting/requests-and-responses). These dates are transformed into ISO 8601. + +## Set up the Xero source connector + +1. Click **Sources** and then click **+ New source**. +2. On the Set up the source page, select **Xerp** from the Source type dropdown. +3. Enter a name for your new source. +4. For **Client ID**, enter Client ID of your Xero App. +5. For **Client Secret**, enter a Client Secret created on "Configuration" screen of your Xero App +6. For **Tenant ID** field, enter your Xero Organisation's [Tenant ID](https://developer.xero.com/documentation/guides/oauth2/auth-flow/#xero-tenants) +7. For **Scopes** field enter scopes you used for user's authorization on "Configuration" screen of your Xero App +8. Choose **Custom Connections Authentication** as **Authentication** option +9. For **Start date** enter UTC date and time in the format YYYY-MM-DDTHH:mm:ssZ as the start date and time of ingestion. +10. Click **Set up source**. + +## Supported sync modes + +The source connector supports the following [sync modes](https://docs.airbyte.com/cloud/core-concepts#connection-sync-modes): + +- Full Refresh +- Incremental + +## Changelog \ No newline at end of file