From ec89eceab53765c746d8b21440f951ffbfc9cc4d Mon Sep 17 00:00:00 2001 From: Bryan Cross Date: Sun, 8 Oct 2023 12:52:16 -0500 Subject: [PATCH] Updating postman assets --- postman/ConvertOAS.postman_collection.json | 99 --------------------- postman/ConvertOAS.postman_environment.json | 14 ++- 2 files changed, 10 insertions(+), 103 deletions(-) diff --git a/postman/ConvertOAS.postman_collection.json b/postman/ConvertOAS.postman_collection.json index 917e631..e166a4d 100644 --- a/postman/ConvertOAS.postman_collection.json +++ b/postman/ConvertOAS.postman_collection.json @@ -1523,105 +1523,6 @@ }, "response": [] }, - { - "name": "ConvertOAS2To3 Copy", - "event": [ - { - "listen": "test", - "script": { - "exec": [ - "pm.test(\"Status code is 200\", function () {", - " pm.response.to.have.status(200);", - "});", - "const json = pm.response.json();", - "//console.log(json.b64);", - "var oas30schema = \"\";", - "if(pm.environment.get('cfg_outputFileFormat') == 'yaml' || pm.environment.get('cfg_outputFileFormat') == 'yml')", - "{", - " oas30schema = Buffer.from(json.b64,'base64').toString('utf-8');", - "}", - "else {", - " oas30schema = JSON.stringify(json.spec);", - "}", - "", - "let oas30schemaString = \"\";", - "oas30schemaString = oas30schema.replaceAll(/\\n/g, \"\\\\n\");", - "oas30schemaString = oas30schema.replaceAll(/\\\"/g, \"\\\\\\\"\");", - "console.log(oas30schemaString);", - "pm.environment.set('rt_targetSchema', oas30schema);", - "pm.environment.set('rt_targetSchema-string',oas30schemaString)", - "", - "if(pm.environment.get('cfg_createNewAPI') == 'false') {", - " postman.setNextRequest(\"Add 3.0 Schema\")", - "}", - "" - ], - "type": "text/javascript" - } - }, - { - "listen": "prerequest", - "script": { - "exec": [ - "let sourceSchema = pm.environment.get('rt_sourceSchema');", - "//console.log(\"Source schema: \", sourceSchema);", - "let sourceSchema64 = Buffer.from(sourceSchema).toString('base64');", - "console.log(sourceSchema64);", - "pm.environment.set('rt_sourceSchema64',sourceSchema64);", - "" - ], - "type": "text/javascript" - } - } - ], - "request": { - "method": "POST", - "header": [], - "body": { - "mode": "raw", - "raw": "{\"b64\":\"{{rt_sourceSchema64}}\"}", - "options": { - "raw": { - "language": "json" - } - } - }, - "url": { - "raw": "https://eaa7painas5mlef3tqy6md4t3m0kgoto.lambda-url.us-east-2.on.aws/?outputFileFormat={{rt_sourceFileFormat}}&inputFileFormat={{rt_sourceFileFormat}}&inputAPIType=swagger_2&outputAPIType={{cfg_outputAPIType}}", - "protocol": "https", - "host": [ - "eaa7painas5mlef3tqy6md4t3m0kgoto", - "lambda-url", - "us-east-2", - "on", - "aws" - ], - "path": [ - "" - ], - "query": [ - { - "key": "outputFileFormat", - "value": "{{rt_sourceFileFormat}}" - }, - { - "key": "inputFileFormat", - "value": "{{rt_sourceFileFormat}}" - }, - { - "key": "inputAPIType", - "value": "swagger_2" - }, - { - "key": "outputAPIType", - "value": "{{cfg_outputAPIType}}" - } - ] - }, - "description": "Sends the source OAS file to a Lambda function at `cfg_OASConverterUrl` for conversion:\n\n#### Parameters\n\n**outputAPIType**: The OAS version to convert the source to is specified in the `cfg_outputAPIType` variable. Currently only `openapi_3` is supported." - }, - "response": [] - }, { "name": "Create 3.0 API", "event": [ diff --git a/postman/ConvertOAS.postman_environment.json b/postman/ConvertOAS.postman_environment.json index 8d22cfe..4c747e3 100644 --- a/postman/ConvertOAS.postman_environment.json +++ b/postman/ConvertOAS.postman_environment.json @@ -1,5 +1,5 @@ { - "id": "f4729082-c30a-4d98-b09e-be72a0a669ca", + "id": "8e8fc40e-9321-4adb-885b-8abe0753f8bd", "name": "Convert OAS 2 to OAS 3", "values": [ { @@ -10,7 +10,7 @@ }, { "key": "cfg_workspaceId", - "value": "b300ef5a-6cf8-4295-9712-0cfecc414f50", + "value": "", "type": "default", "enabled": true }, @@ -28,7 +28,7 @@ }, { "key": "cfg_outputFileFormat", - "value": "", + "value": "yaml", "type": "default", "enabled": true }, @@ -127,9 +127,15 @@ "value": "", "type": "any", "enabled": true + }, + { + "key": "cfg_APINameFilter", + "value": "", + "type": "default", + "enabled": true } ], "_postman_variable_scope": "environment", - "_postman_exported_at": "2023-10-08T00:06:01.156Z", + "_postman_exported_at": "2023-10-08T17:51:49.759Z", "_postman_exported_using": "Postman/10.18.10-231005-0655" } \ No newline at end of file