Xero

Xero Bank Feeds API v2

The Bank Feeds API is available to financial institutions with a Xero partnership and approved app partners. For non-bank apps, it automates statement imports…

Finance & banking#openapi

Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.

Overview

The Bank Feeds API is available to financial institutions with a Xero partnership and approved app partners. For non-bank apps, it automates statement imports into Xero bank and credit card accounts; it does not create a direct bank feed.
Feed Connections 2.0 is intended to replace 1.0. The customer chooses whether to connect an existing Xero account or create a new one. Use ExistingAccount with the chosen accountId, or NewAccount to create an account; Xero does not guess which account to connect or silently change an account name. The GET and delete operations also use 2.0. Statements continue to use 1.0.
Partial failures are rare, and nearly all are recoverable by your app with no need to contact Xero support. If an item in a write response has status PARTIAL_FAILURE, handle only that item and read its error.type. For partial-failure-new-account-creation, do not resend the NewAccount item: connect error.accountId with POST /FeedConnections/ExistingAccount. For partial-failure-new-account-existence-not-confirmed, the account named in error.accountName may or may not exist. Use the Accounting API to check whether an account with that name exists. If it does, connect it with POST /FeedConnections/ExistingAccount. If it does not, resend the NewAccount item. If your app has a user, you can show them this message instead: "Something went wrong. Please check whether your chosen account name now exists. If it does, connect it. If not, try creating the new one again." For any other partial-failure-* type, resend the same item. If the recovery request for partial-failure-new-account-creation, partial-failure-previous-connection-deletion or partial-failure-connection-creation returns 409 feed-already-connected-in-current-organisation, the earlier attempt succeeded: treat the item as created and use GET /FeedConnections to find its id. error.subtype is optional diagnostics; do not branch on it, and never parse title or detail. Full detail: https://developer.xero.com/documentation/api/bankfeeds/feedconnections-2-0-errors/#partial-failures

Endpoints 5

FeedConnections

  • GETRetrieve the Feed Connections for an Organisation/FeedConnections?page=1&pageSize=10Returns the Feed Connections belonging to both the Organisation in Xero-Tenant-Id and the Application associated with the OAuth client. Connections belonging…
  • GETRetrieve a single Feed Connection/FeedConnections/:idReturns one Feed Connection, as a bare object rather than inside an envelope. The response is 404 bank-feed-not-found when the identifier names no Feed…
  • POSTConnect feeds to Xero Bank Accounts that already exist/FeedConnections/ExistingAccountCreates Feed Connections against Xero Bank Accounts the Organisation already has. Each item must include the accountId of the account it connects to. Xero…
  • POSTCreate Xero Bank Accounts and connect feeds to them/FeedConnections/NewAccountCreates a new Xero Bank Account for each item and connects a feed to it. accountId must not be supplied. An item that includes one — including an all-zeros…
  • POSTTerminate Feed Connections/FeedConnections/DeleteRequestsTerminates the Feed Connections named in the request. Terminating a Feed Connection discontinues the bank feed, and does not otherwise affect the customer's…

API details

Base URL
https://api.xero.com/bankfeeds.xro/2.0
Authentication
OAuth 2.0 (authorization code flow) with 4 scopes
Operations
5 operations on 5 pathsPOST 3GET 2
Main resources
FeedConnections 5
Response formats
application/json application/problem+json
Description format
OpenAPI 3.0.0, API version 20.1.0

How to test the Xero Bank Feeds API v2 in Swastik Codes

  1. Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
  2. Fork it into your workspaceChoose a workspace. You get your own copy of the Xero Bank Feeds API v2 collection, without the publisher's secrets.
  3. Add your credentialsThis API uses OAuth 2.0 (authorization code flow) with 4 scopes. Add yours in the collection's variables or an environment; the requests already reference it.
  4. Send a requestPick an endpoint, for example “Retrieve the Feed Connections for an Organisation” (GET /FeedConnections?page=1&pageSize=10), and press Send. Check the response, add tests and run the whole collection with the runner.

Frequently asked questions

What is the Xero Bank Feeds API v2?

The Bank Feeds API is available to financial institutions with a Xero partnership and approved app partners. For non-bank apps, it automates statement imports… It is listed under Finance & banking and has 5 endpoints.

Who publishes the Xero Bank Feeds API v2?

It is listed from Xero's public API description (an OpenAPI document), not published by Xero on Swastik Codes. Anyone who controls xero.com can claim the profile by adding a DNS TXT record.

What is the base URL of the Xero Bank Feeds API v2?

Requests go to https://api.xero.com/bankfeeds.xro/2.0. Endpoint paths are added to this base URL.

How do I authenticate with the Xero Bank Feeds API v2?

With OAuth 2.0 (authorization code flow) with 4 scopes.

How many endpoints does the Xero Bank Feeds API v2 have?

5 operations on 5 paths (3 POST, 2 GET). The largest groups are FeedConnections.

Is forking the Xero Bank Feeds API v2 free?

Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.

Suggest an API

Tell us which public API is missing. We check it, then add it here with its endpoints when it has an OpenAPI (Swagger) description.