XM
Powered By GitBook
Search Products
Path:
1
GET https://{baseurl}/api-product/v1/product/search?size=10&page=0
Copied!
Enables you to search products, by keyword. You may alternatively use the query parameters 'page' and 'size,' for a paginated response.

Headers

Content-Type : application/json
x-site-context : { "date": "2020-08-28T02:35:27.787Z", "channel": 12, "account": 5f493c9f30ec2a0007a94fc8", "stage": "sandbox" }
Authorization: The JWT Authorization token from the Login API.

Parameters

Type : query
Name : The keywords to narrow down the search results.
Required: true

or

Type : query
Name : The page and size number for a focused search results.
Required: true

1. Sample request for products, by keywords

1
GET https://{baseurl}/api-product/v1/product/search?keyword=test1
Copied!

Sample Response

Response Code: 200
Message: OK
Description: You will see this response when the products are successfully retrieved based on the query parameter 'keywords.' When there are no matching products, you will see a blank array of products in the success response.
1
{
2
"products": [
3
{
4
"sku": "PricingTest123",
5
"itemId": 68,
6
"children": [
7
{
8
"sku": "var1",
9
"attributes": [
10
{
11
"name": "Display Name",
12
"description": "",
13
"mapping": "title",
14
"type": "TEXT",
15
"value": "var1"
16
},
17
{
18
"name": "Active",
19
"description": "",
20
"mapping": "active",
21
"type": "BOOLEAN",
22
"value": "true"
23
}
24
]
25
},
26
{
27
"sku": "var2",
28
"attributes": [
29
{
30
"name": "Display Name",
31
"description": "",
32
"mapping": "title",
33
"type": "TEXT",
34
"value": "var2"
35
},
36
{
37
"name": "Active",
38
"description": "",
39
"mapping": "active",
40
"type": "BOOLEAN",
41
"value": "true"
42
}
43
]
44
}
45
],
46
"type": "ITEM",
47
"bundleItems": [],
48
"categories": [
49
{
50
"id": "60c10ad09572f1000875291a",
51
"name": "Base 1",
52
"breadcrumbs": [
53
{
54
"id": "60a417f5c4b80d0008461e87",
55
"name": "MASTER",
56
"attributes": []
57
}
58
],
59
"attributes": []
60
}
61
],
62
"attributes": [
63
{
64
"name": "Display Name",
65
"description": "",
66
"mapping": "title",
67
"type": "TEXT",
68
"value": "Pricing Test 123"
69
},
70
{
71
"name": "Active",
72
"description": "",
73
"mapping": "active",
74
"type": "BOOLEAN",
75
"value": "true"
76
}
77
],
78
"dependents": [
79
"var1",
80
"var2"
81
]
82
},
83
{
84
"sku": "test1",
85
"itemId": 39,
86
"children": [
87
{
88
"sku": "testc2",
89
"attributes": [
90
{
91
"name": "Display Name",
92
"description": "",
93
"mapping": "title",
94
"type": "TEXT",
95
"value": "Test C1"
96
},
97
{
98
"name": "Active",
99
"description": "",
100
"mapping": "active",
101
"type": "BOOLEAN",
102
"value": "true"
103
}
104
]
105
},
106
{
107
"sku": "testc3",
108
"attributes": [
109
{
110
"name": "Display Name",
111
"description": "",
112
"mapping": "title",
113
"type": "TEXT",
114
"value": "Test C3"
115
},
116
{
117
"name": "Active",
118
"description": "",
119
"mapping": "active",
120
"type": "BOOLEAN",
121
"value": "true"
122
}
123
]
124
}
125
],
126
"type": "ITEM",
127
"bundleItems": [],
128
"categories": [
129
{
130
"id": "60b896d2e723930008f3d432",
131
"name": "Drafting Tables",
132
"breadcrumbs": [
133
{
134
"id": "60a417f5c4b80d0008461e87",
135
"name": "MASTER",
136
"attributes": []
137
},
138
{
139
"id": "60b89690e723930008f3d42f",
140
"name": "Tables",
141
"attributes": []
142
}
143
],
144
"attributes": []
145
}
146
],
147
"attributes": [
148
{
149
"name": "Display Name",
150
"description": "",
151
"mapping": "title",
152
"type": "TEXT",
153
"value": "Test 1"
154
},
155
{
156
"name": "Active",
157
"description": "",
158
"mapping": "active",
159
"type": "BOOLEAN",
160
"value": "true"
161
}
162
],
163
"dependents": [
164
"testc2",
165
"testc3"
166
]
167
}
168
],
169
"totalSize": 2,
170
"pageSize": 2,
171
"pages": 1
172
}
Copied!

2. Sample request for products, by page and size

1
GET https://{baseurl}/api-product/v1/product/search?size=10&page=0
Copied!

Sample Response

Response Code: 200
Message: OK
Description: You will see this paginated response when the query parameters are size and page.
1
{
2
"products": [
3
{
4
"sku": "5",
5
"itemId": 78,
6
"children": [],
7
"type": "ITEM",
8
"bundleItems": [],
9
"categories": [
10
{
11
"id": "60c3ecd1eaeb3400084fff36",
12
"name": "Meal Plans",
13
"breadcrumbs": [
14
{
15
"id": "60a417f5c4b80d0008461e87",
16
"name": "MASTER",
17
"attributes": []
18
}
19
],
20
"attributes": []
21
}
22
],
23
"attributes": [
24
{
25
"name": "Display Name",
26
"description": "",
27
"mapping": "title",
28
"type": "TEXT",
29
"value": "12 Dinners"
30
}
31
],
32
"dependents": []
33
},
34
{
35
"sku": "4",
36
"itemId": 77,
37
"children": [],
38
"type": "ITEM",
39
"bundleItems": [],
40
"categories": [
41
{
42
"id": "60c3ecd1eaeb3400084fff36",
43
"name": "Meal Plans",
44
"breadcrumbs": [
45
{
46
"id": "60a417f5c4b80d0008461e87",
47
"name": "MASTER",
48
"attributes": []
49
}
50
],
51
"attributes": []
52
}
53
],
54
"attributes": [
55
{
56
"name": "Display Name",
57
"description": "",
58
"mapping": "title",
59
"type": "TEXT",
60
"value": "8 Dinners"
61
}
62
],
63
"dependents": []
64
},
65
{
66
"sku": "3",
67
"itemId": 76,
68
"children": [],
69
"type": "ITEM",
70
"bundleItems": [],
71
"categories": [
72
{
73
"id": "60c3ecd1eaeb3400084fff36",
74
"name": "Meal Plans",
75
"breadcrumbs": [
76
{
77
"id": "60a417f5c4b80d0008461e87",
78
"name": "MASTER",
79
"attributes": []
80
}
81
],
82
"attributes": []
83
}
84
],
85
"attributes": [
86
{
87
"name": "Display Name",
88
"description": "",
89
"mapping": "title",
90
"type": "TEXT",
91
"value": "6 Dinners"
92
}
93
],
94
"dependents": []
95
},
96
{
97
"sku": "2",
98
"itemId": 75,
99
"children": [],
100
"type": "ITEM",
101
"bundleItems": [],
102
"categories": [
103
{
104
"id": "60c3ecd1eaeb3400084fff36",
105
"name": "Meal Plans",
106
"breadcrumbs": [
107
{
108
"id": "60a417f5c4b80d0008461e87",
109
"name": "MASTER",
110
"attributes": []
111
}
112
],
113
"attributes": []
114
}
115
],
116
"attributes": [
117
{
118
"name": "Display Name",
119
"description": "",
120
"mapping": "title",
121
"type": "TEXT",
122
"value": "4 Dinners"
123
}
124
],
125
"dependents": []
126
},
127
{
128
"sku": "1",
129
"itemId": 74,
130
"children": [
131
{
132
"sku": "2",
133
"attributes": [
134
{
135
"name": "Display Name",
136
"description": "",
137
"mapping": "title",
138
"type": "TEXT",
139
"value": "4 Dinners"
140
}
141
]
142
},
143
{
144
"sku": "3",
145
"attributes": [
146
{
147
"name": "Display Name",
148
"description": "",
149
"mapping": "title",
150
"type": "TEXT",
151
"value": "6 Dinners"
152
}
153
]
154
},
155
{
156
"sku": "4",
157
"attributes": [
158
{
159
"name": "Display Name",
160
"description": "",
161
"mapping": "title",
162
"type": "TEXT",
163
"value": "8 Dinners"
164
}
165
]
166
},
167
{
168
"sku": "5",
169
"attributes": [
170
{
171
"name": "Display Name",
172
"description": "",
173
"mapping": "title",
174
"type": "TEXT",
175
"value": "12 Dinners"
176
}
177
]
178
}
179
],
180
"type": "ITEM",
181
"bundleItems": [],
182
"categories": [
183
{
184
"id": "60c3ecd1eaeb3400084fff36",
185
"name": "Meal Plans",
186
"breadcrumbs": [
187
{
188
"id": "60a417f5c4b80d0008461e87",
189
"name": "MASTER",
190
"attributes": []
191
}
192
],
193
"attributes": []
194
}
195
],
196
"attributes": [
197
{
198
"name": "Display Name",
199
"description": "",
200
"mapping": "title",
201
"type": "TEXT",
202
"value": "Dinners"
203
}
204
],
205
"dependents": [
206
"2",
207
"3",
208
"4",
209
"5"
210
]
211
},
212
{
213
"sku": "65387675",
214
"itemId": 71,
215
"children": [],
216
"type": "ITEM",
217
"bundleItems": [],
218
"categories": [
219
{
220
"id": "60c3ebbdeaeb3400084fff32",
221
"name": "sub prime",
222
"breadcrumbs": [
223
{
224
"id": "60a417f5c4b80d0008461e87",
225
"name": "MASTER",
226
"attributes": []
227
},
228
{
229
"id": "60ab85a19e69ae00080042e1",
230
"name": "Bedding",
231
"attributes": []
232
},
233
{
234
"id": "60c3eb9feaeb3400084fff2f",
235
"name": "Sub",
236
"attributes": []
237
}
238
],
239
"attributes": []
240
}
241
],
242
"attributes": [
243
{
244
"name": "Display Name",
245
"description": "",
246
"mapping": "title",
247
"type": "TEXT",
248
"value": "Component"
249
}
250
],
251
"dependents": []
252
},
253
{
254
"sku": "var2",
255
"itemId": 70,
256
"children": [],
257
"type": "ITEM",
258
"bundleItems": [],
259
"categories": [
260
{
261
"id": "60c10ad09572f1000875291a",
262
"name": "Base 1",
263
"breadcrumbs": [
264
{
265
"id": "60a417f5c4b80d0008461e87",
266
"name": "MASTER",
267
"attributes": []
268
}
269
],
270
"attributes": []
271
}
272
],
273
"attributes": [
274
{
275
"name": "Display Name",
276
"description": "",
277
"mapping": "title",
278
"type": "TEXT",
279
"value": "var2"
280
},
281
{
282
"name": "Active",
283
"description": "",
284
"mapping": "active",
285
"type": "BOOLEAN",
286
"value": "true"
287
}
288
],
289
"dependents": []
290
},
291
{
292
"sku": "var1",
293
"itemId": 69,
294
"children": [],
295
"type": "ITEM",
296
"bundleItems": [],
297
"categories": [
298
{
299
"id": "60c10ad09572f1000875291a",
300
"name": "Base 1",
301
"breadcrumbs": [
302
{
303
"id": "60a417f5c4b80d0008461e87",
304
"name": "MASTER",
305
"attributes": []
306
}
307
],
308
"attributes": []
309
}
310
],
311
"attributes": [
312
{
313
"name": "Display Name",
314
"description": "",
315
"mapping": "title",
316
"type": "TEXT",
317
"value": "var1"
318
},
319
{
320
"name": "Active",
321
"description": "",
322
"mapping": "active",
323
"type": "BOOLEAN",
324
"value": "true"
325
}
326
],
327
"dependents": []
328
},
329
{
330
"sku": "PricingTest123",
331
"itemId": 68,
332
"children": [
333
{
334
"sku": "var1",
335
"attributes": [
336
{
337
"name": "Display Name",
338
"description": "",
339
"mapping": "title",
340
"type": "TEXT",
341
"value": "var1"
342
},
343
{
344
"name": "Active",
345
"description": "",
346
"mapping": "active",
347
"type": "BOOLEAN",
348
"value": "true"
349
}
350
]
351
},
352
{
353
"sku": "var2",
354
"attributes": [
355
{
356
"name": "Display Name",
357
"description": "",
358
"mapping": "title",
359
"type": "TEXT",
360
"value": "var2"
361
},
362
{
363
"name": "Active",
364
"description": "",
365
"mapping": "active",
366
"type": "BOOLEAN",
367
"value": "true"
368
}
369
]
370
}
371
],
372
"type": "ITEM",
373
"bundleItems": [],
374
"categories": [
375
{
376
"id": "60c10ad09572f1000875291a",
377
"name": "Base 1",
378
"breadcrumbs": [
379
{
380
"id": "60a417f5c4b80d0008461e87",
381
"name": "MASTER",
382
"attributes": []
383
}
384
],
385
"attributes": []
386
}
387
],
388
"attributes": [
389
{
390
"name": "Display Name",
391
"description": "",
392
"mapping": "title",
393
"type": "TEXT",
394
"value": "Pricing Test 123"
395
},
396
{
397
"name": "Active",
398
"description": "",
399
"mapping": "active",
400
"type": "BOOLEAN",
401
"value": "true"
402
}
403
],
404
"dependents": [
405
"var1",
406
"var2"
407
]
408
},
409
{
410
"sku": "capio-child",
411
"itemId": 67,
412
"children": [],
413
"type": "ITEM",
414
"bundleItems": [],
415
"categories": [
416
{
417
"id": "60acf75737d4df0008185284",
418
"name": "AB",
419
"breadcrumbs": [
420
{
421
"id": "60a417f5c4b80d0008461e87",
422
"name": "MASTER",
423
"attributes": []
424
}
425
],
426
"attributes": []
427
}
428
],
429
"attributes": [
430
{
431
"name": "Display Name",
432
"description": "",
433
"mapping": "title",
434
"type": "TEXT",
435
"value": "capio-child"
436
},
437
{
438
"name": "Active",
439
"description": "",
440
"mapping": "active",
441
"type": "BOOLEAN",
442
"value": "true"
443
}
444
],
445
"dependents": []
446
}
447
],
448
"totalSize": 37,
449
"pageSize": 10,
450
"pages": 4
451
}
Copied!

Change Log

    June - 2021 First Updated
Last modified 3mo ago
Copy link
Contents
Change Log