API call getting 404 Error back

Topic summary

API POST to inventory_levels/adjust.json returns 404 Not Found when adjusting inventory levels. Original request included location_id, inventory_item_id, and available_adjustment and had worked until the prior day.

Suggested troubleshooting: 404 typically indicates a resource can’t be found (e.g., an ID not accessible). Verify IDs via GET requests to InventoryItem and InventoryLevel endpoints. Capture and share the full request and the x-request-id response header for deeper review.

Outcome for the original reporter: issue resolved by correcting an incorrect inventory location_id.

Ongoing issue: another user still receives 404 on POST admin/api/2023-10/inventory_levels/adjust.json with provided IDs. They shared X-Request-ID: 8c640015-66a6-4b4f-9df1-13765abcf38f and body with location_id 62358323267, inventory_item_id 42269704028227, available_adjustment 1.

Current status: partially resolved. One case fixed (bad location_id); the second case awaits further investigation with the provided x-request-id and payload. No final resolution or changes confirmed beyond ID validation guidance.

Summarized with AI on January 7. AI used: gpt-5.

Hello, When using API call to adjust inventory, the call received 404 error back.

API:inventory_levels/adjust.json

Path : https://c2f650ca0a99f8ce68a3a247c4f815fc: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@developermk.myshopify.com/admin/api/2021-04/inventory_levels/adjust.json

Post content: {“location_id”: 61929390243,“inventory_item_id”: 43914601693347,“available_adjustment”: 1000}

The code worked until yesterday.

Please help!

Thanks.

Hey @YaoWu ,

Generally a 404 error presents itself when a specific resource can’t be found - 404 Not Found - often related to an id that is no longer accessible. There are many moving parts when it comes to inventory management with the API, as outlined in our docs here. Generally, I would suggest troubleshooting start by using a GET request to the InventoryItem and or InventoryLevel resources to confirm the ids are valid, are indeed found and accurate.

From there, if you are still facing an issue of unexpected 404 errors, please log the full request body, and the x-request-id response header returned with the error and share them here. I can take closer look and pass on any insights or next steps from there - Cheers!

Thank you for your reply. We have figured out the cause of the problem, which is incorrect inventory location ID.

hi @awwdam :
I’m facing same issue, but both my locationId and Inventory item id is correct, but still getting not found error 404 on adjust inventory
URL: admin/api/2023-10/inventory_levels/adjust.json (POST)

X-Request-ID: 8c640015-66a6-4b4f-9df1-13765abcf38f

Body:

{
“location_id”: 62358323267,
“inventory_item_id”: 42269704028227,
“available_adjustment”: 1
}

Response: 404

{
“errors”: “Not Found”
}