#johnnylivettv
1 messages ยท Page 1 of 1 (latest)
There's some support for think via Checkout/PaymentLink flows, but in your own UI flows you'd need to look up the customer and check for subscriptions
You can use the Search API to get all customers with a case-insensitive email match:
https://stripe.com/docs/search#query-fields-for-customers
okay yeah so no one query i twould have to be multiple
Assuming you de-dupe similarly, there should only ever be zero or one
get all customers with said email address loop through each active sub
and count essentialyl
yeah that is exactly how i dedupe!
then you'd list their subscriptions:
https://stripe.com/docs/api/subscriptions/list?lang=curl#list_subscriptions-customer
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Hmm actually you can use expansion via Search if you attach a query parameter:
https://api.stripe.com/v1/customers/search?expand[]=data.subscriptions
So that should work via the SDKs too, allowing a one-shot
YOu'd get the customer search results back with the subscriptions included, if present
NP!
๐ anything else we can help with?
nope all good thanks ๐