#thomasst

1 messages · Page 1 of 1 (latest)

turbid parcelBOT
covert valley
#

👋 happy to help

plain hornet
#

Thanks!

covert valley
#

sorry still looking into this

#

so unfortunately you can't really update the Checkout Session metadata after creation, you either need to create a new one or you can update the metadata on the underlying PI

#

once it gets created

plain hornet
#

Thanks, that's a good idea.

#

That would be on the setup_intent or would it have to be on setup_intent.payment_method?

#

Looks like according to the docs it should work on the setup_intent, which I'm assuming is unique on each successful checkout.

timid dew
#

hmm, well it can be either one, it depends where you'd like to find the metadata later

plain hornet
#

I basically want to flag the checkout as been "processed" by my code.

#

so my code doesn't accidentally process a checkout twice

timid dew
#

makes sense, I suppose you could add metadata to the SetupIntent then! not sure why we don't let you update metadata on the CheckoutSession, sorry

plain hornet
#

Yeah especially because the checkout session create docs say "All keys can be unset by posting an empty value to metadata."

#

Implying that I could unset them at some point.

timid dew
#

yeah that's the just the generic description for all metadata fields in the API