#mpv

1 messages · Page 1 of 1 (latest)

glossy hillBOT
grave dune
unborn quarry
#

Huh, didn't actually expect (want) a solution that only works for checkout. To get the promo code used for any subscription would the best solution be to fetch the first invoice of a subscription and expand out the data.discount.promotion_code? Ruby code would look something like this: Stripe::Invoice.list(subscription:"sub_someid", limit: 1, expand: ['data.discount.promotion_code'])