Git Product home page Git Product logo

cheddargetter_client_ruby's Introduction

Cheddar Getter API Client for Ruby

This is a Ruby wrapper for the CheddarGetter API.

It allows you to interface with the Cheddar Getter API using simple calls, i.e.:

client = CheddarGetter::Client.new(:product_code => "YOUR_PRODUCT_CODE",
                                   :username => "[email protected]",
                                   :password => "your.password")

client.new_customer(
  :code      => 'EXAMPLE_CUSTOMER',
  :firstName => 'Example',
  :lastName  => 'Customer',
  :email     => '[email protected]',
  :subscription => {
    :planCode     => 'THE_PLAN_CODE',
    :ccFirstName  => 'Example',
    :ccLastName'  => 'Customer',
    :ccNumber'    => '4111111111111111',
    :ccExpiration => '04/2011',
    :ccZip'       => '90210'
  }
)

See the ‘example` directory for more usage examples. It is modeled directly after cheddargetter-client-php, the official PHP library, with a number of ruby-isms to make life easier.

Installation

This library should be installed as a gem. It is hosted on Gemcutter.

If you don’t have your system set up to use gemcutter, follow the instructions on their site, i.e.:

$ gem install gemcutter
$ gem tumble

This will install Gemcutter and set your gem sources to search the gemcutter repos.

Then you can install this library as a gem:

$ gem install cheddargetter_client_ruby

Requirements

This library requires HTTParty version 0.4.3 or greater.

$ gem install httparty

Usage

Simply require this library before you use it:

require 'cheddargetter_client_ruby'

If you’re using Rails, you could include this gem in your configuration, i.e. in ‘environment.rb`

config.gem 'cheddargetter_client_ruby'

Check out the example to see usage details. You can also check out the Cheddar Getter API documention.

Copyright © 2011 Expected Behavior. See LICENSE.txt for further details.

cheddargetter_client_ruby's People

Contributors

brentw avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.