A ruby client for accessing the Xero API
Ruby Shell
Switch branches/tags
Nothing to show
Permalink
Failed to load latest commit information.
lib
spec
.gitignore
.rvmrc
Gemfile
LICENSE
README.md
Rakefile
ruxero.gemspec

README.md

Ruxero (Xero API Ruby Client) Project status

Goals for this project

  • Provide a Rails 3 like syntax for querying records

    Ruxero::Invoice.find('abc123-abc123-abc123-abc123')
    Ruxero::Contact.where(:status => 'ACTIVE').all
    Ruxero::Contact.where(:status => 'ACTIVE').order('Name').first
    Ruxero::Contact.where(:status => 'ACTIVE').order('Name').last
  • Provide a Rails 3 like syntax for creating records

    Ruxero::Contact.new(:name => 'Joe Somebody')
    
    Ruxero::Contact.create(:name => 'Joe Somebody')
    
    record = Ruxero::Contact.new
    record.name = 'Joe Somebody'
    record.save
  • Provide a Rails 3 like syntax for updating records

    record = Ruxero::Contact.find('abc123-abc123-abc123-abc123')
    record.update_attributes(:name => 'Joe Somebody')
    
    record = Ruxero::Contact.find('abc123-abc123-abc123-abc123')
    record.name = 'Joe Somebody'
    record.save
  • Provide an easy configuration interface

    Ruxero.configure do |config|
      config.application = Ruxero::PrivateApplication
      config.oauth_consumer_key = 'ABCDEFGHIJKLMNOPQRSTUVWXYZABCD'
      config.oauth_consumer_secret = 'ABCDEFGHIJKLMNOPQRSTUVWXYZABCD'
      config.private_key_path = Rails.root.join('config/xero/privatekey.pem')
    end
    
    Ruxero.configuration.oauth_consumer_key = 'ABCDEFGHIJKLMNOPQRSTUVWXYZABCD'
  • Provide thorough code documentation using SDoc

  • Provide clear usage examples through a detailed test suite