From 437cf0c4eea96bed290cb6a22dd1fa1900eebcc8 Mon Sep 17 00:00:00 2001 From: Mehmet Ali Gok Date: Wed, 11 Jun 2025 18:13:34 +0200 Subject: [PATCH 1/2] feat(specs): update try transformation specs for no-code --- specs/ingestion/common/schemas/transformation.yml | 7 ++++++- tests/CTS/requests/ingestion/tryTransformation.json | 12 ++++++++---- .../ingestion/tryTransformationBeforeUpdate.json | 12 ++++++++---- 3 files changed, 22 insertions(+), 9 deletions(-) diff --git a/specs/ingestion/common/schemas/transformation.yml b/specs/ingestion/common/schemas/transformation.yml index f5d24c46e42..d7906cc5193 100644 --- a/specs/ingestion/common/schemas/transformation.yml +++ b/specs/ingestion/common/schemas/transformation.yml @@ -153,6 +153,10 @@ TransformationTry: properties: code: $ref: '#/Code' + type: + $ref: '#/TransformationType' + input: + $ref: '#/TransformationInput' sampleRecord: description: The record to apply the given code to. type: object @@ -161,7 +165,8 @@ TransformationTry: items: $ref: './authentication.yml#/AuthenticationCreate' required: - - code + - type + - input - sampleRecord TransformationTryResponse: diff --git a/tests/CTS/requests/ingestion/tryTransformation.json b/tests/CTS/requests/ingestion/tryTransformation.json index bba7758a217..59610e25757 100644 --- a/tests/CTS/requests/ingestion/tryTransformation.json +++ b/tests/CTS/requests/ingestion/tryTransformation.json @@ -1,7 +1,8 @@ [ { "parameters": { - "code": "foo", + "type": "code", + "input": {"code": "foo"}, "sampleRecord": { "bar": "baz" } @@ -10,7 +11,8 @@ "path": "/1/transformations/try", "method": "POST", "body": { - "code": "foo", + "type": "code", + "input": {"code": "foo"}, "sampleRecord": { "bar": "baz" } @@ -20,7 +22,8 @@ { "testName": "with authentications", "parameters": { - "code": "foo", + "type": "code", + "input": {"code": "foo"}, "sampleRecord": { "bar": "baz" }, @@ -40,7 +43,8 @@ "path": "/1/transformations/try", "method": "POST", "body": { - "code": "foo", + "type": "code", + "input": {"code": "foo"}, "sampleRecord": { "bar": "baz" }, diff --git a/tests/CTS/requests/ingestion/tryTransformationBeforeUpdate.json b/tests/CTS/requests/ingestion/tryTransformationBeforeUpdate.json index 5ac39434f5c..bc74c740ab1 100644 --- a/tests/CTS/requests/ingestion/tryTransformationBeforeUpdate.json +++ b/tests/CTS/requests/ingestion/tryTransformationBeforeUpdate.json @@ -3,7 +3,8 @@ "parameters": { "transformationID": "6c02aeb1-775e-418e-870b-1faccd4b2c0f", "transformationTry": { - "code": "foo", + "type": "code", + "input": {"code": "foo"}, "sampleRecord": { "bar": "baz" } @@ -13,7 +14,8 @@ "path": "/1/transformations/6c02aeb1-775e-418e-870b-1faccd4b2c0f/try", "method": "POST", "body": { - "code": "foo", + "type": "code", + "input": {"code": "foo"}, "sampleRecord": { "bar": "baz" } @@ -25,7 +27,8 @@ "parameters": { "transformationID": "6c02aeb1-775e-418e-870b-1faccd4b2c0f", "transformationTry": { - "code": "foo", + "type": "code", + "input": {"code": "foo"}, "sampleRecord": { "bar": "baz" }, @@ -46,7 +49,8 @@ "path": "/1/transformations/6c02aeb1-775e-418e-870b-1faccd4b2c0f/try", "method": "POST", "body": { - "code": "foo", + "type": "code", + "input": {"code": "foo"}, "sampleRecord": { "bar": "baz" }, From fa35a7b94c983f0ba833153b6a3527b01fd80973 Mon Sep 17 00:00:00 2001 From: Mehmet Ali Gok Date: Thu, 12 Jun 2025 12:00:32 +0200 Subject: [PATCH 2/2] fix(specs): remove required fields to not break existing integrations --- specs/ingestion/common/schemas/transformation.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/specs/ingestion/common/schemas/transformation.yml b/specs/ingestion/common/schemas/transformation.yml index d7906cc5193..211737b9552 100644 --- a/specs/ingestion/common/schemas/transformation.yml +++ b/specs/ingestion/common/schemas/transformation.yml @@ -107,8 +107,6 @@ TransformationCreate: $ref: '#/AuthenticationIDs' required: - name - - type - - input TransformationCreateResponse: type: object @@ -165,8 +163,6 @@ TransformationTry: items: $ref: './authentication.yml#/AuthenticationCreate' required: - - type - - input - sampleRecord TransformationTryResponse: