The work with API is fulfilled in accordance with the API work rules. API-methods of Warehouse section are used for integration.
To register and configure the warehouse system you need to use method POST /api/v5/integration-modules/{code}/edit. If the module with {code}
code already exists, the method changes it’s settings, otherwise a new warehouse integration module is created. You can see the current module configuration using method GET /api/v5/integration-modules/{code}.
When registering the system you need to specify integrationModule[name]
, integrationModule[code]
, integrationModule[baseUrl]
and customer ID integrationModule[clientId]
. clientId
is needed to identify the user in the warehouse system when making callback-requests. You can also specify the warehouse system logo integrationModule[logo]
, that will be displayed in integration list of Marketplace section.
To activate callback-methods you need to transfer settings of the desired callback-method in integrationModule[integrations][store][actions]
. You need to specify code
, url
for each method. The request address will be compiled from integrationModule[baseUrl]
of basic configuration and the url
of the specific method.
Available callback-methods are shown below.
To configure leftovers loading in method POST /api/v5/integration-modules/{code}/edit you need to specify code of the method inventoriesUpload
in integrationModule[integrations][store][actions]
. Also you need to specify integrationModule[integrations][store][actions][][callPoints]
, in which the request will be initiated:
onReserve
- by opening of product reservation window in the order
onOrderProductList
- by opening item selection window in the order
onProduct
- by entering the order card
The method GET /api/v5/store/inventories allows to get information about leftovres and cost prices for sales propositions. The information about leftovers and cost prices is returned for each sales proposition in terms of warehouses.
The method POST /api/v5/store/inventories/upload allows to update leftovers and cost prices for sales propositions in warehouses. The method can be used as for instant update of a small pile of leftovers, as well as for periodical update of leftovers in the whole catalogue. In the last case you need to transfer leftovers by portions of not more than 250 sales propositions per request till complete catalogue is updated.
The callback-method POST {configuration["actions"]["inventoriesUpload"]["url"]} allows to update leftovers and cost prices in warehouses for sales propositions. To use the method you need to register the warehouse system through API. The call of the method is initiated by the system when making definite actions, that can be set by warehouse system configuration.
The method GET /api/v5/store/product-groups allows you to get list of item groups.
The method GET /api/v5/store/products allows you to get information about items and their sales propositions.
The method GET /api/v5/store/products/properties allows you to get list of item properties.
If you work with external warehouse system, the shipment should be made on the side of warehouse system. For transferring information about order shipment from warehouse system you should use method POST /api/v5/orders/{externalId}/edit. It is needed to transfer the shipment flag order[shipped]
, shipping warehouse order[shipmentStore]
, date of shipment order[shipmentDate]
.
Important: order[shipped]
field is editable in API only on condition of registered warehouse system.