Warning

This site is no longer being maintained. Visit the eDocs documentation portal for updated information.

Visit eDocs
Dismiss message

Skusearch API

Created by Iago Fernández · last update December 10, 2019

About this endpoint

The main goal of this endpoint is to provide a set of parameters with the aim of searching SKUs (Stock keeping units).

GET https://api.empathybroker.com/search/v1/query/{instance_id}/skusearch?{Input_Parameters}

Input Parameters

Parameter Data Type
q String
lang String
start Integer
rows Integer
warehouse Integer
catalogue String
origin String

Implementation

Here is a simple example of an implementation in Java to consume this service

1
2
3
4
5
6
7
8
9
10
11
12
13
14
Client client;
WebTarget target;
public void init(){
    client = ClientBuilder.newClient();
    target = client.target("https://api.empathybroker.com/search/v1/query/{instance_id}/skusearch")
        //Query parameters
        .queryParam("lang","ES")

   
}
 
public JSON getResponse(String query){
    return target.queryParam("q",query).request(MediaType.APPLICATION_JSON).get(JSON.class)
}

Output

The service will return a single json node per product/document and all attributes associated with the item type

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
"content": {
    "docs": [{
        "id": "500975676",
        "eb_id": "500975676-009",
        "internal_id": "500975676-009",
        "mocacoReference": "1628/311/009",
        "eb_sku": "1628/311/009",
        "minPrice": "19.99",
        "maxPrice": "19.99",
        "minOldPrice": "0.0",
        "maxOldPrice": "0.0",
        "name": "Sandalia azul tacón medio pulsera",
        "firstRootCategory": "1010141507",
        "idProduct": "500975676-009",
        "productId": "500975676",
        "reference": "1628/311",
        "displayReference": "1628/311",
        "img": {
            "timestamp": "1537979412849",
            "url": "/2018/I/1/1/p/1628/311/009/1628311009",
            "aux": [
                "1",
                "2",
                "3",
                "4",
                "5",
                "6"
            ],
            "type": [
                "1",
                "2",
                "3",
                "4"
            ]
            }
        }
    ],
    "numFound": 1
}