POST Orders request returning 403 despite sufficient permissions

POST Orders request returning 403 despite sufficient permissions

AlexeyKhimich
New Member
5 0 0

I am developing a custom app intended to be used exclusively for my store to automatically create orders based on input data. The necessary permissions (read_orders and write_orders) have been granted. POST requests to another elevated permissions endpoints (POST Products and even GET Orders) return as expected, creating a product and returning a list of orders respectively. However, trying to make a POST Orders request with valid headers (content-type and x-shopify-access-token set to "application/json" and my access token respectively) always returns a 403 with a following body

{
  "errors": "Service is unavailable."
}

The error message indicates a problem on the Shopify side, however in such case I'd expect the error code to be in the 5xx range.

 

Thank you in advance.

Replies 3 (3)

ShopifyDevSup
Shopify Staff
1453 238 508

Hey @AlexeyKhimich

 

There can be a few reasons why you are seeing 'service unavailable' but in order to confirm, we would need an X-Request-ID from your response headers in order to look at the logs. 

 

Are you able to send us one that is within the last 7 days?

 

Thanks,

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

AlexeyKhimich
New Member
5 0 0

I have solved the problem. The shop that had been used for testing had no active Shopify subscription, and I was therefore not allowed to create any orders. Still, I would kindly ask you to make the error message clearer and more understandable for the end user.

ShopifyDevSup
Shopify Staff
1453 238 508

Glad it was resolved! I'll be sure to let the product team know that it would be valuable to have a more detailed error message.

 

Thanks for your feedback!

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