#Linas
1 messages ยท Page 1 of 1 (latest)
Hello ๐
What kind of object / event are you looking at?
The refund object should have the reason (if one was provided)
https://stripe.com/docs/api/refunds/object#refund_object-reason
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
but the webhook itselft do not have it. So, i guess, i have to make additional call and retrieve refund object?
Do you have the event ID handy so I can take a look?
POST /v1/charges/ch_3MU5IL2WxmpWlx1M1rOJNUXP/refund
not sure, where exact is event id. i copied from stripe
Oh that's the request to create a refund, you said you're looking at webhook event?
oh, webhook event id: evt_3MU5hp2WxmpWlx1M0vhFwLcL
it shows only type: +"reason": "requested_by_customer"
but it doesnt show, text ,which i have entered during refund.
Ah I believe thats expected. The additional text might only be available via Dashboard
ok, then i will ask from another side: We charge user for 3 items, using line_items: item1, item2, item3. Lets imagine, customer asks for refund, but only for item2.
What would be best practice to handle it ? and how i can recognize from webhooks, that refund for item2 was made ?
somehow i need to automate that for product fulfilment and affiliate traking.
If you're using the API to create refunds then you can use the metadata property to store that information. Don't think there is a great way to handle this via the dashboard unfortunately.
no, refunds are made via Stripe admin panel.
i thought, that i could write product name in the reason. But that doesnt work as expected.
Ah yeah, sorry thats a dashboard only feature at the moment