Chargebee's APIs Are Intuitive and Efficient
Chargebee helps you solve all the complexities involved in recurring billing effortlessly.
Work with our robust set of APIs to build recurring genius, and remarkable experiences, right inside your app.
One of our product experts will be reaching out to you to discuss your subscription billing needs
Skip the queue and directly book a demo with our product experts.
Chargebee helps you solve all the complexities involved in recurring billing effortlessly.
Work with our robust set of APIs to build recurring genius, and remarkable experiences, right inside your app.
/*
creates a subscription with customer information and billing details.
*/
require 'chargebee'
ChargeBee.configure(:site => "{site}",
:api_key => "{site_api_key}")
result = ChargeBee::Subscription.create({
:plan_id => "no_trial",
:auto_collection => "off",
:billing_address => {
:first_name => "John",
:last_name => "Doe",
:line1 => "PO Box 9999",
:city => "Walnut",
:state => "California",
:zip => "91789",
:country => "US"
},
:customer => {
:first_name => "John",
:last_name => "Doe",
:email => "john@user.com"
}
})
subscription = result.subscription
customer = result.customer
card = result.card
invoice = result.invoice
unbilled_charges = result.unbilled_charges
# creates a subscription with customer information and billing details.
curl https://{site}.chargebee.com/api/v2/subscriptions \
-u {site_api_key}:\
-d plan_id="no_trial" \
-d auto_collection="off" \
-d customer[first_name]="John" \
-d customer[last_name]="Doe" \
-d customer[email]="john@user.com" \
-d billing_address[first_name]="John" \
-d billing_address[last_name]="Doe" \
-d billing_address[line1]="PO Box 9999" \
-d billing_address[city]="Walnut" \
-d billing_address[state]="California" \
-d billing_address[zip]="91789" \
-d billing_address[country]="US"
/*
creates a subscription with customer information and billing details.
*/
Environment.configure("{site}","{site_api_key}");
Result result = Subscription.create()
.planId("no_trial")
.autoCollection(AutoCollection.OFF)
.customerFirstName("John")
.customerLastName("Doe")
.customerEmail("john@user.com")
.billingAddressFirstName("John")
.billingAddressLastName("Doe")
.billingAddressLine1("PO Box 9999")
.billingAddressCity("Walnut")
.billingAddressState("California")
.billingAddressZip("91789")
.billingAddressCountry("US")
.request();
Subscription subscription = result.subscription();
Customer customer = result.customer();
Card card = result.card();
Invoice invoice = result.invoice();
UnbilledCharge unbilledCharges = result.unbilledCharges();
/*
creates a subscription with customer information and billing details.
*/
require 'ChargeBee.php';
ChargeBee_Environment::configure("{site}","{site_api_key}");
$result = ChargeBee_Subscription::create(array(
"planId" => "no_trial",
"autoCollection" => "off",
"billingAddress" => array(
"firstName" => "John",
"lastName" => "Doe",
"line1" => "PO Box 9999",
"city" => "Walnut",
"state" => "California",
"zip" => "91789",
"country" => "US"
),
"customer" => array(
"firstName" => "John",
"lastName" => "Doe",
"email" => "john@user.com"
)
));
$subscription = $result->subscription();
$customer = $result->customer();
$card = $result->card();
$invoice = $result->invoice();
$unbilledCharges = $result->unbilledCharges();
We have a dedicated team that helps migrate all your subscription data securely. Zero hassle and workarounds.
No more running between systems to put out fires, you will have 24*7 access to our support from the app.