How the country list works
A resource’s availability is itscountries field: an array of ISO-2 country codes.
countries array means unrestricted: the resource is available in every country the store sells in. A non-empty array limits it to exactly those countries.
Set a resource’s countries
Write availability withcountry_isos on a company create or update. It becomes the countries field you read back.
- An empty array clears the limit.
"country_isos": []makes the resource available everywhere the store sells. - Leaving the key out changes nothing. Updates change only what you send, so you can edit other fields without touching availability.
Read a resource’s countries
countries is on every response for these resources, public and company alike. Use the company show request to read it for a resource in any state:
Filter a list by country
Passfilter[country] with an ISO-2 code to list what’s available in one country. It works on public and company lists:
filter[country], a list isn’t narrowed by country at all. Countries never affect a public slug lookup.
Products
Products have nocountries field. Each variant carries the countries it’s sold in, and a product is available wherever at least one of its variants is.
To read products for one country, pass country rather than filter[country]:
country the store doesn’t sell in falls back to the store’s default country. On the company list, it returns 422.
Next steps
- Visibility, drafts, and scheduling — the rest of what decides whether a resource shows.
- Find and create resources — set
country_isoswhen you create a resource.