Skip to content

Commit 6c29d77

Browse files
authored
Merge pull request #674 from akeneo/CPM-764
CPM-764: Add doc for uuid filter
2 parents 9602700 + ea291b3 commit 6c29d77

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

content/rest-api/filter.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,27 @@ To get the products with an "A" or "B" for the `mobile` channel and `en_GB` loca
241241
/api/rest/v1/products-uuid?search={"quality_score":[{"operator":"IN","value":["A","B"],"scope":"mobile","locale":"en_GB"}]}
242242
```
243243

244+
### On their uuid
245+
246+
::: availability versions=SaaS editions=CE,EE
247+
248+
To filter products on their uuid, use the `uuid` product property. This filter does not need a `scope` or `locale` value.
249+
This filter accepts 2 operators: IN and NOT IN, and the value is always an array of uuids.
250+
251+
#### Examples
252+
253+
To get the products having uuid `aaf518b2-f91e-40f1-a53a-78ce5e81a6f9` or `fc24e6c3-933c-4a93-8a81-e5c703d134d5`.
254+
255+
```
256+
/api/rest/v1/products-uuid?search={"uuid":[{"operator":"IN","value":["aaf518b2-f91e-40f1-a53a-78ce5e81a6f9", "fc24e6c3-933c-4a93-8a81-e5c703d134d5"]}]}
257+
```
258+
259+
To get all the products but the products with uuid `aaf518b2-f91e-40f1-a53a-78ce5e81a6f9` and `fc24e6c3-933c-4a93-8a81-e5c703d134d5`.
260+
261+
```
262+
/api/rest/v1/products-uuid?search={"uuid":[{"operator":"NOT IN","value":["aaf518b2-f91e-40f1-a53a-78ce5e81a6f9", "fc24e6c3-933c-4a93-8a81-e5c703d134d5"]}]}
263+
```
264+
244265
## Filter on product model properties
245266

246267
To filter product models by one of their properties, you can use the `search` query parameter. The value given to this query parameter should be a valid JSON as shown below.

0 commit comments

Comments
 (0)