# Xero Accounting API

> Xero's official OpenAPI 3.0 description of the Xero Accounting API, published by Xero under the MIT license.

- Page: https://library.schematica.io/model/60d6dd5b2df84b29a605de56608a2283
- Model type: Schema
- License: MIT
- Access type: Free
- Access method: GitHub
- Model size: Mid
- Formats: JSON Schema
- Domains: Finance
- Audiences: Developer, Data Scientist
- Classifications: #dbt-ready #vendor-api #financial-modeling #api #accounting
- Open in CoreModels: https://go.coremodels.io/app/60d6dd5b2df84b29a605de56608a2283
- Listed in library: 2025-09-02
- Last updated: 2026-10-23

## Use cases

### Transaction Integration (Finance)

Developers create invoices and credit notes and read the chart of accounts from accounting and billing systems.

### SDK and Client Generation (Finance)

Developers generate typed clients from the OpenAPI file, as Xero does for its own SDKs.

### Agent Grounding (Finance)

AI agents look up exact Xero object fields, such as how an Invoice links to a Contact, instead of guessing them when they write code or SQL.

### Accounting Analytics Modeling (Finance)

Data engineers model Xero objects such as Account, Invoice and Journal before they build dbt models for profit and loss, general ledger and balance sheet reports. The Fivetran package fivetran/dbt_xero covers these.

## Description

## Overview
The Xero Accounting API exposes the accounting functions of the main Xero application. Clients use it to create transactions such as invoices and credit notes, and to pull accounting data through the reports endpoint. Xero publishes the description as an OpenAPI 3.0 file in the XeroAPI/Xero-OpenAPI repository; the accounting file is version 19.1.0. Its schemas include Account, Contact, Invoice, CreditNote, Payment, BankTransaction, ManualJournal and TrackingCategory. The same repository holds separate files for payroll, assets, projects and bank feeds. Developers and data engineers can use this entry to check object shapes before they write integration code or dbt models.

## Top entities
Account, Contact, Invoice, CreditNote, Payment, BankTransaction, Item, ManualJournal, PurchaseOrder, Quote, TaxRate, TrackingCategory

## Mappings
- Fivetran dbt package fivetran/dbt_xero: partial. Models cover profit and loss, general ledger and balance sheet reports.
- schema.org Invoice: conceptual. Invoice aligns in intent with schema.org Invoice, not field by field.

## For agents
Query the library's CoreModels project for Xero object shapes before generating code or SQL. Use the matching file in the repository for payroll or assets. Sample prompt: "Using the Xero Accounting API schema in the Schematica Library, list the fields that link an Invoice to its Contact and its LineItems." Read via MCP: get_project_summary with graphProjectId 60d6dd5b2df84b29a605de56608a2283.

## Provenance
Publisher: Xero. License: MIT (https://github.com/XeroAPI/Xero-OpenAPI/blob/master/LICENSE). Version: 19.1.0. Format: OpenAPI (listed here as JSON Schema until the library format list includes it). Described by the Schema Librarian on 2026-10-23; auto-cataloged.

---

Source: https://library.schematica.io/model/60d6dd5b2df84b29a605de56608a2283
