#jinx-checkout-shipping

1 messages · Page 1 of 1 (latest)

nimble forumBOT
fresh flare
#

jinx-checkout-shipping

#

hey @queen ibex can you share your exact code?

queen ibex
#

Sure! It's just a simple json request.

Key: shipping_address_collection[allowed_countries] Value: US

fresh flare
#

what does that mean "a simple json request"

queen ibex
fresh flare
#

our API doesn't support JSON

#

so I'm asking if you can share real code that I can help you with

#

or explain how you make our request

#

cc @queen ibex

queen ibex
#

My API Call is a curl but formatted as a json post.

-d "shipping_address_collection[allowed_countries]"=US

fresh flare
#

gotcha so allowed_countries is an array. So it should be -d "shipping_address_collection[allowed_countries][0]"=US

queen ibex
#

Awesome! It worked. Thanks man!

fresh flare
#

yay!

queen ibex
#

Oh btw How can I make multiple allowed countries?

fresh flare
#

you pass the same thing, it's an array, you just change the index -d "shipping_address_collection[allowed_countries][0]"=US -d "shipping_address_collection[allowed_countries][1]"=FR -d "shipping_address_collection[allowed_countries][2]"=CA ...

queen ibex
#

I see. Anyway I can just allow all countries at once?

next compass
#

Hi 👋 I'm stepping in. No you need to specify each country you plan to collect shipping address information from.