I have one Stripe Customer, that attached to many companies into my project. Every company has its own subscription. So one Customer has many Subscriptions.
But during manage subscriptions on Customer Portal page I want to see just one subscription related to company (for now I see all Subscriptions related to the Customer).
Is there way (param) to show just one subscription related to specific Company (maybe by its ID) on Customer Portal page?
It's not possible right now to restrict the subscriptions managed in a Customer Portal session. You pass the customer parameter on creation and all subscriptions associated to that Customer object are manageable.
Related
Is there any way to show active subscription plan on stripe's embeddable table, like passing customer, subscription or price id?
https://stripe.com/docs/payments/checkout/pricing-table
How on client side, where stripe pricing table is used, can be prevented for user/customer to select another (or same) plan and do any sort of action except updating current plan with upgrade or downgrade?
The pricing table product is built for first time purchases and it allows you to easily drop an iframe on your webpage that shows the different price options that you offer to your new customers. Once you have a Customer that has already made a purchase, the pricing table product is not what should be used.
Instead, separately, you can let your existing customers manage their subscriptions with the Customer Portal here which has a full Stripe redirect page. You can pass the list of Price ids when creating the portal configuration so your customers are able to upgrade or downgrade to different prices.
So in my use case, I have a service that I provide to some companies. Those companies each have several employees who are responsible for purchasing subscriptions to my service via Stripe. Instead of creating accounts for each of the employees, I'd like to have a single account per company/organization, so any employee with enough permissions could purchase a subscription. And all of the subscriptions will be linked to company accounts, not to personal ones.
I would appreciate it if someone tells me if this flow possible?
Using Node.js
I got a question with the flow of the API.
My web app allows users to use the site for free but gives them a choice to "subscribe" to other users and view their premium content which charges them monthly.
Looking at the stripe API, to add a subscription to a user, I would need customer object. Would the proper flow of this be:
User signs up and in the backend, create a stripe customer for said user and save the id into my user object database.
When user subscribes to another user, grab their customer id from the database and create the subscription.
Also side question, does this allow for multiple subscriptions of the same product? Because a user can subscribe to multiple users
Thanks!
Your understanding of Customers sounds correct; you collect a user's credit card details, create a Customer object, then using that id, sign the Customer up for a Subscription.
With a Stripe Subscription you can use quantity or have multiple subscription items attached to a single Subscription. So if the user already has an active subscription, you could grab this and increase the quantity or add a second plan.
e.g. you could bill a user for Plan A and Plan B on a single Subscription, or 2 x Plan A, etc
see:
https://stripe.com/docs/api/subscription_items/create#create_subscription_item-quantity
https://stripe.com/docs/api/subscription_items/create
I am planning on integrating stripe into our application. There is a requirement to add multiple subscriptions for a customer (which looks to be possible with stripe). However, after looking at their API, I can't find a way to set which payment method will be used with each subscription. We want to enable a customer to choose two different methods for each of their subscriptions. Looking at the stripe API docs however, it seems that all subscriptions are billed to the default source on the customer. I can't find any way to specify that a specific subscription be billed to a specific payment method...
It is a current limitation of Stripe's API that subscriptions are always billed to the customer's default payment source. If you want to have multiple subscriptions billed to different sources, you'd need to have multiple customer objects, each with a different payment method as its default source, and create the subscriptions on the appropriate customer objects.
EDIT: The above is no longer true! You can now use different sources for different subscriptions, using the default_source parameter.
You can set the default_source of your subscription.
https://stripe.com/docs/api/subscriptions/object
default_source:
ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If not set, defaults to the customer’s default source.
When creating a subscription the customer can see the "name" of the subscription.
Is there a way to display additional information for each subscription in the subscription panel of the customers wallet?
Right now if the subscribe to multiple services they can not distinguish the subscription by name only.