Create inventories

By default, the Inventory API provides a STORE, a SUPPLIER, a BIN, and a SOLD inventory.
When needed, you can create one or more inventories of the STORE inventory type. For example, you can create several STORE inventories for different types of products to differentiate their stocks.

Prerequisites

  • Make sure that authorisation is set up with the following OAuth scope using OAuth API:
    • WRITE:PRODUCT

Create an inventory

For the organization to which the merchant is signed in, use this request to create an inventory of the STORE type:
1
POST /inventories
1
{
2
"name": "The name of the new STORE inventory",
3
"description": "The description of the new STORE inventory"
4
}
Example: This example creates a STORE inventory for the organization associated with the authorization token. In the request header, the token is passed in type Authorization: Bearer eyJraWQiOiIxNjM3MTg1Mjg0Nz....
Request
1
POST /inventories
2
Host: inventory.izettle.com
3
Authorization: Bearer eyJraWQiOiIxNjM3MTg1Mjg0Nz...
1
{
2
"name": "T-shirt with a start print",
3
"description": "The inventory shows the stock balance of T-shirt with a start print."
4
}
Response
After the inventory is created successfully, it can be accessed using the link that is provided in the Location header in the response.
1
Location: https://<Host>/inventories/<inventoryUuid>