#green-node-expand
1 messages · Page 1 of 1 (latest)
hi, sorry i accidently sent it before adding image lol
Webhooks never expand by default
You have to re-retrieve the object after you receive the Event in your webhook endpoint and it expand it when you retrieve it
i did re-retrieve it, i think
i read that it said re-retrieve it inside the webhook handler, so i'm not sure why it isn't expanding now
Ah okay you are trying to use list line items there instead of retrieving the Session itself. You don't expand with that endpoint
You would use https://stripe.com/docs/api/checkout/sessions/retrieve and then expand line_items.data.price.product
this still isn't working, is the expand one of the options parameters? , should it be in the same object as stripeAccount?
Yes it would be same object as stripeAccount. Sorry, didn't notice above that you had it separated.
still doesn't work, and i put it my clientside one and got this warning
(node:84058) Stripe: Invalid options found (expand); ignoring.
What does "doesn't work" mean exactly. You aren't seeing line_items at all when you retrieve the Session?
yeh, i'm not seeing line_items at all after i put them inside same object as stripeAccount
Can you provide the exact code snippet you are using to retrieve here?
Err doh so sorry. You were right the first time. Expand is an argument and stripeAccount goes within the options object. So they should be separated.