Set up your Xero integration

Before you can access data from your customers who use Xero for their accounting, you need to set up the Xero integration.

You'll need to:

  • Create a Xero app.
  • Retrieve your app's secure keys.
  • Add the app's secure keys to the Codat Portal.

To link more than 25 companies (excluding connections to the Xero demo company) you must become a Xero app partner. For more information, see Applying for app partner status with Xero on this page.

🚧

Connection limits for non-partner apps

Xero apps created by non-partners, known as uncertified apps, are limited to a maximum of 25 connections (excluding connections to the Xero demo company).

To remove this connection limit, you must be granted app partner status with Xero. For more information, see App Partner Overview and OAuth 2.0 API limits in the Xero Developer documentation.

Create a Xero app

Create and configure an app in Xero Developer.

  1. Log in to Xero Developer using your Xero credentials, or sign up for a Xero Developer account if you don't already have one.

  2. Click My Apps in the top navigation bar, then click New app.

  3. Enter the following information in the Add a new app dialog:

    • App name: Enter a name for your application. This is displayed to your users when they authorize your access to their accounting data, so choose a name that clearly identifies your organization.

    • Integration type: Select Web app.

    • Company or application URL: Enter the URL for your company's website prefixed with https://

    • Redirect URI: Enter https://xero.codat.io/oauth2/callback

  4. Agree to the Xero Developer Platform Terms & Conditions, then click Create app.

Your new app is displayed on the My Apps page. If you do not have app partner status, 25 max connections is displayed next to the app name:

If you want to apply for app partner status with Xero, you should also provide links to your privacy policy and terms and conditions. To provide this information, click the app name then enter the details in the Web app section of the App details page.

Retrieve your app's secure keys

Retrieve the secure keys for the app you created in Xero Developer.

  1. Click My Apps in the top navigation bar, then select your application from the list.

  2. Click Configuration in the left pane.

  3. Click the eye icon to show your app's Client ID in the Client id box.

  4. Click Generate a secret to generate a client secret for your app; the secret appears in the Client secret 1 box.

    Note: Copy the secret and store it in a safe place. If you leave the Configuration page, you won't be able to view the same client secret again; you'll need to generate a new one.

  5. Keep this page open in your browser. You'll need to enter your secure keys in the following procedure.

Add your secure keys to Codat

After you've created and configured a Xero application, add the application's keys to the Xero integration. When you're ready, enable the integration.

Perform these steps in the Codat Portal.

  1. On the navigation bar, select Settings > Accounting.

  2. Find the Xero integration, then select Manage.

  3. Select One-off or Continuous to choose what type of access to company data the integration will have.

  4. Enter the Client id and Client secret from your Xero app, then click Save.

  5. Enable the integration by setting the Xero toggle to Enabled.

Configure direct bank feeds

To create a direct bank feed using Xero's Bank Feeds API, you push (POST) Bank Transactions via the Codat API.

To create direct bank feeds in Xero, you must have app partner status. Additionally, the Bank Feeds API must be enabled by Xero for your registered app. For more information, see the Bank Feeds API Overview in the Xero Developer documentation.

Make sure you enable Bank Feeds in your Codat portal. You can do so by navigating to the Manage section of the portal under the Integrations > Accounting tab, and clicking the toggle. Save the page to validate this configuration.

If you don't have access to direct bank feeds, a 403 error is returned if you try to push bank transactions to Xero. For example:

{
  "type": "invalid-organisation-bank-feeds",
  "title": "Invalid Organisation",
  "status": 403,
  "detail": "The organisation does not support automated bank feeds."
}

Apply for app partner status with Xero

❗️

Financial services providers

Financial services providers may be subject to additional commercial terms before being granted app partner status with Xero. If you are a financial services provider, we strongly recommend that you contact Xero before you build your integration. You can also contact your Codat sales or solutions representative to learn more about Xero app partnership.

Xero have specific requirements about who can gain app partner status and how they must build their integration. Xero app partnership is not possible for all use cases.

For detailed information about applying for app partner status with Xero, review the following articles in the Xero Developer documentation:

To start the app partner application process, click Join the Xero App Store on the App details page for your app. You can also contact [email protected] with the details of the application you are building.


Did this page help you?