Rdocumentation
powered by
Learn R Programming
RStripe (version 0.1)
stripe_create_subscription: Create a Subscription
Description
Create a new subscription for a customer and add it to them.
Usage
stripe_create_subscription(api_key, customer_id, args)
Arguments
api_key
Your Stripe API Key
customer_id
The customer id you want to add a subscription to.
args
A list which includes:
plan
required
The plan id
coupon
optional
A coupon to apply to this subscription.
trial_end
optional
When the trial ends. Unix timestamp to override plan. You can use
now
to make it end now.
card
optional
A token or card dictionary to use instead of default.
required
if customer has no card.
quantity
optional
Quantity to place in subscription.
application_fee_percent
optional
A decimal 1 to 100 for percentage of amount.
metadata
optional
A list which can contain anything to further describe.
Value
A data frame with the new subscription info if successful.