The Xero Accounting API gives programmatic access to core accounting resources in Xero – contacts, accounts, bank transactions, bank transfers, batch payments, purchase orders, credit notes, branding themes and contact groups – allowing you to retrieve, create, update, delete, and manage attachments and history records for these entities.
CreditNoteID(path, required) — Unique identifier for a Credit Note
FileName(path, required) — Name of the file you are attaching to Credit Note
IncludeOnline(query) — Allows an attachment to be seen by the end customer within their online invoice
GET
/CreditNotes/{CreditNoteID}/History
Retrieves history records of a specific credit note
CreditNoteID(path, required) — Unique identifier for a Credit Note
PUT
/CreditNotes/{CreditNoteID}/History
Retrieves history records of a specific credit note
CreditNoteID(path, required) — Unique identifier for a Credit Note
GET
/CreditNotes/{CreditNoteID}/pdf
Retrieves credit notes as PDF files
CreditNoteID(path, required) — Unique identifier for a Credit Note
GET
/Currencies
Retrieves currencies for your Xero organisation
where(query) — Filter by an any element
order(query) — Order by an any element
PUT
/Currencies
Create a new currency for a Xero organisation
GET
/Employees
Retrieves employees used in Xero payrun
If-Modified-Since(header) — Only records created or modified since this timestamp will be returned
where(query) — Filter by an any element
order(query) — Order by an any element
POST
/Employees
Creates a single new employees used in Xero payrun
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
PUT
/Employees
Creates new employees used in Xero payrun
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
GET
/Employees/{EmployeeID}
Retrieves a specific employee used in Xero payrun using a unique employee Id
EmployeeID(path, required) — Unique identifier for a Employee
GET
/ExpenseClaims
Retrieves expense claims
If-Modified-Since(header) — Only records created or modified since this timestamp will be returned
where(query) — Filter by an any element
order(query) — Order by an any element
PUT
/ExpenseClaims
Creates expense claims
GET
/ExpenseClaims/{ExpenseClaimID}
Retrieves a specific expense claim using a unique expense claim Id
ExpenseClaimID(path, required) — Unique identifier for a ExpenseClaim
POST
/ExpenseClaims/{ExpenseClaimID}
Updates a specific expense claims
ExpenseClaimID(path, required) — Unique identifier for a ExpenseClaim
GET
/ExpenseClaims/{ExpenseClaimID}/History
Retrieves history records of a specific expense claim
ExpenseClaimID(path, required) — Unique identifier for a ExpenseClaim
PUT
/ExpenseClaims/{ExpenseClaimID}/History
Creates a history record for a specific expense claim
ExpenseClaimID(path, required) — Unique identifier for a ExpenseClaim
GET
/InvoiceReminders/Settings
Retrieves invoice reminder settings
GET
/Invoices
Retrieves sales invoices or purchase bills
If-Modified-Since(header) — Only records created or modified since this timestamp will be returned
where(query) — Filter by an any element
order(query) — Order by an any element
IDs(query) — Filter by a comma-separated list of InvoicesIDs.
InvoiceNumbers(query) — Filter by a comma-separated list of InvoiceNumbers.
ContactIDs(query) — Filter by a comma-separated list of ContactIDs.
Statuses(query) — Filter by a comma-separated list Statuses. For faster response times we recommend using these explicit parameters instead of passing OR conditions into the Where filter.
page(query, page) — e.g. page=1 – Up to 100 invoices will be returned in a single API call with line items shown for each invoice
includeArchived(query) — e.g. includeArchived=true - Contacts with a status of ARCHIVED will be included in the response
createdByMyApp(query) — When set to true you'll only retrieve Invoices created by your app
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
POST
/Invoices
Updates or creates one or more sales invoices or purchase bills
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
PUT
/Invoices
Creates one or more sales invoices or purchase bills
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
GET
/Invoices/{InvoiceID}
Retrieves a specific sales invoice or purchase bill using a unique invoice Id
InvoiceID(path, required) — Unique identifier for an Invoice
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
POST
/Invoices/{InvoiceID}
Updates a specific sales invoices or purchase bills
InvoiceID(path, required) — Unique identifier for an Invoice
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
GET
/Invoices/{InvoiceID}/Attachments
Retrieves attachments for a specific invoice or purchase bill
InvoiceID(path, required) — Unique identifier for an Invoice
GET
/Invoices/{InvoiceID}/Attachments/{AttachmentID}
Retrieves a specific attachment from a specific invoices or purchase bills by using a unique attachment Id
InvoiceID(path, required) — Unique identifier for an Invoice
AttachmentID(path, required) — Unique identifier for an Attachment
contentType(header, required) — The mime type of the attachment file you are retrieving i.e image/jpg, application/pdf
GET
/Invoices/{InvoiceID}/Attachments/{FileName}
Retrieves an attachment from a specific invoice or purchase bill by filename
InvoiceID(path, required) — Unique identifier for an Invoice
FileName(path, required) — Name of the file you are attaching
contentType(header, required) — The mime type of the attachment file you are retrieving i.e image/jpg, application/pdf
POST
/Invoices/{InvoiceID}/Attachments/{FileName}
Updates an attachment from a specific invoices or purchase bill by filename
InvoiceID(path, required) — Unique identifier for an Invoice
FileName(path, required) — Name of the file you are attaching
PUT
/Invoices/{InvoiceID}/Attachments/{FileName}
Creates an attachment for a specific invoice or purchase bill by filename
InvoiceID(path, required) — Unique identifier for an Invoice
FileName(path, required) — Name of the file you are attaching
IncludeOnline(query) — Allows an attachment to be seen by the end customer within their online invoice
POST
/Invoices/{InvoiceID}/Email
Sends a copy of a specific invoice to related contact via email
InvoiceID(path, required) — Unique identifier for an Invoice
GET
/Invoices/{InvoiceID}/History
Retrieves history records for a specific invoice
InvoiceID(path, required) — Unique identifier for an Invoice
PUT
/Invoices/{InvoiceID}/History
Creates a history record for a specific invoice
InvoiceID(path, required) — Unique identifier for an Invoice
GET
/Invoices/{InvoiceID}/OnlineInvoice
Retrieves a URL to an online invoice
InvoiceID(path, required) — Unique identifier for an Invoice
GET
/Invoices/{InvoiceID}/pdf
Retrieves invoices or purchase bills as PDF files
InvoiceID(path, required) — Unique identifier for an Invoice
GET
/Items
Retrieves items
If-Modified-Since(header) — Only records created or modified since this timestamp will be returned
where(query) — Filter by an any element
order(query) — Order by an any element
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
POST
/Items
Updates or creates one or more items
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
PUT
/Items
Creates one or more items
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
DELETE
/Items/{ItemID}
Deletes a specific item
ItemID(path, required) — Unique identifier for an Item
GET
/Items/{ItemID}
Retrieves a specific item using a unique item Id
ItemID(path, required) — Unique identifier for an Item
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
POST
/Items/{ItemID}
Updates a specific item
ItemID(path, required) — Unique identifier for an Item
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
GET
/Items/{ItemID}/History
Retrieves history for a specific item
ItemID(path, required) — Unique identifier for an Item
PUT
/Items/{ItemID}/History
Creates a history record for a specific item
ItemID(path, required) — Unique identifier for an Item
GET
/Journals
Retrieves journals
If-Modified-Since(header) — Only records created or modified since this timestamp will be returned
offset(query, offset) — Offset by a specified journal number. e.g. journals with a JournalNumber greater than the offset will be returned
paymentsOnly(query) — Filter to retrieve journals on a cash basis. Journals are returned on an accrual basis by default.
GET
/Journals/{JournalID}
Retrieves a specific journal using a unique journal Id.
JournalID(path, required) — Unique identifier for a Journal
GET
/LinkedTransactions
Retrieves linked transactions (billable expenses)
page(query, page) — Up to 100 linked transactions will be returned in a single API call. Use the page parameter to specify the page to be returned e.g. page=1.
LinkedTransactionID(query) — The Xero identifier for an Linked Transaction
SourceTransactionID(query) — Filter by the SourceTransactionID. Get the linked transactions created from a particular ACCPAY invoice
ContactID(query) — Filter by the ContactID. Get all the linked transactions that have been assigned to a particular customer.
Status(query) — Filter by the combination of ContactID and Status. Get the linked transactions associated to a customer and with a status
TargetTransactionID(query) — Filter by the TargetTransactionID. Get all the linked transactions allocated to a particular ACCREC invoice
PUT
/LinkedTransactions
Creates linked transactions (billable expenses)
DELETE
/LinkedTransactions/{LinkedTransactionID}
Deletes a specific linked transactions (billable expenses)
LinkedTransactionID(path, required) — Unique identifier for a LinkedTransaction
GET
/LinkedTransactions/{LinkedTransactionID}
Retrieves a specific linked transaction (billable expenses) using a unique linked transaction Id
LinkedTransactionID(path, required) — Unique identifier for a LinkedTransaction
POST
/LinkedTransactions/{LinkedTransactionID}
Updates a specific linked transactions (billable expenses)
LinkedTransactionID(path, required) — Unique identifier for a LinkedTransaction
GET
/ManualJournals
Retrieves manual journals
If-Modified-Since(header) — Only records created or modified since this timestamp will be returned
where(query) — Filter by an any element
order(query) — Order by an any element
page(query, page) — e.g. page=1 – Up to 100 manual journals will be returned in a single API call with line items shown for each overpayment
POST
/ManualJournals
Updates or creates a single manual journal
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
PurchaseOrderID(path, required) — Unique identifier for Purchase Order object
FileName(path, required) — Name of the attachment
PUT
/Payments
Creates multiple payments for invoices or credit notes
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
GET
/Payments/{PaymentID}
Retrieves a specific payment for invoices and credit notes using a unique payment Id
PaymentID(path, required) — Unique identifier for a Payment
POST
/Payments/{PaymentID}
Updates a specific payment for invoices and credit notes
PaymentID(path, required) — Unique identifier for a Payment
GET
/Payments/{PaymentID}/History
Retrieves history records of a specific payment
PaymentID(path, required) — Unique identifier for a Payment
PUT
/Payments/{PaymentID}/History
Creates a history record for a specific payment
PaymentID(path, required) — Unique identifier for a Payment
GET
/Prepayments
Retrieves prepayments
If-Modified-Since(header) — Only records created or modified since this timestamp will be returned
where(query) — Filter by an any element
order(query) — Order by an any element
page(query, page) — e.g. page=1 – Up to 100 prepayments will be returned in a single API call with line items shown for each overpayment
unitdp(query) — e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts
GET
/Prepayments/{PrepaymentID}
Allows you to retrieve a specified prepayments
PrepaymentID(path, required) — Unique identifier for a PrePayment
PUT
/Prepayments/{PrepaymentID}/Allocations
Allows you to create an Allocation for prepayments
PrepaymentID(path, required) — Unique identifier for Prepayment
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
GET
/Prepayments/{PrepaymentID}/History
Retrieves history record for a specific prepayment
PrepaymentID(path, required) — Unique identifier for a PrePayment
PUT
/Prepayments/{PrepaymentID}/History
Creates a history record for a specific prepayment
PrepaymentID(path, required) — Unique identifier for a PrePayment
GET
/PurchaseOrders
Retrieves purchase orders
If-Modified-Since(header) — Only records created or modified since this timestamp will be returned
Status(query) — Filter by purchase order status
DateFrom(query) — Filter by purchase order date (e.g. GET https://.../PurchaseOrders?DateFrom=2015-12-01&DateTo=2015-12-31
DateTo(query) — Filter by purchase order date (e.g. GET https://.../PurchaseOrders?DateFrom=2015-12-01&DateTo=2015-12-31
order(query) — Order by an any element
page(query, page) — To specify a page, append the page parameter to the URL e.g. ?page=1. If there are 100 records in the response you will need to check if there is any more data by fetching the next page e.g ?page=2 and continuing this process until no more results are returned.
POST
/PurchaseOrders
Updates or creates one or more purchase orders
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
GET
/PurchaseOrders/{PurchaseOrderID}/History
Retrieves history for a specific purchase order
PurchaseOrderID(path, required) — Unique identifier for a PurchaseOrder
PUT
/PurchaseOrders
Creates one or more purchase orders
summarizeErrors(query) — If false return 200 OK and mix of successfully created objects and any with validation errors
GET
/PurchaseOrders/{PurchaseOrderID}
Retrieves a specific purchase order using a unique purchase order Id
PurchaseOrderID(path, required) — Unique identifier for a PurchaseOrder
POST
/PurchaseOrders/{PurchaseOrderID}
Updates a specific purchase order
PurchaseOrderID(path, required) — Unique identifier for a PurchaseOrder
GET
/PurchaseOrders/{PurchaseOrderID}/Attachments
Retrieves attachments for a specific purchase order
PurchaseOrderID(path, required) — Unique identifier for Purchase Orders object