#sushbhat-pi
1 messages · Page 1 of 1 (latest)
So we have a generic microservice that creates payment intents for different client applications, when we handle webhook requests we need a way to identify which client application was it to take customized actions
I found that there is a field called 'application' in payment intent, but its only on response object
looking for something like this 'application' attribute while creating the payment intent to set 'application':'clientName'
Can you share an example? Not familiar with that field
and then while webhook processing check application == 'clientName'
application
string
EXPANDABLE "APPLICATION"
CONNECT ONLY
ID of the Connect application that created the PaymentIntent.
just want to know how to set this application while creating paymentIntetn
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 don't set that field, it's computed from other parameters you pass when creating the PI (depending on what kind of Connect charges you're making)
Do you have an example pi_xxx ID I can look at
Correct, that's expected. You're not using Connect?
no, what is connect?
It facilitates multi-party payments. The fields you're referencing is only applicable if you're using Connect
In any case, you should just set metadata on the PI: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-metadata
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
ok got it..
also
we need to use the charges object inside the payment intent to get metda data?
Nope, it'll be on the Payment Intent object