Giter Club home page Giter Club logo

chargify_api_ares's Introduction

Chargify API wrapper for Ruby (using ActiveResource) build status

This is a Ruby wrapper for the Chargify API that leverages ActiveResource.

It allows you to interface with the Chargify API using simple ActiveRecord-like syntax, i.e.:

Chargify::Subscription.create(
  :customer_reference => 'moklett',
  :product_handle => 'chargify-api-ares-test',
  :credit_card_attributes => {
    :first_name => "Michael",
    :last_name => "Klett",
    :expiration_month => 1,
    :expiration_year => 2010,
    :full_number => "1234-1234-1234-1234"
  }
)

subscription.credit_card_attributes = { :expiration_year => 2013 }
subscription.save

subscription.cancel

See the examples directory for more usage examples.

Installation

This library can be installed as a gem. It is hosted on Rubygems.

You can install this library as a gem using the following command:

$ gem install chargify_api_ares

Usage

Simply require this library before you use it:

require 'chargify_api_ares'

If you're using Rails 3.x, you could include this gem in your Gemfile.

gem 'chargify_api_ares'

Install the gem using the following command: $ bundle install

If you're using Rails 2 you could include this gem in your configuration, i.e. in environment.rb

config.gem 'chargify_api_ares'

Now you'll have access to classes the interact with the Chargify API, such as:

  • Chargify::Product
  • Chargify::Customer
  • Chargify::Subscription

Check out the examples in the examples directory. If you're not familiar with how ActiveResource works, you may be interested in some ActiveResource Documentation

chargify_api_ares's People

Contributors

npverni avatar shayfrendt avatar moklett avatar douglasr avatar caffo avatar benhoskings avatar ryansch avatar aeden avatar staugaard avatar cyoungberg avatar infused avatar russolsen avatar scotchi avatar ysiadf avatar jsmestad avatar

Watchers

James Cloos avatar  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.