#avpsolution-subscription-metadata
1 messages ยท Page 1 of 1 (latest)
Hey ๐ just to clarify, are you attempting to update a checkout session, or are you trying to set the subscription_data.metadata when you create the session?
Trying to add subscription_data.metadata while creating a session.
Gotcha, and are you receiving any sort of an error?
not really, didn't catch any error so far
Do you have the request ID for a one of these requests (req_123)?
When I checked the logs on the server the Request POST body was not showing subscription_data.metadata
req_hPEOU2SRTuwVCT request Id
Thanks, bear with me while I dig into that.
Checkout session object
Looking at that request I don't see any subscription_data being passed in. Looking at your snippet, it also looks like the user_feature isn't being entered as a string.
Gotcha, bear with me while I run through a test case in my account.
Hm, it seemed to work on my end. Would it be possible to replace UserFeature.getStripeMetaData() with a hard coded string such as 'test_value' to see if that works?
Additionally, can you share any insight on what you expect that function to return?
ok, so whenever I tried to pass nested JSON object as value of metadata tag it didn't work.
It works absolutely perfect with a plain JSON object.
in short, I must not use nested JSON objects
๐
Ah, gotcha, yeah our metadata objects only support string values.
Thanks for the help and double-checking stuff for me on your side.
This resolves my problem thanks again.
๐ glad to hear, and best of luck on the rest of your project!