#Laestry
1 messages · Page 1 of 1 (latest)
hi! to be clear, are you specifically using our Checkout (/v1/checkout/sessions) API for this?
oh yes indeed
well you can a mixture of recurring and one-off line items to Checkout in mode:subscription, that works fine. The one offs are charged as part of the first invoice.
i.e. the cart might look like this
line_items.data.price.recurring
would I change this var?
aaaa
prob this one? line_items.data.price.type
to one_time?
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
well generally you create the Price objects ahead of time and just pass in the IDs
but yes it's the type of the Price indeed
wow thanks! It's just one of the boxes the customer orders can be custom filled with items
ah
so your saying I could create the product ahead of time, but how could I change if it's just one time or recurring?
hmm, well you wouldn't
you would create various Products/Prices in your account, save the IDs to your database, and pass them into the Checkout as needed, for example
thanks so much, weird how it needs the mode: "subscription" seems unnecessary