Xero integration

Cloud accounting: Invoices, Contacts, Credit Notes, Quotes, Purchase Orders, Reports, Payments

Help CentreConnectors

Overview

Xero is a cloud accounting platform popular with SMBs in AU/NZ/UK/SA. The Automize Xero connector covers the core accounting flows – invoices, contacts, payments, credit notes, quotes, items, accounts, journals, and bank transactions.

  • Regions: Xero is a single global platform, but data is regionalised by the Organisation's country (AU, NZ, UK, US, SA, etc.). The connector talks to api.xero.com – no region selector. Choose which Organisation when authorising.
  • Plans: All Xero plans expose the API. Limited features (e.g. Projects, Payroll) need the corresponding add-on subscription.

Setting up the connection

Auth type: OAuth 2.0 (Authorization Code).

  1. Sign in at developer.xero.com and create an app (Web app type).
  2. Set the Redirect URI shown in the Automize Xero connector dialog.
  3. Add the scopes listed below.
  4. Copy the Client ID and Client Secret.
  5. In Automize, open Settings → Connectors → Xero → Add connection. Paste credentials, click Connect with Xero, choose which Organisation to connect (each Org is a separate connection).

Scopes required:

  • openid
  • profile
  • email
  • accounting.transactions
  • accounting.contacts
  • accounting.settings
  • accounting.reports.read
  • offline_access

Find your credentials at https://developer.xero.com/app/manage.


Rate limits

Xero enforces 60 calls/minute and 5,000 calls/day per Organisation per app. Tight by enterprise-API standards – design for batched calls and caching. The connector retries 429 with the Retry-After header. For bulk loads, use Xero's batched POST endpoints (one call accepts up to 200 invoices/contacts).


Data model

An Organisation is the tenant. Most objects live within an Organisation.

    Contact ─┬─ Invoices ─── Payments
             ├─ Credit Notes
             └─ Quotes
    Account ─── Manual Journals
    Bank Account ─── Bank Transactions

Contacts are de-duplicated by Name (case-insensitive) within an Org.

Available operations

26 operations available. Click any row to jump to its detail.

OperationCategoryWhat it does
Create contactGeneralCreate a new contact in Xero.
Create credit noteGeneralCreate a new credit note in Xero.
Create invoiceGeneralCreate a new sales (ACCREC) or purchase (ACCPAY) invoice in Xero.
Create paymentGeneralCreate a payment against an invoice in Xero.
Create purchase orderGeneralCreate a new purchase order in Xero.
Create quoteGeneralCreate a new quote in Xero.
Balance sheet reportGeneralGet the Balance Sheet report from Xero.
Get contactGeneralGet a contact by ID from Xero.
Get credit noteGeneralGet a credit note by ID from Xero.
Get invoiceGeneralGet an invoice by ID from Xero.
Get itemGeneralGet an inventory item by ID from Xero.
Profit & loss reportGeneralGet the Profit & Loss report from Xero.
Get purchase orderGeneralGet a purchase order by ID from Xero.
Get quoteGeneralGet a quote by ID from Xero.
Trial balance reportGeneralGet the Trial Balance report from Xero.
List accountsGeneralList the chart of accounts in Xero.
List bank transactionsGeneralList bank transactions in Xero.
List contactsGeneralList all contacts in Xero.
List credit notesGeneralList all credit notes in Xero.
List invoicesGeneralList all invoices in Xero.
List itemsGeneralList inventory items in Xero.
List paymentsGeneralList all payments in Xero.
List purchase ordersGeneralList all purchase orders in Xero.
List quotesGeneralList all quotes in Xero.
Update contactGeneralUpdate an existing contact in Xero.
Update invoiceGeneralUpdate an existing invoice in Xero.

Operations

Create contact

Create a new contact in Xero.

ParameterRequiredTypeDescription
Name NameYestext
Email EmailAddressNotext

Tips

  • Name is the required dedupe key – case-insensitive unique per Org.
  • EmailAddress + ContactNumber are optional but useful for downstream sync.

Create credit note

Create a new credit note in Xero.

No input parameters.

Tips

  • Allocate to a specific invoice via Allocations on the Invoice update, not here. This just creates the credit note.

Create invoice

Create a new sales (ACCREC) or purchase (ACCPAY) invoice in Xero.

ParameterRequiredTypeDescription
Type (ACCREC/ACCPAY) TypeYestext
Contact (JSON) ContactYestext
Line items (JSON) LineItemsYestextarea

Tips

  • Status defaults to DRAFT. Set Status=AUTHORISED to send straight to the customer.
  • Type=ACCREC for sales invoices, ACCPAY for bills.
  • Line items: each needs Description + (UnitAmount + Quantity OR LineAmount), plus AccountCode.

Errors

  • ValidationException – Field-level validation failed. Response body lists each offending field.
  • InvoiceNumber must be unique – Numbering scheme conflict. Don't pass InvoiceNumber to let Xero auto-assign.

Create payment

Create a payment against an invoice in Xero.

