fullscreeninteractive/silverstripe-xero

1.0.0 2021-09-16 01:41 UTC

This package is auto-updated.

Last update: 2021-11-28 21:20:08 UTC


README

Maintainer Contact

Installation

composer require "fullscreeninteractive/silverstripe-xero"

Documentation

Provides a lightweight wrapper around calcinai/xero-php with additional Silverstripe support for authenication and connecting applications via oauth.

To setup register a Xero Application and define your clientId and clientSecret as environment variables.

XERO_CLIENT_ID='123'
XERO_CLIENT_SECRET='123'

Once those API keys are available, a new tab under the Settings admin will appear for connecting to Xero. Follow the prompts to link the selected account to your Silverstripe website.

Interacting with the API

/** @var \XeroPHP\Application **/
$app = XeroFactory::singleton()->getApplication();

Integrating with the API is done via https://github.com/calcinai/xero-php. Consult that page for further information for creating invoices etc.