#Tiziano
1 messages · Page 1 of 1 (latest)
Can you share exactly what request you're making and what you're looking at?
Example code and request IDs would help me understand whats happening for you
Sure,
when I create the checkout session I put several line_item in the request and some metadata for each line_item. The checkout session is ok and the customer can pay.
In the event log from the dashboard I can see that the metadata is ok from the create endpoint
When I want to know the status about the checkout session and iterating the line_items using the checkout/sessions/{id}/line_items endpoint the metadata array is always empty.
Now i will go to simultate the problem
Req id where I create the session: req_Tc2RNXqsuKOPEY
And what does your retrieval request look like?
Oh, i see, the metadata is in your product_data
you'll need to expand the product to get that
expand=data.price.product
if using the /line_items endpoint
So if I expand the product I can see the metadata in the root of the response?
The result..
NP!
it is slightly misleading since in the creation phase we are not talking about products stuff
You're implicitly creating a product when you supply product_data -- but I can appreciate that that might not be obvious