#kekko7072-metered-billing

1 messages ยท Page 1 of 1 (latest)

steep talon
dusk creek
#

i read but i didnt understand

#

i should create a product? It's no clear to me. How can i bill monthly automatically but with different price?

#

can you explain me the configuration better? Maybe linking videos i use Flutter SDK for front end and Firebase functions as backend +

#

firestore for storing

steep talon
#

We likely don't have videos for your exact environment, but the outline of the steps are:

  1. Create a Product and Price (this step in the doc, which contains code snippets: https://stripe.com/docs/billing/prices-guide#creating-metered-subscription). This is a one-time step and only needs to be completed once for each product.
  2. When creating the subscription, pass in the Price ID from Step 1.
  3. Follow the steps in this section to create usage records which indicate how much a product has been used. https://stripe.com/docs/billing/prices-guide#reporting-usage
  4. At the beginning of the next billing period (unless configured otherwise with thresholds) we will bill based on the provided usage records.
dusk creek
#

clear thankyou so much

#

but how i can add the subscription to the user?

#

i have the customer id is it usefull? how can i can implement the subscription in my code?

steep talon
#

customer is a required parameter when creating a subscription, and it does expect the customer ID to be provided:
https://stripe.com/docs/api/subscriptions/create
https://stripe.com/docs/billing/subscriptions/build-subscription

Create and manage subscriptions to accept recurring payments.

dusk creek
#

grat thankyou so much