Inventory levels - Error (406) Not Acceptable

Solved
rcorona
New Member
3 0 0

Hi,

I am trying to update the available for a product with:

https://.../arcaecologica.myshopify.com/admin/api/2021-04/inventory_levels/adjust.json

with this payload in the request:

payload = {
"location_id": 62715035846,
"inventory_item_id": 42177144160454,
"available": 290
}

I receive like response a statuscode: 406 and a the following message: Not Acceptable

Please, I need to know how to solve this problem, it's very important for me to update the stocks of the products via api.

Regards.

 

 

 

0 Likes
rcorona
New Member
3 0 0

About my problem 406, I add x-request-id codes in the response object:

'X-Request-ID': 'cf0bad4e-94e6-4127-bbdb-cf83d30895c3'

X-Request-ID': '11fac569-5efc-4b3b-b299-c2ea2fa0afdb

X-Request-ID': 'f8863d1c-4876-4cbb-b850-52ff2694cbbc

 

Regards

0 Likes
awwdam
Shopify Staff
Shopify Staff
93 10 4

This is an accepted solution.

Hey @rcorona, took a closer look for you here and it appears you are using the PUT method, when POST should be used. Feel free to look through our docs here for reference!

- Cheers

awwdam | API Support @ Shopify
- Was my reply helpful? Click Like to let me 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

0 Likes
rcorona
New Member
3 0 0

Thanks!!! It was the problem!!

0 Likes