> For the complete documentation index, see [llms.txt](https://docs.xorosoft.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.xorosoft.com/developers-api/inventory-management/update-inventory.md).

# Update Inventory

It is used to update the inventory by using request format.

| Field          | Data Type | Default Value | Description                                                                                                                                                                          |
| -------------- | --------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `ItemNumber`   | string    | NA            | SKU number.                                                                                                                                                                          |
| `DeltaQty`     | decimal   | 0             | Instead of sending a new and old value for inventory an adjustment value can be sent.                                                                                                |
| `OldQty`       | decimal   | 0             | The original stock level that the client believes the product variant has. This should be sent to avoid a race condition when the item being adjusted is simultaneously sold online. |
| `NewQty`       | decimal   | 0             | The number of items in stock for this product variant.                                                                                                                               |
| `LocationDisp` | string    | NA            | Warehouse 3PL location (Provided by the client).                                                                                                                                     |

Note: If New/Old Qty and Delta Qty are both provided then New/Old Qty will take priority and Delta Qty will be ignored.

```json
{"openapi":"3.0.3","info":{"title":"Xorosoft ERP Public API","version":"2026.07"},"tags":[{"name":"Inventory Management","description":"Use Inventory Management APIs to read and update stock availability across stores, warehouses, locations, items, products, and inventory qualities. These endpoints are typically used by commerce channels, warehouse tools, 3PL integrations, and replenishment workflows that need current on-hand, allocated, available, and not-available quantities. Write operations should be used carefully because they can affect fulfillment and accounting downstream."}],"servers":[{"url":"https://res.xorosoft.io","description":"Xorosoft ERP API server"}],"security":[{"basic":[]}],"components":{"securitySchemes":{"basic":{"scheme":"basic","type":"http"}}},"paths":{"/api/xerp/inventory/updateinventory":{"post":{"responses":{"200":{"content":{"application/json":{"schema":{"properties":{"Data":{"type":"string"},"IsForwardRequest":{"type":"boolean"},"Message":{"type":"string"},"MessageTitle":{"type":"string","nullable":true},"Result":{"type":"boolean"}},"type":"object"}}},"description":"OK","headers":{}}},"tags":["Inventory Management"],"description":"It is used to update the inventory by using request format.\nField               |Data Type          |Default Value          |Description\n-------------------|-------------------|-------------------|--------------\n``ItemNumber``|string|NA|SKU number.\n``DeltaQty``|decimal|0|Instead of sending a new and old value for inventory an adjustment value can be sent.\n``OldQty ``|decimal|0|The original stock level that the client believes the product variant has. This should be sent to avoid a race condition when the item being adjusted is simultaneously sold online.\n``NewQty``|decimal|0|The number of items in stock for this product variant.\n``LocationDisp``|string|NA|Warehouse 3PL location (Provided by the client).\n\nNote: If New/Old Qty and Delta Qty are both provided then New/Old Qty will take priority and Delta Qty will be ignored.","operationId":"post_inventory_updateinventory","requestBody":{"content":{"application/json":{"schema":{"properties":{"DeltaQty":{"type":"number"},"ItemNumber":{"type":"string"},"LocationDisp":{"type":"string"},"NewQty":{"type":"number"},"OldQty":{"type":"number"}},"type":"object"}}}},"summary":"Update Inventory"}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.xorosoft.com/developers-api/inventory-management/update-inventory.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
