Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

shipping zone api rest

Solved

shipping zone api rest

haleema
Shopify Partner
4 0 2

how to create a shipping zone api using rest admin api iam trying to hit this url https://api_key:api_secret@test.myshopify.com/admin/api/2022-01/shipping_zones.json and the body as 

{
  "shipping_zone": {
    "name""New Shipping Zone",
    "countries": [
      {
        "code""US"
      }
    ]
    
}
}
but it gives 406 not acceptable error
Accepted Solution (1)

ShopifyDevSup
Shopify Staff
1453 239 531

This is an accepted solution.

Hi @haleema,

 

Currently, you can't edit/create Shipping zones via the REST API but you may want explore delivery profiles via GraphQL as an alternative. 

 

Hope that helps! 

Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

View solution in original post

Replies 2 (2)

ShopifyDevSup
Shopify Staff
1453 239 531

This is an accepted solution.

Hi @haleema,

 

Currently, you can't edit/create Shipping zones via the REST API but you may want explore delivery profiles via GraphQL as an alternative. 

 

Hope that helps! 

Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

haleema
Shopify Partner
4 0 2

hello @ShopifyDevSup  where can i get location group id i need to update a delivery profile by adding multiple zones to a profile 

profile: {
                  locationGroupsToUpdate: {
                    id: {location_group_id},
                  zonesToCreate: [