#pitcherojbh
1 messages ยท Page 1 of 1 (latest)
Hi ๐ that is expected behavior. Metadata is not automatically copied from one object to other objects. You will need to manually make requests to copy that data if that is something that is required. Otherwise you'll need to have a path to get from the object you're investigating to the related object with the metadata you want to see.
What type of object are you looking at as the "payment"?
It is a subscription payemtn, we need to specify in the meta data the fees we charge for our Express accounts
How can I specify these in a subscription?
What type of object are you looking at as the "payment"? <-- what do you mean by this sorry,
I'm not sure I'm grasping the question here. I got the impression you are already passing metadata to your Subscriptions.
Within Stripe there are multiple objects involved with making a payment, I'm trying to figure out which type you're looking at when you were looking for the metadata but didn't find it. Subscriptions will create Invoices for each payment, which will create a Payment Intent, which then creates a Charge.
If you're looking at the Invoice, you may already be able to find the Subscription's metadata via subscription_details.metadata:
https://stripe.com/docs/api/invoices/object#invoice_object-subscription_details
but if you're looking at a different object type, you'll need to retrieve additional items to find the associated 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.
Ah ok, so I am using CreateSubscriptionRequest I can see the meta data and the application fee on the subscription. This application fee is just showing as text on the meta data fields.
But I can not see this application fee or the meta data on the invocie that is raised
What do you see in the subscription_details.metadata field on the Invoice?
Can you share the ID of an Invoice you're looking at?
yes it is in_0NyDjkNRNK7sFw4mg36WzqkS
payment id is pi_2NyDjkNRNK7sFw4m1EycUJxg
The subscription is sub_0NyDjkNRNK7sFw4mJwJUQd1m
How are you checking the subscription_details.metadata field on the Invoice object? It looks like that is populated with the metadata from the Subscription object.
From the dashboard, ah is it visible form the API?
Yeah. We aren't too familiar with the dashboard in this forum, we primarily focus on working with the API.
How can I see the Pitchero Application Fee that we add form the meta data
if you check this payment, pi_2NxtP9NRNK7sFw4m1atYumMM you should see what I mena
*mean
I will check the API responses now
We use this value to tell Stripe how much to charge the customer
That metadata won't be on the Payment Intent. It will be on the Subscription where you originally put it, and on the Invoices created by that Subscription in their subscription_details.metadata hash.
Ok so providing it is on there still, the fees will be correct?
I don't know what you mean by that, would you mind trying to clarify? metadata does not impact the fees that are charged. I don't understand whether you're currenlty expecting metadata to adjust fee amounts, or if you're passing fee details through metadata so you can charge those later at a different part of your flow.