Xero
A simple node library for Xero Private Applications
Install
npm install xero-extended
Use
You can use similar methods for xero.Invoices
, xero.Payments
, and xero.Users
.
var Xero = ;var xero = CONSUMER_KEY CONSUMER_SECRET RSA_PRIVATE_KEY; // Find a bunch of InvoicesxeroInvoicesall { if err return res; res;}; // Find a single InvoicexeroInvoices; // Create an Invoicevar invoiceData = Type: xeroInvoicesSALE Contact: Name: 'Nathan Hoad' Date: DueDate: '2014-12-01' LineAmountTypes: xeroInvoicesEXCLUSIVE LineItems: Description: 'This is a thing' Quantity: 7 UnitAmount: 120 DiscountRate: 10 AccountCode: 200 ;xeroInvoices
Raw calls
Request
var Xero = ; var xero = CONSUMER_KEY CONSUMER_SECRET RSA_PRIVATE_KEY;xero;
Response
"Response": "Id":"37286998-xxxx-xxxx-xxxx-xxxxxxxxxxxx" "Status":"OK" "ProviderName":"My Account" "DateTimeUTC":"2013-04-22T17:13:31.2755569Z" "Users": "UserID":"613fbf01-xxxx-xxxx-xxxx-xxxxxxxxxxxx" "FirstName":"Chadd" "LastName":"Sexington" "UpdatedDateUTC":"2013-04-12T05:54:50.477" "IsSubscriber":"true" "OrganisationRole":"STANDARD"
Download PDF
var Xero = ;var fs = ; var xero = CONSUMER_KEY CONSUMER_SECRET RSA_PRIVATE_KEY;var invoiceId = 'invoice-identifier';var req = xero; req;req;req;
Docs
http://developer.xero.com/api/
Authors
- thallium205 https://github.com/thallium205
- nathanhoad https://github.com/nathanhoad