#Shaun - Product names
1 messages · Page 1 of 1 (latest)
I think I figured it out 🤦♂️ stripe.product.retrieve(it.product)
I was trying stripe.products for way too long
Is that correct?
hmm don't think that worked
No, I don't think this is possible. Could you share more details on what you're trying to achieve?
const price = await stripe.prices.retrieve(priceID)
const product = // .... ?
console.log(`Product name ${product.name}`)
I need to retrieve a prices product (fill in line #2)
Just to clarify, are you using the Node SDK?
I think this is what you're looking for:
limit: 3,
});```
I don't want to list products
I have a price, and I want to retrieve the price's product.
This works, but it gives compiler warnings, but it will suffice.
const product = await stripe.products.retrieve(it.product)
return {id: it.id, name: product.name, price: it.unit_amount}
what warning are you getting, what it.product exactly?