#L0rdandBooz

1 messages · Page 1 of 1 (latest)

gritty grailBOT
desert jasper
#

Hi, yes. Happy to help with technical questions.

halcyon herald
#

I'm trying to setup my products issuing spending controls and am having trouble with the allowed / blocked categories section. It won't allow me to set it back to an empty array so all categories would be permitted to spend.

Here's the documentation I'm looking at: https://stripe.com/docs/issuing/controls/spending-controls

Here's the code: const updateMcc = await stripe.issuing.cards.update(
req.body.id,
{
spending_controls:{allowed_categories: req.body.formattedArray},
},
{stripeAccount: req.body.connectAccountID}
);

when formatted array is set to empty and passed to the api it keeps it to whatever values it already had.

desert jasper
halcyon herald
#

yes standby plesae

#

alrighty here it is req_VJpaFlIuW4t0bO

desert jasper
#

I tested this on my end, and it appears this is expected and you cannot unset this.

halcyon herald
#

So how do I make it to where all categories are allowed? aside from submitting a 300 item long array?

#

Dang that's really weird

#

thank you for checking on it for me though

desert jasper
#

@halcyon herald - I just tested this again and it's working like you expect it. Instead of passing an empty array, you'd need to pass an empty string to accomplish this.

halcyon herald
#

oh that makes sense. thank you

#

thank you so much

desert jasper
#

Happy to help!

halcyon herald
#

Seriously saved me so much time