Skip to content

krisquigley/electio

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Codeship Status for krisquigley/electio Codacy Badge Codacy Badge

electio

Ruby gem for the electio API

Installation

Add this line to your application's Gemfile:

gem 'electio'

Basic usage

require 'electio'

Electio.configure do |config|
  config.api_key = ENV['API_KEY'] # Your Primary or Secondary developer API key.
end

Querying an endpoint

Summary of a specific consignment:

consignment_reference = 'EC-XXX-XXX-XXX'
consignment = Electio::Consignment.find(consignment_reference) #=> Returns response as an object.

Creating a consignment:

consignment_params = { ... }
consignment = Electio::Consignment.new(consignment_params)
consignment.save #=> Returns response as an object

Todo

  • Error handling
  • Implement 100% of API - #3

Contributing

Feel free to implement the missing API end points listed above and submit a PR Bug reports and pull requests are welcome on GitHub at https://github.com/krisquigley/electio.

About

Ruby gem for the electio API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages