2017 © Pedro Peláez
 

library xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

image

picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  • Thursday, August 18, 2016
  • by cbakker
  • Repository
  • 3 Watchers
  • 4 Stars
  • 6,905 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 2 Open issues
  • 15 Versions
  • 1 % Grown

The README.md

xero-php-client

PHP Client library for the Xero oAuth API, only for private applications, (*1)

This package is not maintained anymore, we recommend this excellent alternative: https://packagist.org/packages/calcinai/xero-php, (*2)

Composer install

Installing this Xero API client for PHP can be done through Composer., (*3)

composer require picqer/xero-php-client

Usage

Create a new Private Application in your Xero account: https://app.xero.com/Application/Add, (*4)

Create a private key and certificate, and upload your certificate., (*5)

Start a Xero client:, (*6)

$xero = new Picqer\Xero\Xero('--api key--', '--api secret--', '--path to private key file--');

Provide your API key, API secret and the path to your private key file., (*7)

Now retrieve your invoices:, (*8)

$invoices = $xero->getInvoices();

Create a new contact

$contact = new Picqer\Xero\Entities\Contact();
$contact->Name = 'Casper Bakker Demo';

$address = new Picqer\Xero\Entities\ContactAddress();
$address->City = 'Doesburg';
$contact->Addresses = [ $address ];

$response = $xero->create($contact);

Create a new invoice

$invoice = new Picqer\Xero\Entities\Invoice();
$invoice->Type = 'ACCREC';
$invoice->LineAmountTypes = 'Exclusive';
$invoice->Date = new DateTime();
$invoice->DueDate = new DateTime('+2 weeks');

$lineitem = new Picqer\Xero\Entities\InvoiceLineItem();
$lineitem->Description = 'Subscription';
$lineitem->UnitAmount = 12.95;
$lineitem->AccountCode = '8100';
$lineitem->Quantity = 2;

$invoice->addLineItem($lineitem);

$invoice->Contact = $xero->getContact('--existing customer id--');

$response = $xero->create($invoice);

The Versions

18/08 2016

dev-master

9999999-dev http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

18/08 2016

v0.1.13

0.1.13.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

07/03 2016

v0.1.12

0.1.12.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

07/03 2016

v0.1.11

0.1.11.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

07/03 2016

v0.1.10

0.1.10.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

04/03 2016

v0.1.9

0.1.9.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

18/06 2015

v0.1.8

0.1.8.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

11/05 2015

v0.1.7

0.1.7.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

11/05 2015

v0.1.6

0.1.6.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

06/05 2015

v0.1.5

0.1.5.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

06/05 2015

v0.1.4

0.1.4.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

23/04 2015

v0.1.3

0.1.3.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

16/04 2015

v0.1.2

0.1.2.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

15/04 2015

v0.1.1

0.1.1.0 http://github.com/picqer/xero-php-client

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero

15/04 2015

v0.1.0

0.1.0.0 http://github.com/picqer/xero-php-api

PHP Client library for the Xero oAuth API, only for private applications

  Sources   Download

MIT

The Requires

 

by Casper Bakker

xero