#cnguyen-fetch-PIs
1 messages · Page 1 of 1 (latest)
Hey there! When you fetch a PI, there is an invoice hash, which is expandable: https://stripe.com/docs/api/payment_intents/object#payment_intent_object-invoice
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
You can also expand the Subsription related to the invoice.
if there is an invoice, it's a subscription ?
or I have to expand the invoice to check the info?
Well that depends on your integration... if you only use Subs and not one-off invoices then an invoice would indicate a Sub
for now, I check if the description field contains 'subscription'
But to be sure, yes you you can look at the Subscription hash on the invoice
ok so, to be sure, I check the subscription field of the invoice. Right ?