ParameterRequiredTypeDescription
Invoice (JSON) InvoiceYestext
Account (JSON) AccountYestext
Amount AmountYesnumber
Date (YYYY-MM-DD) DateYestext

Tips

  • Apply a payment to an Invoice (sales) or Bill (purchases). Requires Invoice ID + Account (the bank) + Amount + Date.

Create purchase order

Create a new purchase order in Xero.

No input parameters.


Create quote

Create a new quote in Xero.

No input parameters.

Tips

  • Same line item shape as invoices. Convert ACCEPTED → invoice via the Xero UI (no direct API endpoint).

Balance sheet report

Get the Balance Sheet report from Xero.

No input parameters.


Get contact

Get a contact by ID from Xero.

ParameterRequiredTypeDescription
Contact ID contact_idYestext

Tips

  • contact_id or ContactNumber. Returns full contact incl. addresses, phones, balances.

Get credit note

Get a credit note by ID from Xero.

ParameterRequiredTypeDescription
Credit note ID creditNoteIdYestext
Credit Note Id credit_note_idYestext

Get invoice

Get an invoice by ID from Xero.

ParameterRequiredTypeDescription
Invoice ID invoice_idYestext

Tips

  • invoice_id or InvoiceNumber. Returns line items, payments, attachments references.

Get item

Get an inventory item by ID from Xero.

ParameterRequiredTypeDescription
Item ID itemIdYestext
Item Id item_idYestext

Profit & loss report

Get the Profit & Loss report from Xero.

No input parameters.


Get purchase order

Get a purchase order by ID from Xero.

ParameterRequiredTypeDescription
Purchase order ID purchaseOrderIdYestext
Purchase Order Id purchase_order_idYestext

Get quote

Get a quote by ID from Xero.

ParameterRequiredTypeDescription
Quote ID quoteIdYestext
Quote Id quote_idYestext

Trial balance report

Get the Trial Balance report from Xero.

No input parameters.


List accounts

List the chart of accounts in Xero.

No input parameters.

Tips

  • Chart of accounts. Filter by Type (REVENUE, EXPENSE, BANK, etc.).
  • AccountCode is the human-readable code; AccountID is the UUID.

List bank transactions

List bank transactions in Xero.

No input parameters.

Tips

  • Type: RECEIVE (money in), SPEND (money out), or transfer types.
  • Filter by BankAccount.AccountID to scope to one bank account.

List contacts

List all contacts in Xero.

No input parameters.

Tips

  • Where: Name.Contains("Acme") for fuzzy search.
  • IncludeArchived=true to return inactive contacts.

List credit notes

List all credit notes in Xero.

No input parameters.

Tips

  • Filter by Type (ACCRECCREDIT / ACCPAYCREDIT) and Status.

List invoices

List all invoices in Xero.

No input parameters.

Tips

  • Filter via Where clause: Status=="AUTHORISED", Type=="ACCREC" (sales) or Type=="ACCPAY" (bills).
  • Pagination is 100 per page. Use page parameter.
  • Add summaryOnly=true for header-only listings (much faster on big orgs).

List items

List inventory items in Xero.

No input parameters.

Tips

  • Inventory / non-inventory items. Has Code (your SKU), Name, sale and purchase details.

List payments

List all payments in Xero.

No input parameters.

Tips

  • Filter by Invoice.InvoiceID to find payments against a specific invoice.

List purchase orders

List all purchase orders in Xero.

No input parameters.


List quotes

List all quotes in Xero.

No input parameters.

Tips

  • Status flow: DRAFT → SENT → ACCEPTED → INVOICED, or DECLINED.

Update contact

Update an existing contact in Xero.

ParameterRequiredTypeDescription
Contact ID contactIdYestext
Contact Id contact_idYestext

Tips

  • Set IsCustomer=true / IsSupplier=true to flag – Xero tracks these separately.

Update invoice

Update an existing invoice in Xero.

ParameterRequiredTypeDescription
Invoice ID invoice_idYestext
Fields (JSON) fieldsYestextarea

Tips

  • Only DRAFT invoices can change line items. AUTHORISED invoices can only update notes / reference / dates.
  • Status transition AUTHORISED → VOIDED is irreversible.

FAQ

Why does my invoice fail with 'ValidationException – Account code is required'?
Every line item needs an AccountCode from the chart of accounts (e.g. 200 for Sales). Look it up via List Accounts.
Multiple Organisations – one connection or several?
Each Xero Organisation = one Automize Xero connection. Authorise once per Org. Use process variables to pick the right connection at runtime.
Can I post to a Posted (locked) period?
No. Xero forbids edits in a locked period. The Org's CurrentFinancialYearEndDate locks history. To amend, unlock via the Xero UI or post adjustments in a current period.
InvoiceNumber sequence – manual or auto?
Leave InvoiceNumber off and Xero auto-assigns per its sequence. Pass it explicitly only if you're migrating data with existing numbers – collisions return ValidationException.

Related connectors

See it working on your own data

Everything documented here ships with the platform – try the document tools free, or go live in 7 days.