Endpoints
Login Endpoint
It's possible to pass params both as JSON or POST params
Sync Inventory
URL |
https://DOMAIN/api/rest/v001/store/STORE ID/ext/sync |
Method |
PATCH |
Format |
JSON |
Request Content |
JSON encoded array list of inventory structs. Each struct has to contain "external_id" param, which will be used to lookup related item in inventory. Unnecessary params can be omitted, in that case they will not be updated. By the way, as "external_id" is used to lookup inventory, inventory Tipsi "id" param is prohibited here as the request will look ambiguously, thus trying to use it will cause error with HTTP respone 400. |
Sync Inventory With Clearing
Same, as Sync Inventory Endpoint, except will clear inventory not listed in the batch. It's a safe method as it will just mark in_stock parameter to 0. For real inventory deletion DELETE method should be used upon each inventory item.
List Wine Inventory
URL |
https://DOMAIN/api/rest/v001/store/STORE ID/wine |
Method |
GET |
GET Params |
List of fields for each struct inventory structs. If not specified which fields to fetch for a given struct, it will contain only "id" parameter. Param name, related to a given struct, listed below struct tables |
https://DOMAIN.gettipsi.com/api/rest/v001/store/STORE ID/wine?wine_fields=id,winery,region&inventory_fields=id,wine&winery_fields=id,name®ion_fields=id,name,description,image_url
List Drink Inventory
Create Wine Inventory
Minimal parameters for wine: barcodes
and external_id
. If wine_id
is not passed, it will create item in unmatched state. Such item doesn't have linked wine, but it's useful when wine should be manually matched by Tipsi team (see Label Processing Tasks Guide).
({
"abv": null,
"barcodes": [
"wine-123"
],
"external_id": 3001,
"id": 421,
"in_stock": null,
"price": null,
"proof": null,
"special_price": null,
"special_price_amount": 0,
"special_price_on": false,
"status": "match_complete",
"unit_size": null
})
Create Drink Inventory
Minimal parameters for wine: barcodes
and external_id
. If drink_id
is not passed, it will create item in unmatched state. Please see Label Processing Tasks Guide.
Get Product By Barcode
URL |
https://DOMAIN/api/rest/v001/store/STORE ID/barcode/BARCODE |
Method |
GET |
GET Params |
List of fields for each struct inventory structs. If not specified which fields to fetch for a given struct, it will contain only "id" parameter. Param name, related to a given struct, listed below struct tables. |
Example:
https://DOMAIN.gettipsi.com/api/rest/v001/store/STORE ID/barcode/BARCODE?wine_fields=id,winery,region&inventory_fields=id,wine&winery_fields=id,name®ion_fields=id,name,description,image_url
Full Text Search
Example
({
"count": 2,
"next": null,
"previous": null,
"results": [
{
"drink": null,
"rank": "0.638323",
"wine": {
"id": 19,
"pro_rating": [],
"winery": {
"id": 18,
"name": "Caymus"
}
}
},
{
"drink": {
"id": 20
},
"rank": "0.0607927",
"wine": null
}
]
}
{
"count": 1,
"next": null,
"previous": null,
"results": [
{
"rank": "0.638323",
"wine": {
"id": 19,
"pro_rating": [],
"winery": {
"id": 18,
"name": "Caymus"
}
}
}
]
}
({
"count": 1,
"next": null,
"previous": null,
"results": [
{
"drink": {
"id": 20
},
"rank": "0.0607927"
}
]
}
Upload image
URL |
/api/rest/v001/store/STORE_ID/image_upload |
Method |
POST |
Format |
"multipart/form-data" |
POST Params |
Image file encoded using standard "multipart/form-data" as image field |
Create task
WINE URL |
/api/rest/v001/store/STORE_ID/{wine,drink}/TIPSI_INVENTORY_ID/create_task |
Method |
POST |
Format |
JSON |
POST Params |
front_image, back_image (optional), vintage (optional) |
Returns inventory structs with drink_id and wine_id.