#sateeshmadagoni_63774

1 messages · Page 1 of 1 (latest)

umbral jacinthBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

hoary wigeon
#

subscription_data: { metadata: { plan_type: planType, billing_period: billingPeriod, organization_id: req.organization._id, }, },

grizzled jackal
#

Which metadata parameter(s) are you using on your Checkout Session creation?

hoary wigeon
#

This is always empty.

grizzled jackal
#

Can you paste either the evt_xxx ID or that sub_xxx ID

hoary wigeon
#

sub_1OUpaXE4YflY2cbLL8QWN6a5

grizzled jackal
#

I don't see the subscription_data[metadata] parameter in your request

umbral jacinthBOT
hoary wigeon
#

But I am adding it like this
mode: "subscription", cancel_url: ${process.env.APP_URL}/, success_url: ${process.env.APP_URL}/payment-success?checkoutId={CHECKOUT_SESSION_ID}, metadata: { plan_type: planType, billing_period: billingPeriod, organization_id: req.organization._id, }, subscription_data: { metadata: { plan_type: planType, billing_period: billingPeriod, organization_id: req.organization._id, }, },

#

Do I have to stringify it ?

#

Ok my bad! the values were empty.

grizzled jackal
#

Yep, the SDK will remove any nullish values from the payload

hoary wigeon
#

So this values will be carried for every payment for that subscription right ?

grizzled jackal
#

The subscription_details[metadata] field on the invoice will be a snapshot of key/values on the subscription at the time the invoice is generated, yes

frail agate