GitHub - flavioruiz/chargebee-ruby: ChargeBee API client implementation for Ruby

The ruby library for integrating with ChargeBee Recurring Billing and Subscription Management solution.

Installation

Install the latest version of the gem with the following command…

$ sudo gem install chargebee

Documentation

For API reference see apidocs.chargebee.com/docs/api?lang=ruby

Usage

To create a new subscription:

ChargeBee.configure({:api_key => "your_api_key"}, {:site => "your_site"})
result = ChargeBee::Subscription.create({
:id => "sub_KyVqDh__dev__NTn4VZZ1", 
:plan_id => "basic", 
})
subscription = result.subscription
puts "created subscription is #{subscription}"

License

See the LICENSE file.