Stock | Warehouses

A warehouse is a place where products are stored. Information about the warehouses is necessary for the functioning of the platform. Information about the warehouse will be visible to the customer on the fronted ONe platform. Multiple warehouses can be assigned. Later, products and their stock quantity will be assigned to the created warehouses.
In the ONE system through the integration API it is possible to create and update warehouses.

Table of contents

Glossary

Name
Explanation
id
required field, warehouse identifier, used to communicate with API
label
only descriptive meaning, used in front, if empty: name will be used
name
this is the name that will be displayed to customers on the fronted of the platform
parent
identifier of parent CENTRAL warehouse, valid only for LOCAL warehouse
pickupPoint
flag indicating whether the goods can be picked up from a given warehouse
reservation
flag indicating whether the goods can be reserved from a given warehouse. Reservation of products on a sales order means that after placing an order, the amount of available products is reduced by the amount of products from the order. The reserved quantity is visible on the created sales order in the Reserved Quantity column. It is possible to reservation of goods for the customer in the backoffice. For more information on how to do this via backkoffice check here
reservationTime
reservation time in hours, required when reservation is true. The reservation time is valid for reservations on the shopping cart. Time is not a parameter that determines the validity of a reservation on a sales order. Time is given in hours
shippingTime
shipping time for the warehouse (in hours, eg. 24 means 1 day/24 hours)
supported
flag indicating whether the warehouse supports sales from ONe
type
required field, specifying whether the warehouse is local or central Listing: "CENTRAL" "LOCAL”
address: TIN type firstName lastName companyName zip city street number apartment country phone latitude longitude additionalInfo
tax Identification Number the field specifies whether the address is personal or whether it is a company (enum: "PERSONAL" "COMPANY") first name of the contact person for the address (for personal address) last name of the contact person for the address (for personal address) name of company (for company address) zip of addres city of addres street of addres number of addres apartament of addres country of addres phone of addres geographic latitude geographic longitude additional information that will appear only on the backoffice (the client will not see it)

PUT - create or update warehouse with given id

As previously mentioned, the warehouse can only be created via API in an external system (eg ERP). The warehouse can be updated via an external system as well as on the ONe platform
⚠️
Important! In the settings in the backoffice (Configurations → Warehouses) you can edit whole information except warehouseId
The diagram below shows the dependency of communicating with the API when warehouse was created or update in external system:
Image without caption
Use PUT /api/v1/account/integrations/auth-required/warehouses to create / update the warehouse. Then you need in request put the following data:
  • id
  • name
  • type
Providing other information as in the example below is not required, but it is worth completing during creation the warehouse.
⚠️
All information provided during the creation of the warehouse should be included in the content in order to update the information
Example request
json
curl -X PUT "https://api-preprod.one.unity.pl/api/v1/stock/integrations/auth-required/warehouses" -H "accept: */*" -H "one-tenant: {tenant}" -H "ApiAuth: {apiKey}" -H "Content-Type: application/json" -d "{ "id": "WRO", -- required "label": "Wrocław warehouse", "name": "Wrocław", -- required "parent": null, "pickupPoint": true, "reservation": true, "reservationTime": 3, "shippingTime": 24, "supported": true, "type": "CENTRAL", -- required "address": { "TIN": "111111111", "type": "COMPANY", "firstName": null, "lastName": null, "companyName": "Speedimex", "zip": "54-045", "city": "Wrocław", "street": "Międzyleska", "number": "25", "apartment": null, "country": "Polska", "phone": "111111111", "latitude": 51.079923, "longitude": 17.068543, "additionalInfo": "Warehouse operated by a third party" } }"

Powered by Notaku