Xero Connector
Description
Xero is a cloud-based accounting software platform for small and medium-sized businesses. This component allows you to manage invoices, payments, items, and contacts through the Xero REST API.
API Documentation
This component was built using the Xero Accounting API.
Connections
OAuth 2.0
key: oauth2Xero uses OAuth 2.0 to authorize requests made to the API. This connection uses the OAuth 2.0 Authorization Code grant type so that the integration can authenticate with a customer's Xero account.
Prerequisites
- A Xero account with access to the developer portal
Setup Steps
- Log on to Xero's developer portal.
- Click New app.
- Give the app a name.
- Select Web app for Integration type.
- Enter the company's URL for Company or application URL.
- Enter
https://oauth2.prismatic.io/callbackfor the Redirect URI.
- Open the Configuration page.
- Click Generate Secret and take note of the Client id and Client secret.
Configure the Connection
When a Xero step is added to an integration, a Xero OAuth 2.0 connection config variable is created automatically.
- For Scopes, enter the scopes from this list that are relevant to the integration.
Always include the
offline_accessscope so that authentication tokens refresh automatically. - For Client ID and Client Secret, enter the values noted above.
- A single customer might be logged in to multiple tenants, and Tenant Name is unique for each customer. Leave that input blank, and click the gear icon next to Tenant Name. Adjust Input Visibility and select Customer to make that input visible to customers. That way, customers are prompted for their tenant name when they enable this integration.
For additional information regarding authentication, refer to the Xero docs.
| Input | Notes | Example |
|---|---|---|
| Authorize URL | The OAuth 2.0 Authorization URL for Xero | https://login.xero.com/identity/connect/authorize |
| Client ID | Provide the Client Id you received from the Xero Developer Console. | |
| Client Secret | Provide the Client Secret you generated from the Xero Developer Console. | |
| Scopes | A space-delimited set of one or more scopes to get the user's permission to access. You must specify 'offline_access' to enable automatic token refresh. | accounting.contacts |
| Tenant Name | The name of the tenant you are requesting access to. | Acme Inc. |
| Token URL | The OAuth 2.0 Token URL for Xero | https://identity.xero.com/connect/token |
OAuth 2.0 Client Credentials
key: xeroOAuthClientCredentialsXero uses OAuth 2.0 to authorize requests made to the API. This connection uses the client credentials grant type to access data from a single Xero organization using Custom Connections.
Custom Connections are a premium integration option that utilize the client credentials grant type to access data from a single Xero organization.
Setup Steps
-
Create the Custom Connection.
- Log in to My Apps and click New App.
- Give the integration a name and select Custom connection as the integration type.
-
Select scopes and the authorizing user.
- Select the API scopes the integration will need and who will authorize the connection.
- That user is then emailed a link that takes them to the authorization step.
- Once authorization is complete, an email confirms the connection has been authorized.
-
Authorize the connection.
- After clicking the Connect button in the email, the authorizing user is taken to a consent screen where they can see which scopes are being requested and select the organization to connect.
- Note that an organization needs to have purchased a subscription with sufficient Custom Connections to be authorized and connected.
- The only exception is the Xero Demo Company, which can be used for free for development purposes.
-
Retrieve the client id and client secret.
- Once the custom connection has been authorized, the client id is available on the app details page and the client secret can be generated.
Configure the Connection
- For Scopes, enter the scopes relevant to the integration, separated by spaces. Do not include
offline_access, as this is a client credentials flow. - For Client ID and Client Secret, enter the values retrieved from the app details page.
For more information, refer to the Custom Connections documentation.
| Input | Notes | Example |
|---|---|---|
| Client ID | Provide the Client Id you received from the Xero Developer Console. | |
| Client Secret | Provide the Client Secret you generated from the Xero Developer Console. | |
| Scopes | A space-delimited set of one or more scopes to get the user's permission to access. Don't specify 'offline_access' as this is a client credentials flow. | accounting.contacts |
| Token URL | The OAuth 2.0 Token URL for Xero | https://identity.xero.com/connect/token |
Triggers
New and Updated Records
Checks for new and updated records in Xero on a configured schedule. | key: pollChangesTrigger
| Input | Notes | Example |
|---|---|---|
| Resource Type | The type of Xero resource to poll for new and updated records. | |
| Show New Records | Include newly created records in trigger results. | true |
| Show Updated Records | Include updated records in trigger results. | true |
| Connection | The Xero connection to use. |
This trigger polls the Xero Accounting API for new and updated records of a selected resource type on a scheduled basis.
How It Works
- The trigger runs on the configured schedule
- It fetches records modified since the last poll using Xero's
If-Modified-Sinceheader, limiting results to records that have changed - Each returned record is compared against the set of previously known IDs. Records with unknown IDs are classified as new, and records with known IDs are classified as updated
- The trigger updates its internal state after each poll, storing the last poll timestamp and the full set of known record IDs
The following resource types are supported:
Supported Resource Types (9)
| Resource | Paginated | Tracks New | Tracks Updated |
|---|---|---|---|
| Accounts | No | Yes | Yes |
| Bank Transactions | Yes | Yes | Yes |
| Contacts | Yes | Yes | Yes |
| Credit Notes | Yes | Yes | Yes |
| Invoices | Yes | Yes | Yes |
| Items | No | Yes | Yes |
| Manual Journals | Yes | Yes | Yes |
| Payments | Yes | Yes | Yes |
| Purchase Orders | Yes | Yes | Yes |
Returned Data
Returns an object with two arrays: created for new records and updated for modified records.
Example Response
{
"data": {
"created": [
{
"ContactID": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"Name": "Acme Corp",
"UpdatedDateUTC": "/Date(1699610400000+0000)/"
}
],
"updated": [
{
"ContactID": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
"Name": "Global Industries",
"UpdatedDateUTC": "/Date(1699696800000+0000)/"
}
]
}
}
Fields shown are representative. The full response object includes additional properties.
Notes
- Classification as new or updated is based on ID history, not Xero metadata. A record whose ID has not been seen in a prior poll is classified as created, while a record whose ID is already known is classified as updated.
- The known ID set and the last poll timestamp both persist across executions via polling state.
- Paginated resource types fetch all pages before classifying records.
Example Payload for New and Updated Records⤓
Webhook
Receive and validate webhook requests from Xero for manually configured webhook subscriptions. | key: webhook
| Input | Notes | Example |
|---|---|---|
| Webhook Key | The webhook signing key created when the subscription was set up. | up/tz7l0Q9FM6Wyq3Rli0bqJrfqmtl4idswda/LQ== |
Example Payload for Webhook⤓
Data Sources
Select Account
Select an account from the list. | key: selectAccount | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | The Xero connection to use. |
Select Contact
Select a contact from the list. | key: selectContact | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | The Xero connection to use. |
Select Invoice
Select an invoice from the list. | key: selectInvoice | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | The Xero connection to use. |
Select Item
Select an item from the list. | key: selectItem | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | The Xero connection to use. |
Select Payment
Select a payment from the list. | key: selectPayment | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | The Xero connection to use. |
Actions
Add Note to Invoice
Add additional notes to an invoice by ID. | key: addNoteToInvoice
| Input | Notes | Example |
|---|---|---|
| Invoice ID | The unique identifier for the invoice. | example-e40f-414a-8f95-ce6a63196e1a |
| Notes | The note text to add to the object's history. | These are example notes. |
| Connection | The Xero connection to use. |
Example Payload for Add Note to Invoice⤓
Add Note to Item
Add a note to an item's history by ID. | key: addNoteToItem
| Input | Notes | Example |
|---|---|---|
| Item ID | The unique identifier for the item. | example-e40f-414a-8f95-ce6a63196e1a |
| Notes | The note text to add to the object's history. | These are example notes. |
| Connection | The Xero connection to use. |
Example Payload for Add Note to Item⤓
Archive Account
Archive an account by ID. | key: archiveAccount
| Input | Notes | Example |
|---|---|---|
| Account ID | The unique identifier for the account. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Archive Account⤓
Archive Contact
Archive a contact by ID. | key: archiveContact
| Input | Notes | Example |
|---|---|---|
| Contact ID | The unique identifier for the contact. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Archive Contact⤓
Create Account
Create a new account. | key: createAccount
| Input | Notes | Example |
|---|---|---|
| Account Code | A customer-defined alphanumeric code that identifies the account. | 200 |
| Account Name | The display name shown for the account. | Example Account |
| Account Type | The category of the account. Choose a value from the Xero account types. | BANK |
| Bank Account Number | The bank account number. Required when the account type is BANK. | 121-121-1234567 |
| Optional Values | For each item, provide a key and value to be used in the request body. | exampleValue |
| Show In Expense Claims | When true, the account appears in expense claims. Required for certain account types. | false |
| Connection | The Xero connection to use. |
Xero has support for many different types of accounts. Creating certain accounts may require additional fields. These fields can be provided with the 'Optional Values' input. For a list of the required values for each type of account, refer to the documentation provided by Xero.
Example Payload for Create Account⤓
Create Attachment
Add an attachment to an existing object. Existing attachments with that file name will be overridden. | key: createAttachment
| Input | Notes | Example |
|---|---|---|
| Content Type | The MIME type of the file to upload. | image/png |
| File Data | The binary contents of the file to upload. | |
| File Name | The name of the file to attach. This becomes the unique identifier of the file for update operations. | My Example File |
| Object ID | The unique identifier for the object to attach the file to. | example-e40f-414a-8f95-ce6a63196e1a |
| Object Type | The type of object to attach the file to. | |
| Connection | The Xero connection to use. |
Create Contact
Create a new contact. | key: createContact
| Input | Notes | Example |
|---|---|---|
| Accounts Payable Tax Type | The default tax type applied to bills for the contact. See the Xero tax types for accepted values. | OUTPUT |
| Accounts Receivable Tax Type | The default tax type applied to sales invoices for the contact. See the Xero tax types for accepted values. | OUTPUT |
| Additional Fields | Additional fields that might not be covered by the standard inputs. See Xero API documentation for additional fields. | |
| Address | The street address of the contact. | 4 Privet Drive |
| Address Type | The kind of address being provided. | POBOX |
| Bank Account Details | The bank account number for the contact. Depending on the account type, providing a value here could cause the request to fail. See the Xero accounts documentation for the expected shape. | 01-0123-example-00 |
| City | The city portion of the contact's address. | San Francisco |
| Contact Name | The full name or business name of the contact. | Acme Inc. |
| Contact Status | The status to assign to the contact. | |
| Country | The country portion of the contact's address. | United States |
| Default Currency | The default currency code used for the contact. | USD |
| Email Address | The email address used to reach the contact. | someone@example.com |
| First Name | The given name of the contact. | John |
| Last Name | The family name of the contact. | Doe |
| Postal Code | The postal or ZIP code of the contact's address. | 48423 |
| Region | The state or region portion of the contact's address. | California |
| Tax Number | The tax number of the contact. See the Xero tax types for accepted values. | 12-345-678 |
| Connection | The Xero connection to use. |
Example Payload for Create Contact⤓
Create Invoice
Create a new invoice. | key: createInvoice
| Input | Notes | Example |
|---|---|---|
| Additional Fields | Additional fields that might not be covered by the standard inputs. See Xero API documentation for additional fields. | |
| Contact ID | The unique identifier for the contact. | example-e40f-414a-8f95-ce6a63196e1a |
| Currency Code | The currency the invoice has been raised in. | USD |
| Date | The date the invoice was issued. Defaults to the current date based on the organization's timezone setting if not specified. Format: YYYY-MM-DD. | 2024-10-01 |
| Date String | The date the record was created. Format: YYYY-MM-DDTHH:MM:SS. | 2021-05-27T00:00:00 |
| Due Date | The date the invoice is due. Format: YYYY-MM-DD. | 2024-10-01 |
| Due Date String | The due date of the invoice as a string. Format: YYYY-MM-DDTHH:MM:SS. | 2021-05-27T00:00:00 |
| Invoice Number | A unique number that identifies the invoice. | INV01 |
| Invoice Status | The status of the invoice. Required to make payments on an invoice. Defaults to DRAFT. | |
| Invoice Type | The type of invoice to create. | |
| Line Amount Type | Whether line amounts are tax exclusive, inclusive, or have no tax. | |
| Line Items | A JSON array where each object describes a line item. The 'ItemCode', 'Tracking', and 'DiscountRate' properties are optional. Use an empty array for no line items. | |
| Reference | An additional reference number for the invoice (Accounts Receivable invoices only). | REF01 |
| Sent To Contact | When true, marks the invoice in the Xero app as "sent". This can only be set on invoices that have been approved. | false |
| URL | The URL of a source document, shown as "Go to [appName]" in the Xero app. | https://example.com |
| Connection | The Xero connection to use. |
Example Payload for Create Invoice⤓
Create Item
Create a new item. | key: createItem
| Input | Notes | Example |
|---|---|---|
| Description | A summary that describes the item. | This is an example description |
| Inventory Asset Account Code | The account code used to track the inventory asset. | 200 |
| Is Purchased | When true, the item is available to purchase. | false |
| Is Sold | When true, the item is available to sell. | false |
| Item Code | A user-defined code that identifies the item. | Untracked Item |
| Item Name | The display name of the item. | Example Name |
| Purchase Account Code | The account code used for purchases of the item. | 200 |
| Purchase Description | A summary shown on purchase transactions for the item. | This is an example description |
| Purchase Tax Type | The tax type applied to purchases. Choose a value from the Xero tax types. | NONE |
| Purchase Unit Price | The unit price applied when the item is purchased. | 800 |
| Sales Account Code | The account code used for sales of the item. | 200 |
| Sales Tax Type | The tax type applied to sales of the item. Choose a value from the Xero tax types. | NONE |
| Sales Unit Price | The unit price applied when the item is sold. | 50.69 |
| Connection | The Xero connection to use. |
Example Payload for Create Item⤓
Delete Account
Delete an account by ID. | key: deleteAccount
| Input | Notes | Example |
|---|---|---|
| Account ID | The unique identifier for the account. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Delete Account⤓
Delete Invoice
Delete an invoice by ID. | key: deleteInvoice
| Input | Notes | Example |
|---|---|---|
| Invoice ID | The unique identifier for the invoice. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Delete Invoice⤓
Delete Item
Delete an item by ID. | key: deleteItem
| Input | Notes | Example |
|---|---|---|
| Item ID | The unique identifier for the item. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Delete Item⤓
Get Account
Retrieve the information and metadata of an account by ID. | key: getAccount
| Input | Notes | Example |
|---|---|---|
| Account ID | The unique identifier for the account. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Get Account⤓
Get Attachment
Retrieve an attachment by ID. | key: getAttachment
| Input | Notes | Example |
|---|---|---|
| File Name | The name of the file to attach. This becomes the unique identifier of the file for update operations. | My Example File |
| Object ID | The unique identifier for the object to attach the file to. | example-e40f-414a-8f95-ce6a63196e1a |
| Object Type | The type of object to attach the file to. | |
| Connection | The Xero connection to use. |
Get Contact
Retrieve the information and metadata of a contact by ID. | key: getContact
| Input | Notes | Example |
|---|---|---|
| Contact ID | The unique identifier for the contact. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Get Contact⤓
Get Contact History
Retrieve the information and metadata of a contact's history by ID. | key: getContactHistory
| Input | Notes | Example |
|---|---|---|
| Contact ID | The unique identifier for the contact. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Get Contact History⤓
Get Invoice
Retrieve the information and metadata of an invoice by ID. | key: getInvoice
| Input | Notes | Example |
|---|---|---|
| Invoice ID | The unique identifier for the invoice. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Get Invoice⤓
Get Item
Retrieve the information and metadata of an item by ID. | key: getItem
| Input | Notes | Example |
|---|---|---|
| Item ID | The unique identifier for the item. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Get Item⤓
Get Item History
Retrieve the information and metadata of an item's history by ID. | key: getItemHistory
| Input | Notes | Example |
|---|---|---|
| Item ID | The unique identifier for the item. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Get Item History⤓
Get Payment
Retrieve the information and metadata of a payment by ID. | key: getPayment
| Input | Notes | Example |
|---|---|---|
| Payment ID | The unique identifier for the payment. | |
| Connection | The Xero connection to use. |
Example Payload for Get Payment⤓
Get Payment History
Retrieve the information and metadata of a payment's history by ID. | key: getPaymentHistory
| Input | Notes | Example |
|---|---|---|
| Payment ID | The unique identifier for the payment. | |
| Connection | The Xero connection to use. |
Example Payload for Get Payment History⤓
List Accounts
List all accounts. | key: listAccounts
| Input | Notes | Example |
|---|---|---|
| Modified After | Only records created or modified since this timestamp will be returned. Format: YYYY-MM-DDTHH:MM:SS. | 2021-05-27T00:00:00 |
| Where | A filter expression applied to endpoints and elements that don't have explicit parameters. | Name.Contains("Peter") |
| Connection | The Xero connection to use. |
Example Payload for List Accounts⤓
List Connections
List all connections. | key: listConnections
| Input | Notes | Example |
|---|---|---|
| Connection | The Xero connection to use. |
Example Payload for List Connections⤓
List Contacts
List all contacts. | key: listContacts
| Input | Notes | Example |
|---|---|---|
| Fetch All | When true, automatically fetches all pages of results. This ignores the page number input. | false |
| Modified After | Only records created or modified since this timestamp will be returned. Format: YYYY-MM-DDTHH:MM:SS. | 2021-05-27T00:00:00 |
| Page Number | The page of results to return (1-based). Pagination is only enabled when more than 100 elements are returned by the request. The page size cannot be specified. | 3 |
| Where | A filter expression applied to endpoints and elements that don't have explicit parameters. | Name.Contains("Peter") |
| Connection | The Xero connection to use. |
Example Payload for List Contacts⤓
List Invoices
List all invoices. | key: listInvoices
| Input | Notes | Example |
|---|---|---|
| Fetch All | When true, automatically fetches all pages of results. This ignores the page number input. | false |
| Modified After | Only records created or modified since this timestamp will be returned. Format: YYYY-MM-DDTHH:MM:SS. | 2021-05-27T00:00:00 |
| Page Number | The page of results to return (1-based). Pagination is only enabled when more than 100 elements are returned by the request. The page size cannot be specified. | 3 |
| Where | A filter expression applied to endpoints and elements that don't have explicit parameters. | Name.Contains("Peter") |
| Connection | The Xero connection to use. |
Example Payload for List Invoices⤓
List Items
List all items. | key: listItems
| Input | Notes | Example |
|---|---|---|
| Modified After | Only records created or modified since this timestamp will be returned. Format: YYYY-MM-DDTHH:MM:SS. | 2021-05-27T00:00:00 |
| Where | A filter expression applied to endpoints and elements that don't have explicit parameters. | Name.Contains("Peter") |
| Connection | The Xero connection to use. |
Example Payload for List Items⤓
List Payments
List all payments. | key: listPayments
| Input | Notes | Example |
|---|---|---|
| Fetch All | When true, automatically fetches all pages of results. This ignores the page number input. | false |
| Modified After | Only records created or modified since this timestamp will be returned. Format: YYYY-MM-DDTHH:MM:SS. | 2021-05-27T00:00:00 |
| Page Number | The page of results to return (1-based). Pagination is only enabled when more than 100 elements are returned by the request. The page size cannot be specified. | 3 |
| Where | A filter expression applied to endpoints and elements that don't have explicit parameters. | Name.Contains("Peter") |
| Connection | The Xero connection to use. |
Example Payload for List Payments⤓
Pay Invoice
Create a new payment on an existing AP/AR invoice. | key: payInvoice
| Input | Notes | Example |
|---|---|---|
| Account ID | The unique identifier for the account. | example-e40f-414a-8f95-ce6a63196e1a |
| Date String | The date the record was created. Format: YYYY-MM-DDTHH:MM:SS. | 2021-05-27T00:00:00 |
| Invoice ID | The unique identifier for the invoice. | example-e40f-414a-8f95-ce6a63196e1a |
| Payment Amount | The amount of the payment. Must be less than or equal to the outstanding amount owed on the invoice. | |
| Connection | The Xero connection to use. |
Example Payload for Pay Invoice⤓
Raw Request
Send a raw HTTP request to Xero. | key: rawRequest
| Input | Notes | Example |
|---|---|---|
| Connection | The Xero connection to use. | |
| Data | The HTTP body payload to send to the URL. | {"exampleKey": "Example Data"} |
| File Data | File Data to be sent as a multipart form upload. | [{key: "example.txt", value: "My File Contents"}] |
| File Data File Names | File names to apply to the file data inputs. Keys must match the file data keys above. | |
| Form Data | The Form Data to be sent as a multipart form upload. | [{"key": "Example Key", "value": new Buffer("Hello World")}] |
| Header | A list of headers to send with the request. | User-Agent: curl/7.64.1 |
| Max Retry Count | The maximum number of retries to attempt. Specify 0 for no retries. | 0 |
| Method | The HTTP method to use. | |
| Query Parameter | A list of query parameters to send with the request. This is the portion at the end of the URL similar to ?key1=value1&key2=value2. | |
| Response Type | The type of data you expect in the response. You can request json, text, or binary data. | json |
| Retry On All Errors | If true, retries on all erroneous responses regardless of type. This is helpful when retrying after HTTP 429 or other 3xx or 4xx errors. Otherwise, only retries on HTTP 5xx and network errors. | false |
| Retry Delay (ms) | The delay in milliseconds between retries. This is used when 'Use Exponential Backoff' is disabled. | 0 |
| Timeout | The maximum time that a client will await a response to its request | 2000 |
| URL | Input the path only (/Accounts), The base URL is already included (https://api.xero.com/api.xro/2.0). For example, to connect to https://api.xero.com/api.xro/2.0/Accounts, only /Accounts is entered in this field. | /Accounts |
| Use Exponential Backoff | Specifies whether to use a pre-defined exponential backoff strategy for retries. When enabled, 'Retry Delay (ms)' is ignored. | false |
Reverse Payment
Reverse a payment by ID. | key: reversePayment
| Input | Notes | Example |
|---|---|---|
| Payment ID | The unique identifier for the payment. | |
| Connection | The Xero connection to use. |
Example Payload for Reverse Payment⤓
Send Invoice
Send an existing accounts receivable invoice through email. | key: sendInvoice
| Input | Notes | Example |
|---|---|---|
| Invoice ID | The unique identifier for the invoice. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
The Send Invoice action triggers the email of a sales invoice out of Xero.
The invoice must be of type ACCREC and a valid status for sending (SUBMITTED, AUTHORIZED or PAID).
The email will be sent to the primary email address of the contact on the invoice and any additional contact persons that have IncludeInEmails flag set to true.
The sender will be the user who authorized the app connection.
Example Payload for Send Invoice⤓
Update Account
Update the information and metadata of an existing account by ID. | key: updateAccount
| Input | Notes | Example |
|---|---|---|
| Account Code | A customer-defined alphanumeric code that identifies the account. | 200 |
| Account ID | The unique identifier for the account. | example-e40f-414a-8f95-ce6a63196e1a |
| Account Name | The display name shown for the account. | Example Account |
| Account Type | The category of the account. Choose a value from the Xero account types. | BANK |
| Description | A summary that describes the item. | This is an example description |
| Enable Payments To Account | When true, allows payments to be made to the account. | false |
| Optional Values | For each item, provide a key and value to be used in the request body. | exampleValue |
| Purchase Tax Type | The tax type applied to purchases. Choose a value from the Xero tax types. | NONE |
| Show In Expense Claims | When true, the account appears in expense claims. Required for certain account types. | false |
| Connection | The Xero connection to use. |
Example Payload for Update Account⤓
Update Contact
Update the information and metadata of a contact by ID. | key: updateContact
| Input | Notes | Example |
|---|---|---|
| Accounts Payable Tax Type | The default tax type applied to bills for the contact. See the Xero tax types for accepted values. | OUTPUT |
| Accounts Receivable Tax Type | The default tax type applied to sales invoices for the contact. See the Xero tax types for accepted values. | OUTPUT |
| Additional Fields | Additional fields that might not be covered by the standard inputs. See Xero API documentation for additional fields. | |
| Address | The street address of the contact. | 4 Privet Drive |
| Address Type | The kind of address being provided. | POBOX |
| Bank Account Details | The bank account number for the contact. Depending on the account type, providing a value here could cause the request to fail. See the Xero accounts documentation for the expected shape. | 01-0123-example-00 |
| City | The city portion of the contact's address. | San Francisco |
| Contact ID | The unique identifier for the contact. | example-e40f-414a-8f95-ce6a63196e1a |
| Contact Name | The full name or business name of the contact. | Acme Inc. |
| Contact Number | A unique number that identifies the contact. | IDexample01 |
| Contact Status | The status to assign to the contact. | |
| Country | The country portion of the contact's address. | United States |
| Default Currency | The default currency code used for the contact. | USD |
| Email Address | The email address used to reach the contact. | someone@example.com |
| First Name | The given name of the contact. | John |
| Last Name | The family name of the contact. | Doe |
| Postal Code | The postal or ZIP code of the contact's address. | 48423 |
| Region | The state or region portion of the contact's address. | California |
| Tax Number | The tax number of the contact. See the Xero tax types for accepted values. | 12-345-678 |
| Connection | The Xero connection to use. |
Example Payload for Update Contact⤓
Update Item
Update the information and metadata of an item by ID. | key: updateItem
| Input | Notes | Example |
|---|---|---|
| Description | A summary that describes the item. | This is an example description |
| Optional Values | For each item, provide a key and value to be used in the request body. | exampleValue |
| Inventory Asset Account Code | The account code used to track the inventory asset. | 200 |
| Is Purchased | When true, the item is available to purchase. | false |
| Is Sold | When true, the item is available to sell. | false |
| Item Code | A user-defined code that identifies the item. | Untracked Item |
| Item ID | The unique identifier for the item. | example-e40f-414a-8f95-ce6a63196e1a |
| Item Name | The display name of the item. | Example Name |
| Purchase Account Code | The account code used for purchases of the item. | 200 |
| Purchase Description | A summary shown on purchase transactions for the item. | This is an example description |
| Purchase Tax Type | The tax type applied to purchases. Choose a value from the Xero tax types. | NONE |
| Purchase Unit Price | The unit price applied when the item is purchased. | 800 |
| Sales Account Code | The account code used for sales of the item. | 200 |
| Sales Tax Type | The tax type applied to sales of the item. Choose a value from the Xero tax types. | NONE |
| Sales Unit Price | The unit price applied when the item is sold. | 50.69 |
| Connection | The Xero connection to use. |
Example Payload for Update Item⤓
Void Invoice
Void an existing approved invoice that has no payments applied to it. | key: voidInvoice
| Input | Notes | Example |
|---|---|---|
| Invoice ID | The unique identifier for the invoice. | example-e40f-414a-8f95-ce6a63196e1a |
| Connection | The Xero connection to use. |
Example Payload for Void Invoice⤓
Changelog
2026-06-29
Various modernizations and documentation updates
2026-05-20
Applied automated security patches and code formatting updates
2026-05-08
Updated webhook trigger to return 401 instead of throwing on invalid signature, restoring Xero's intent-to-receive validation handshake
2026-04-30
Updated spectral version
2026-04-21
Added New and Updated Records polling trigger that checks for new and updated invoices, contacts, bank transactions, and other accounting records in Xero on a configured schedule
2026-04-10
Updated example payloads
2026-03-31
Various modernizations and documentation updates
2026-03-16
Improved input field documentation with formatted URL links for better readability
2025-11-19
Enhanced webhook triggers to support simulated test executions
2025-09-11
Added improved error handling for invalid webhook signatures to enhance security
2025-07-03
Added data sources and inline data sources for improved integration with Xero accounting platform