> ## Documentation Index
> Fetch the complete documentation index at: https://docs.boomfi.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# Xero

> Collect open Xero sales invoices with a BoomFi paylink.

Connect [Xero](https://www.xero.com/) so an authorised sales invoice that still has an amount due gets a BoomFi paylink. The customer pays with **Pay now** on the Xero invoice. BoomFi then records that payment in Xero.

Xero is connected with a sign-in, not an API key. This guide is for the BoomFi merchant dashboard.

## Connect Xero

> [!NOTE]
>
> If you would like access to Xero, contact your account manager. Until it is enabled for your organisation, the Xero card stays unavailable.

1. In BoomFi, open **Settings → Integration**.
2. Find **Xero** and choose **Connect**.
3. Sign in to Xero and approve access to invoices, contacts, and payments. Approve that screen in the same browser that started **Connect**.
4. If the Xero user belongs to more than one organisation, choose the one to connect. One Xero organisation connects to one BoomFi organisation. Connecting again stops the previous sync.

The card shows **Disconnect** when that organisation is connected. A warning on the card means the last sync could not finish, or an invoice was skipped.

![BoomFi integrations with Xero connected](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/integrations-xero-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=9ec605cb87bf3e6eea9660fc446e9b2f)

## Add Pay now

The button is a custom payment URL on the invoice branding theme. Add it in Xero before you send invoices. Open **Sales → Online payments**.

### Add the payment service

**Add a new service** lists Stripe cards and PayPal. BoomFi is added from **add another online payment option**.

![Add a payment service, with Stripe cards and PayPal](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-add-service-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=995284ce6a90c2f6623b584eb7eaef58)

Select **Custom Payment URL** and continue.

![Additional payment services, with Custom Payment URL](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-custom-url-choice-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=3982e1785d18922dfe449a3d9de2ddf4)

Set **Account name** to the name that should show on the invoice, such as BoomFi. Xero fills **Pay now button text** with **Pay with credit card**. Change that to **Pay now**.

![Add custom URL connection, before the URL is pasted](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-custom-url-form-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=da5df7d9a506b1cc5026e9e4e5349048)

Paste this custom URL:

```text theme={null}
https://capi.boomfi.xyz/v1/checkout/xero?invoiceId=[INVOICEID]&currency=[CURRENCY]&amount=[AMOUNTDUE]&shortCode=[SHORTCODE]
```

On the test dashboard, use `https://capi-test.boomfi.xyz` in place of `https://capi.boomfi.xyz`. A production URL does not see invoices on the test dashboard. Checkout there runs in test mode.

Xero replaces `[INVOICEID]`, `[CURRENCY]`, `[AMOUNTDUE]`, and `[SHORTCODE]` when the customer clicks. **Show details** on that form uses `[INVOICENUMBER]` in its example. That placeholder is the invoice number. A URL built from it opens a page that cannot take the payment.

![Placeholders Xero lists for a custom payment URL](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-url-placeholders-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=eb6f184a46567412e25d5b081b7a8491)

> [!WARNING]
>
> Use `[INVOICEID]`, not `[INVOICENUMBER]`. The click is accepted only when the invoice id, currency, amount due, and Xero short code all match the open invoice. Anything else sends the customer to a page that cannot take the payment.

Save. To change the URL or the button later, open **Connected services**, then **Edit → Service details**.

### Put it on the branding theme

Open **Connected services → Manage themes**. For each branding theme you send, set **Credit card** to the account you just added. **Standard** is the default theme. Save.

![Connected services, with the account on the Standard theme](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-connected-services-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=54502f73f57f18aecc1ed5a059854f6c)

![Credit card set to the account on the Standard theme](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-payment-theme-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=f1c4a186fc27d8b1a2d34bafe743cdce)

On the invoice, **Branding theme** is the theme you chose and **Online payments** shows that account name. A new invoice uses the default theme. To use another theme, change **Branding theme** on that invoice. New themes are added from **Settings → Invoice settings → New Branding Theme**.

## Stripe, PayPal, and other buttons

A branding theme has one **Credit card** service. **Cards and digital wallets** (Stripe) uses that same column. To offer Stripe cards on some invoices and BoomFi on others, add a second branding theme, connect Stripe to its **Credit card** column, and choose that theme on the invoice.

PayPal is its own service on **Add a new service**. Once it is connected, it can sit on the same theme as BoomFi. The customer then chooses **Pay now** or PayPal.

If the customer pays another way, the next sync sees the invoice paid and BoomFi turns its paylink off.

## Create the invoice

Create the invoice in Xero. BoomFi does not add a line to it.

1. Create a sales invoice with a contact, a currency, at least one line, and an amount due.
2. Set **Branding theme** to the theme whose **Credit card** service is BoomFi. **Online payments** then shows that account name.
3. Approve the invoice so its status is **Awaiting payment**. Drafts and invoices submitted for approval are left alone. Bills are left alone. An invoice that is already paid does not get a paylink.

![Sales invoice on the Standard theme, with online payments set to the account and a Workshop line](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-invoice-theme-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=f44f89153bdbdd96f1921755600983f6)

Connecting imports open invoices once. After that, Xero notifies BoomFi when an invoice is created or approved. Open invoices are also checked about once an hour, in case a notification is missed.

BoomFi creates the customer and a one-time paylink. The paylink is named `Invoice` plus the Xero invoice number, and the amount is the amount due. The Xero lines stay on the Xero invoice. They are not listed on the paylink or on checkout.

> [!WARNING]
>
> Checkout shows the invoice number and a single total. It does not show the Xero line descriptions, quantities, or unit prices.

An invoice with no contact, no currency, or no date is skipped. The rest of the sync continues, and the Xero card shows a warning.

## What the customer sees

On the Xero invoice, the lines are the ones you wrote. **Pay now** is the button from the branding theme.

![Xero invoice with the Workshop line and Pay now](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-pay-now-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=61333f07fbd0fb600cc2beec1353f8f8)

Choosing **Pay now** sends the customer to BoomFi. BoomFi checks the invoice, the currency, and the amount still due, then opens the paylink. Checkout asks for the payer's details and a payment method. The summary is the total only.

![Checkout for that invoice, showing Invoice INV-0011 and a single total](https://mintcdn.com/boom-fi/pIqMNiRxjI-4g6Iz/integrations/images/xero-checkout-boomfi.png?fit=max\&auto=format\&n=pIqMNiRxjI-4g6Iz\&q=85\&s=eba3cd7c7b9b711af7e158fa9cdbadcd)

## After the customer pays

1. In BoomFi, open **Transactions**. The payment status is **Succeeded**, and the reference is the Xero invoice.
2. In Xero, that invoice is marked **Paid** and the amount due is 0. The paylink in BoomFi becomes inactive.

A short payment in the invoice currency is recorded in Xero as that amount. The invoice and the paylink stay open.

A payment in another currency, including crypto, is recorded in Xero as the amount still due. The invoice is marked paid and the paylink is turned off.

If the payment covers the amount due and Xero has no account that can take a payment, the paylink is turned off so the customer cannot pay it twice. The Xero card shows a warning. Add an account in Xero that can take invoice payments. The next sync records the payment.

If an invoice that already has a paylink is voided or deleted in Xero, the next sync turns that paylink off.

## Related

* [Integrations Overview](/integrations/overview)
* [Payment Links](/payments/paylinks)
* [Webhooks Overview](/webhooks/overview)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.