#benstjohn
1 messages ยท Page 1 of 1 (latest)
Hi there ๐ it may be that the metadata you're referring to in the Dashboard is being shown for a different object than the Disputes you're viewing with the API.
Are you setting metadata on the Dispute object, and then not seeing that when you retrieve the object later?
well are not the ones actually "disputing" the charge - I'm assuming that would be the customer, right?
We want the meta data on the associated purchase
that is being disputed. And the dashboard seems to have access to that info
is there a way to get the charge data without spamming the Stripe API with one extra "call" to Stripe for every item in the dispute object?
And would we get hit by any rate limiting issue if we did that?
Gotcha, so it does sound like you're interested in metadata from a different object, metadata is not automatically copied from object to object.
You will likely want to use expand to retrieve the inline objects with the Dispute in a single request:
https://stripe.com/docs/api/expanding_objects?lang=php
Do you know what object holds the metadata you're looking for, is it the Payment Intent associated with the Dispute?
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
I think I can get it with the charge_id
but half of our payments are from payment intents
and the other are just normal charges
so would that be an issue?
How would I expand only the charge from the dispute?
or would the dispute always show the charge, even if the charge exists inside of a payment intent?
I'm not sure offhand, but I think it may always include the Charge and would recommend testing that. If the data you're looking for is split across Charges and Payment Intents, then I would recommend expanding both the charge and payment_intent fields on the Dispute object, but please let me know if that doesn't get you to the data you're looking for.