Integrations / Payments

Xero

Look up invoices and contacts in a Xero organisation, create invoices and bills, and trigger workflows from Xero invoice, contact and credit note events.

7 tools 10 trigger events Connect with OAuth

Tools

xero.list_tenants

List the Xero organisations this connection is authorised for, with the tenantId to use as the connection's tenant ID.

xero.list_invoices

List invoices, newest changes first, filtered by status, contact or a where clause. Invoice IDs are UUIDs like 243216c5-369e-4056-ac67-05388f86dc81.

wherestatusescontact_idsinvoice_numberssearch_termorderpagepage_size

xero.get_invoice

Get an invoice with its line items and payments by invoice ID, a UUID like 243216c5-369e-4056-ac67-05388f86dc81.

invoice_id*

xero.create_invoice writes

Create a sales invoice (ACCREC) or a bill (ACCPAY) for a contact. Contact IDs are UUIDs like bd2270c3-8706-4c11-9cfb-000b551c3f51; find them with list_contacts.

contact_id*typeline_items*statusdatedue_datereferenceinvoice_numberline_amount_types

xero.list_contacts

List contacts, filtered by a search term or a where clause. Contact IDs are UUIDs like bd2270c3-8706-4c11-9cfb-000b551c3f51.

search_termwhereorderpagepage_sizesummary_only

xero.api_get

Send a GET request to any Xero API path under https://api.xero.com and return the response. For endpoints the named tools don't cover.

path*params

xero.api_request writes

Send a POST, PUT, PATCH or DELETE request to any Xero API path under https://api.xero.com.

method*path*paramsbody

Tick Allow raw writes on the connection to add api_request, which can send POST, PUT, PATCH and DELETE requests to any Xero API path.

Connect

  1. Create a Web app under My Apps on developer.xero.com, and add the redirect URL shown on the connection page as its redirect URI.
  2. Copy the app's client ID and generate a client secret under Configuration, and paste both on the connection.
  3. Click Connect on the connection page and pick the organisation. The connection page then lists the organisations the app can reach with their tenant IDs (the list_tenants tool shows them too); paste the one workflows should use as the tenant ID.
  4. To trigger workflows, open Webhooks in the app on developer.xero.com, choose the event categories, set the delivery URL shown on the connection page, and save. Paste the webhooks key shown there on the connection, then click Send "Intent To Receive".

Press Connect on the connection to approve access at Xero. Tokens renew automatically. How OAuth connections work

Credentials

Client secret Webhooks key

Xero API docs

Triggers

On developer.xero.com, open My Apps → your app → Webhooks, choose the event categories, set this URL as the delivery URL and save. Paste the webhooks key shown there on this connection, then click Send "Intent To Receive". Each event in a batch starts its own run, named by category and type (e.g. INVOICE.UPDATE), with resourceId and tenantId in the payload.

Events

INVOICE.CREATEINVOICE.UPDATECONTACT.CREATECONTACT.UPDATECREDITNOTE.CREATECREDITNOTE.UPDATEPREPAYMENT.CREATEPREPAYMENT.UPDATEOVERPAYMENT.CREATEOVERPAYMENT.UPDATE
trigger
kind: xero connection: xero events: [INVOICE.CREATE] tenants: [...]

Your next automation is one sentence away.

14-day free trial with $5 of built-in AI included. Cancel anytime.