From b90c2bc658834af05cf00a541075b099ff630577 Mon Sep 17 00:00:00 2001 From: shortcuts Date: Mon, 15 Sep 2025 13:24:11 +0200 Subject: [PATCH 1/4] feat(specs): allow filtering transformations type --- specs/ingestion/common/transformationParameters.yml | 8 ++++++++ .../paths/transformations/transformations.yml | 1 + tests/CTS/requests/ingestion/listTransformations.json | 10 ++++++++++ 3 files changed, 19 insertions(+) diff --git a/specs/ingestion/common/transformationParameters.yml b/specs/ingestion/common/transformationParameters.yml index 073b8e33ec3..826d4a4ee55 100644 --- a/specs/ingestion/common/transformationParameters.yml +++ b/specs/ingestion/common/transformationParameters.yml @@ -1,3 +1,11 @@ +type: + name: type + in: query + description: Whether to filter the list of transformations by the type of transformation. + required: false + schema: + $ref: './schemas/transformation.yml#/TransformationType' + sort: name: sort in: query diff --git a/specs/ingestion/paths/transformations/transformations.yml b/specs/ingestion/paths/transformations/transformations.yml index 60bf09b6523..6ce9c0f6f09 100644 --- a/specs/ingestion/paths/transformations/transformations.yml +++ b/specs/ingestion/paths/transformations/transformations.yml @@ -12,6 +12,7 @@ get: parameters: - $ref: '../../common/parameters.yml#/itemsPerPage' - $ref: '../../common/parameters.yml#/page' + - $ref: '../../common/transformationParameters.yml#/type' - $ref: '../../common/transformationParameters.yml#/sort' - $ref: '../../common/parameters.yml#/order' responses: diff --git a/tests/CTS/requests/ingestion/listTransformations.json b/tests/CTS/requests/ingestion/listTransformations.json index 67469b47ed6..ffbec4ca66a 100644 --- a/tests/CTS/requests/ingestion/listTransformations.json +++ b/tests/CTS/requests/ingestion/listTransformations.json @@ -5,5 +5,15 @@ "path": "/1/transformations", "method": "GET" } + }, + { + "testName": "allows filtering by type", + "parameters": { + "type":"noCode" + }, + "request": { + "path": "/1/transformations&type=noCode", + "method": "GET" + } } ] From c1b1d443886e41d11b990adca37d7f49277ee93c Mon Sep 17 00:00:00 2001 From: shortcuts Date: Mon, 15 Sep 2025 15:03:00 +0200 Subject: [PATCH 2/4] fix: cts --- tests/CTS/requests/ingestion/listTransformations.json | 5 ++++- tests/output/javascript/yarn.lock | 10 +++++----- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/tests/CTS/requests/ingestion/listTransformations.json b/tests/CTS/requests/ingestion/listTransformations.json index ffbec4ca66a..d4ca853c766 100644 --- a/tests/CTS/requests/ingestion/listTransformations.json +++ b/tests/CTS/requests/ingestion/listTransformations.json @@ -13,7 +13,10 @@ }, "request": { "path": "/1/transformations&type=noCode", - "method": "GET" + "method": "GET", + "queryParameters": { + "type": "noCode" + } } } ] diff --git a/tests/output/javascript/yarn.lock b/tests/output/javascript/yarn.lock index b1b1049d551..82aba42a82e 100644 --- a/tests/output/javascript/yarn.lock +++ b/tests/output/javascript/yarn.lock @@ -427,12 +427,12 @@ __metadata: languageName: node linkType: hard -"@types/node@npm:22.18.0": - version: 22.18.0 - resolution: "@types/node@npm:22.18.0" +"@types/node@npm:22.18.1": + version: 22.18.1 + resolution: "@types/node@npm:22.18.1" dependencies: undici-types: "npm:~6.21.0" - checksum: 10/c4e4cdac52aae71e120fb4a02a08f774366e8bd6654de9376fb1113fb66cfa2706176b72f188069cdecdb40e5cdde2befa031dc720a0cc0b1e349af9e38492ad + checksum: 10/da67f3c3fa4107fbca704e7a71fee36c27f3b6f44af1c466cd5c71eab76a9ffcd6a16f3b97d1e757b9763f1fa1085eebb60cb648c272e36794aca7305b2a15d9 languageName: node linkType: hard @@ -1022,7 +1022,7 @@ __metadata: "@algolia/client-composition": "link:../../../clients/algoliasearch-client-javascript/packages/client-composition" "@algolia/composition": "link:../../../clients/algoliasearch-client-javascript/packages/composition" "@algolia/requester-testing": "link:../../../clients/algoliasearch-client-javascript/packages/requester-testing" - "@types/node": "npm:22.18.0" + "@types/node": "npm:22.18.1" algoliasearch: "link:../../../clients/algoliasearch-client-javascript/packages/algoliasearch" typescript: "npm:5.9.2" vitest: "npm:3.2.4" From f070a549bad56220cc5be8a1de69c5e9b04ae2f8 Mon Sep 17 00:00:00 2001 From: shortcuts Date: Mon, 15 Sep 2025 15:15:12 +0200 Subject: [PATCH 3/4] fix: cts --- tests/CTS/requests/ingestion/listTransformations.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/CTS/requests/ingestion/listTransformations.json b/tests/CTS/requests/ingestion/listTransformations.json index d4ca853c766..88a2dbc85f3 100644 --- a/tests/CTS/requests/ingestion/listTransformations.json +++ b/tests/CTS/requests/ingestion/listTransformations.json @@ -12,7 +12,7 @@ "type":"noCode" }, "request": { - "path": "/1/transformations&type=noCode", + "path": "/1/transformations", "method": "GET", "queryParameters": { "type": "noCode" From 9a4e4e9f20b00f5fb39bc6cb6d9900b82757c3dd Mon Sep 17 00:00:00 2001 From: shortcuts Date: Mon, 15 Sep 2025 15:28:33 +0200 Subject: [PATCH 4/4] fix: cts --- .../paths/transformations/transformations.yml | 2 +- tests/CTS/requests/ingestion/listTransformations.json | 10 +++++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/specs/ingestion/paths/transformations/transformations.yml b/specs/ingestion/paths/transformations/transformations.yml index 6ce9c0f6f09..c50e7f6bc9a 100644 --- a/specs/ingestion/paths/transformations/transformations.yml +++ b/specs/ingestion/paths/transformations/transformations.yml @@ -12,9 +12,9 @@ get: parameters: - $ref: '../../common/parameters.yml#/itemsPerPage' - $ref: '../../common/parameters.yml#/page' - - $ref: '../../common/transformationParameters.yml#/type' - $ref: '../../common/transformationParameters.yml#/sort' - $ref: '../../common/parameters.yml#/order' + - $ref: '../../common/transformationParameters.yml#/type' responses: '200': description: OK diff --git a/tests/CTS/requests/ingestion/listTransformations.json b/tests/CTS/requests/ingestion/listTransformations.json index 88a2dbc85f3..91b50b78dcd 100644 --- a/tests/CTS/requests/ingestion/listTransformations.json +++ b/tests/CTS/requests/ingestion/listTransformations.json @@ -7,14 +7,22 @@ } }, { - "testName": "allows filtering by type", + "testName": "list with every parameters", "parameters": { + "itemsPerPage": 2, + "page": 1, + "sort": "createdAt", + "order": "asc", "type":"noCode" }, "request": { "path": "/1/transformations", "method": "GET", "queryParameters": { + "itemsPerPage": "2", + "page": "1", + "sort": "createdAt", + "order": "asc", "type": "noCode" } }