From b325c803f1beded7d023794a927ccb845ae4eae3 Mon Sep 17 00:00:00 2001 From: Mariangela Date: Wed, 22 Mar 2023 15:23:02 +0530 Subject: [PATCH 1/9] updated x-code-samples --- en/docs/catalogs/runtime-api.yaml | 54 +++++++++++++++++++++++++++++-- 1 file changed, 52 insertions(+), 2 deletions(-) diff --git a/en/docs/catalogs/runtime-api.yaml b/en/docs/catalogs/runtime-api.yaml index d1edabb2c..d1e50a38e 100644 --- a/en/docs/catalogs/runtime-api.yaml +++ b/en/docs/catalogs/runtime-api.yaml @@ -90,6 +90,11 @@ paths: $ref: "#/components/responses/InternalServerError" "400": $ref: "#/components/responses/BadRequest" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis"' + post: tags: - APIs @@ -133,6 +138,14 @@ paths: $ref: "#/components/responses/BadRequest" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Content-Type: application/json" + -H "Accept: application/json" + -H "Host: api.am.wso2.com" -d @data.json + "https://api.am.wso2.com:9095/api/am/runtime/apis"' + /apis/{apiId}: get: tags: @@ -172,6 +185,11 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' + put: tags: - APIs @@ -231,6 +249,11 @@ paths: "500": $ref: "#/components/responses/InternalServerError" + + x-code-samples: + - lang: Curl + source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -d @data.json + "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' delete: tags: - APIs @@ -260,11 +283,16 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X DELETE -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' + /apis/{apiId}/generate-key: post: tags: - APIs - summary: Generate internal API Key to invoke APIS. + summary: Generate internal API Key to invoke APIS description: | This operation can be used to generate internal API key which used to invoke API. operationId: generateInternalAPIKey @@ -287,6 +315,14 @@ paths: $ref: "#/components/responses/Forbidden" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/generate-key" + -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Content-Type: application/json" + -H "Accept: application/json" + -H "Host: api.am.wso2.com"' + /apis/import-service: post: tags: @@ -524,6 +560,10 @@ paths: "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' put: tags: - APIs @@ -582,6 +622,10 @@ paths: "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -d @data.json + "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' /apis/export: get: tags: @@ -809,7 +853,12 @@ paths: "400": $ref: "#/components/responses/BadRequest" "500": - $ref: "#/components/responses/InternalServerError" + $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + "https://api.am.wso2.com:9095/api/am/runtime/services"' + /services/{serviceId}: get: tags: @@ -841,6 +890,7 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + /services/{serviceId}/usage: get: tags: From 5e8c12547b4adc0b390f3587ae15ab039016c62d Mon Sep 17 00:00:00 2001 From: Mariangela Date: Wed, 22 Mar 2023 19:07:55 +0530 Subject: [PATCH 2/9] updated x-code-samples part2 --- en/docs/catalogs/runtime-api.yaml | 94 +++++++++++++++++++++++++++---- 1 file changed, 82 insertions(+), 12 deletions(-) diff --git a/en/docs/catalogs/runtime-api.yaml b/en/docs/catalogs/runtime-api.yaml index d1e50a38e..d8f2eaf3b 100644 --- a/en/docs/catalogs/runtime-api.yaml +++ b/en/docs/catalogs/runtime-api.yaml @@ -187,7 +187,8 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' put: @@ -252,7 +253,7 @@ paths: x-code-samples: - lang: Curl - source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -d @data.json + source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" -H "Content-Type: application/json" -d @data.json "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' delete: tags: @@ -283,10 +284,10 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" - x-code-samples: - - lang: Curl - source: 'curl -k -X DELETE -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' + x-code-samples: + - lang: Curl + source: 'curl -k -X DELETE -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" + "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' /apis/{apiId}/generate-key: post: @@ -375,6 +376,14 @@ paths: "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/import-service?serviceKey=11cd3fa3-c886-49f9-bf78-0ec349b1f4c1" + -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Content-Type: application/json" + -H "Accept: application/json" + -H "Host: api.am.wso2.com" -d @data.json' + /apis/import-definition: post: tags: @@ -423,6 +432,14 @@ paths: "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/import-definition" + -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Content-Type: application/json" + -H "Accept: application/json" + -H "Host: api.am.wso2.com" -F file=@openapi.json -F additionalProperties=@data.json' + /apis/validate-definition: post: tags: @@ -472,6 +489,13 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Content-Type: application/json" + -H "Accept: application/json" + -H "Host: api.am.wso2.com" + -F file=@openapi.json "https://api.am.wso2.com:9095/api/am/runtime/apis/validate-definition"' /apis/validate: post: tags: @@ -517,6 +541,11 @@ paths: "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" + "https://api.am.wso2.com:9095/api/am/runtime/apis/validate?query=name%3Awso2"' /apis/{apiId}/definition: get: tags: @@ -562,7 +591,8 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' put: tags: @@ -624,8 +654,11 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -d @data.json - "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' + source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" + -H "Content-Type: application/json" + -d @data.json + "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' /apis/export: get: tags: @@ -695,6 +728,12 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" + "https://api.am.wso2.com:9095/api/am/runtime/apis/export?apiId=96077508-fd01-4fae-bc64-5de0e2baf43c&name=PizzaShackAPI&version=1.0&provider=admin&format=YAML" + > exportAPI.zip' /apis/import: post: tags: @@ -733,6 +772,10 @@ paths: "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" + -F file=@admin-PizzaShackAPI-1.0.0.zip "https://api.am.wso2.com:9095/api/am/runtime/apis/import?preserveProvider=false&overwrite=false"' /apis/copy-api: post: tags: @@ -779,6 +822,12 @@ paths: - apk:api_create - apk:api_manage operationId: createNewAPIVersion + x-code-samples: + - lang: Curl + source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/copy-api?apiId=01234567-0123-0123-0123-012345678901&newVersion=2.0.0" + -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com"' + /services: get: tags: @@ -857,6 +906,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/services"' /services/{serviceId}: @@ -890,6 +940,11 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" + "https://api.am.wso2.com:9095/api/am/runtime/services/11cd3fa3-c886-49f9-bf78-0ec349b1f4c1"' /services/{serviceId}/usage: get: @@ -922,6 +977,11 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" + "https://api.am.wso2.com:9095/api/am/runtime/services/11cd3fa3-c886-49f9-bf78-0ec349b1f4c1/usage"' /policies: get: tags: @@ -1015,6 +1075,11 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" + "https://api.am.wso2.com:9095/api/am/runtime/policies"' /policies/{policyId}: get: tags: @@ -1051,6 +1116,11 @@ paths: $ref: "#/components/responses/NotFound" "500": $ref: "#/components/responses/InternalServerError" + x-code-samples: + - lang: Curl + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Host: api.am.wso2.com" + "https://api.am.wso2.com:9095/api/am/runtime/policies/1"' components: schemas: APIList: @@ -1092,10 +1162,10 @@ components: example: HTTP createdTime: type: string - example: 2021-02-11 09:57:25 + example: 2023-02-11 09:57:25 updatedTime: type: string - example: 2021-02-11 09:57:25 + example: 2023-02-11 09:57:25 API: title: API object required: @@ -1513,7 +1583,7 @@ components: $ref: "#/components/schemas/PortMapping" createdTime: type: string - example: 2021-02-11 09:57:25 + example: 2023-02-11 09:57:25 PortMapping: title: The PortMapping Object From ab829bd2987f79a5ee58b9ece155d50958e003ce Mon Sep 17 00:00:00 2001 From: Mariangela Date: Wed, 22 Mar 2023 19:37:58 +0530 Subject: [PATCH 3/9] added spacing after samples --- en/docs/catalogs/runtime-api.yaml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/en/docs/catalogs/runtime-api.yaml b/en/docs/catalogs/runtime-api.yaml index d8f2eaf3b..2e1da345f 100644 --- a/en/docs/catalogs/runtime-api.yaml +++ b/en/docs/catalogs/runtime-api.yaml @@ -247,10 +247,8 @@ paths: $ref: "#/components/responses/NotFound" "412": $ref: "#/components/responses/PreconditionFailed" - "500": $ref: "#/components/responses/InternalServerError" - x-code-samples: - lang: Curl source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" -H "Content-Type: application/json" -d @data.json @@ -375,7 +373,6 @@ paths: $ref: "#/components/responses/BadRequest" "500": $ref: "#/components/responses/InternalServerError" - x-code-samples: - lang: Curl source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/import-service?serviceKey=11cd3fa3-c886-49f9-bf78-0ec349b1f4c1" @@ -496,6 +493,7 @@ paths: -H "Accept: application/json" -H "Host: api.am.wso2.com" -F file=@openapi.json "https://api.am.wso2.com:9095/api/am/runtime/apis/validate-definition"' + /apis/validate: post: tags: @@ -538,7 +536,6 @@ paths: $ref: "#/components/responses/BadRequest" "412": $ref: "#/components/responses/PreconditionFailed" - "500": $ref: "#/components/responses/InternalServerError" x-code-samples: @@ -546,6 +543,7 @@ paths: source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis/validate?query=name%3Awso2"' + /apis/{apiId}/definition: get: tags: @@ -586,7 +584,6 @@ paths: $ref: "#/components/responses/NotFound" "412": $ref: "#/components/responses/PreconditionFailed" - "500": $ref: "#/components/responses/InternalServerError" x-code-samples: @@ -594,6 +591,7 @@ paths: source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' + put: tags: - APIs @@ -649,7 +647,6 @@ paths: $ref: "#/components/responses/NotFound" "412": $ref: "#/components/responses/PreconditionFailed" - "500": $ref: "#/components/responses/InternalServerError" x-code-samples: @@ -734,6 +731,7 @@ paths: -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis/export?apiId=96077508-fd01-4fae-bc64-5de0e2baf43c&name=PizzaShackAPI&version=1.0&provider=admin&format=YAML" > exportAPI.zip' + /apis/import: post: tags: @@ -766,16 +764,15 @@ paths: $ref: "#/components/responses/Forbidden" "409": $ref: "#/components/responses/Conflict" - "412": $ref: "#/components/responses/PreconditionFailed" - "500": $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" -F file=@admin-PizzaShackAPI-1.0.0.zip "https://api.am.wso2.com:9095/api/am/runtime/apis/import?preserveProvider=false&overwrite=false"' + /apis/copy-api: post: tags: @@ -982,6 +979,7 @@ paths: source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/services/11cd3fa3-c886-49f9-bf78-0ec349b1f4c1/usage"' + /policies: get: tags: @@ -1080,6 +1078,7 @@ paths: source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/policies"' + /policies/{policyId}: get: tags: @@ -1121,6 +1120,7 @@ paths: source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/policies/1"' + components: schemas: APIList: From 646d3a77644c8b1c8cc3a809e4ae74c69d9c3ca0 Mon Sep 17 00:00:00 2001 From: Mariangela Date: Thu, 23 Mar 2023 09:41:34 +0530 Subject: [PATCH 4/9] removed host header --- en/docs/catalogs/runtime-api.yaml | 43 ++++++++++++------------------- 1 file changed, 16 insertions(+), 27 deletions(-) diff --git a/en/docs/catalogs/runtime-api.yaml b/en/docs/catalogs/runtime-api.yaml index 2e1da345f..63d5c778e 100644 --- a/en/docs/catalogs/runtime-api.yaml +++ b/en/docs/catalogs/runtime-api.yaml @@ -93,7 +93,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis"' + "https://api.am.wso2.com:9095/api/am/runtime/apis"' post: tags: @@ -143,7 +143,7 @@ paths: source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -H "Accept: application/json" - -H "Host: api.am.wso2.com" -d @data.json + -d @data.json "https://api.am.wso2.com:9095/api/am/runtime/apis"' /apis/{apiId}: @@ -187,8 +187,7 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' put: @@ -251,8 +250,9 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" -H "Content-Type: application/json" -d @data.json - "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' + source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Content-Type: application/json" -d @data.json + "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' delete: tags: - APIs @@ -284,7 +284,7 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -X DELETE -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" + source: 'curl -k -X DELETE -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901"' /apis/{apiId}/generate-key: @@ -319,8 +319,7 @@ paths: source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/generate-key" -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" - -H "Accept: application/json" - -H "Host: api.am.wso2.com"' + -H "Accept: application/json"' /apis/import-service: post: @@ -379,7 +378,7 @@ paths: -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -H "Accept: application/json" - -H "Host: api.am.wso2.com" -d @data.json' + -d @data.json' /apis/import-definition: post: @@ -435,7 +434,7 @@ paths: -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -H "Accept: application/json" - -H "Host: api.am.wso2.com" -F file=@openapi.json -F additionalProperties=@data.json' + -F file=@openapi.json -F additionalProperties=@data.json' /apis/validate-definition: post: @@ -491,7 +490,6 @@ paths: source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -H "Accept: application/json" - -H "Host: api.am.wso2.com" -F file=@openapi.json "https://api.am.wso2.com:9095/api/am/runtime/apis/validate-definition"' /apis/validate: @@ -541,7 +539,6 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis/validate?query=name%3Awso2"' /apis/{apiId}/definition: @@ -588,8 +585,7 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" + source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' put: @@ -651,8 +647,7 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" + source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" -d @data.json "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' @@ -728,7 +723,6 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/apis/export?apiId=96077508-fd01-4fae-bc64-5de0e2baf43c&name=PizzaShackAPI&version=1.0&provider=admin&format=YAML" > exportAPI.zip' @@ -770,8 +764,9 @@ paths: $ref: "#/components/responses/InternalServerError" x-code-samples: - lang: Curl - source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Host: api.am.wso2.com" - -F file=@admin-PizzaShackAPI-1.0.0.zip "https://api.am.wso2.com:9095/api/am/runtime/apis/import?preserveProvider=false&overwrite=false"' + source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -F file=@admin-PizzaShackAPI-1.0.0.zip + "https://api.am.wso2.com:9095/api/am/runtime/apis/import?preserveProvider=false&overwrite=false"' /apis/copy-api: post: @@ -822,8 +817,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/copy-api?apiId=01234567-0123-0123-0123-012345678901&newVersion=2.0.0" - -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com"' + -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8"' /services: get: @@ -903,7 +897,6 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/services"' /services/{serviceId}: @@ -940,7 +933,6 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/services/11cd3fa3-c886-49f9-bf78-0ec349b1f4c1"' /services/{serviceId}/usage: @@ -977,7 +969,6 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/services/11cd3fa3-c886-49f9-bf78-0ec349b1f4c1/usage"' /policies: @@ -1076,7 +1067,6 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/policies"' /policies/{policyId}: @@ -1118,7 +1108,6 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Host: api.am.wso2.com" "https://api.am.wso2.com:9095/api/am/runtime/policies/1"' components: From 0e669166d745a3768e0f064ff2f3aa0a9fcb37be Mon Sep 17 00:00:00 2001 From: Mariangela Date: Thu, 23 Mar 2023 11:50:04 +0530 Subject: [PATCH 5/9] Updated based on feedback --- en/docs/catalogs/runtime-api.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/en/docs/catalogs/runtime-api.yaml b/en/docs/catalogs/runtime-api.yaml index 63d5c778e..59bf1b1f3 100644 --- a/en/docs/catalogs/runtime-api.yaml +++ b/en/docs/catalogs/runtime-api.yaml @@ -649,7 +649,7 @@ paths: - lang: Curl source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" - -d @data.json + -F apiDefinition=@swagger.json "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' /apis/export: get: From 0a3d3417f00f5e4babcc554be377e82300cfb6db Mon Sep 17 00:00:00 2001 From: Mariangela Date: Thu, 23 Mar 2023 18:27:47 +0530 Subject: [PATCH 6/9] Checked and updated messaging --- en/docs/catalogs/runtime-api.yaml | 198 +++++++++++++++--------------- 1 file changed, 100 insertions(+), 98 deletions(-) diff --git a/en/docs/catalogs/runtime-api.yaml b/en/docs/catalogs/runtime-api.yaml index 59bf1b1f3..e819c9583 100644 --- a/en/docs/catalogs/runtime-api.yaml +++ b/en/docs/catalogs/runtime-api.yaml @@ -3,7 +3,7 @@ openapi: 3.0.1 info: title: WSO2 API Platform for Kubernetes - Runtime Service API description: | - This document specifies a **RESTful API** for WSO2 **API Platform for Kubernetes(APK)** - **Runtime Service**. + This document specifies a **RESTful API** for WSO2 **API Platform for Kubernetes (APK)** - **Runtime Service**. version: 1.0.0 paths: /apis: @@ -53,7 +53,7 @@ paths: - name: sortOrder in: query description: | - Order of sorting(ascending/descending). + Order of sorting (ascending/descending). required: false style: form explode: true @@ -100,10 +100,10 @@ paths: - APIs summary: Create a New API description: | - This operation can be used to create a new API specifying the details of the API in the payload. + Use this operation to create a new API specifying the details of the API in the payload. operationId: createAPI requestBody: - description: API object that needs to be added + description: The API object that needs to be added. content: application/json: schema: @@ -113,7 +113,7 @@ paths: "201": description: | Created. - Successful response with the newly created object as entity in the body. + Successful response with the newly created object as the entity in the body. Location header contains URL of newly created entity. headers: Location: @@ -152,7 +152,7 @@ paths: - APIs summary: Get Details of an API description: | - Using this operation, you can retrieve complete details of a single API. You need to provide the id of the API to retrieve it. + Using this operation, you can retrieve complete details of a single API. You need to provide the ID of the API to retrieve it. operationId: getAPI parameters: - name: apiId @@ -195,7 +195,7 @@ paths: - APIs summary: Update an API description: | - This operation can be used to update an existing API. This operation will instruct runtime to update deployment. + Use this operation to update an existing API. This operation will instruct the Runtime to update the deployment. operationId: updateAPI parameters: - name: apiId @@ -208,7 +208,7 @@ paths: schema: type: string requestBody: - description: API object that needs to be added + description: The API object that needs to be added. content: application/json: schema: @@ -218,7 +218,7 @@ paths: "200": description: | OK. - Successful response with updated API object + Successful response with an updated API object. headers: Location: description: | @@ -258,7 +258,7 @@ paths: - APIs summary: Delete an API description: | - This operation can be used to delete an existing API proving the Id of the API. + Use this operation to delete an existing API by providing the ID of the API. operationId: deleteAPI parameters: - name: apiId @@ -291,9 +291,9 @@ paths: post: tags: - APIs - summary: Generate internal API Key to invoke APIS + summary: Generate Internal API Key to Invoke APIs description: | - This operation can be used to generate internal API key which used to invoke API. + Use this operation to generate an internal API key that you can use to invoke API. operationId: generateInternalAPIKey parameters: - $ref: "#/components/parameters/apiId" @@ -325,13 +325,13 @@ paths: post: tags: - Service or Schema Import - summary: Create API from a Service - description: This operation can be used to create an API from available Service by providing service + summary: Create an API From a Service + description: Use this operation to create an API from an available Service by providing Service. operationId: importService parameters: - name: serviceKey in: query - description: ID of service that should be imported from Service Catalog + description: The ID of the Service that should be imported from the Service Catalog. required: true style: form explode: true @@ -347,7 +347,7 @@ paths: "201": description: | Created. - Successful response with the newly created object as entity in the body. + Successful response with the newly created object as the entity in the body. Location header contains the URL of the newly created entity. headers: Location: @@ -386,10 +386,10 @@ paths: - Service or Schema Import summary: Import an API Definition description: | - This operation can be used to create an API from an API definition. Provide either `url` or `file` + Use this operation to create an API from an API definition. Provide either the `url` or `file` to specify the definition. - Specify additionalProperties with **at least** API's name, version, context and endpointConfig. + Specify `additionalProperties`` with **at least** the API's name, version, context and endpointConfig. operationId: importAPIDefinition requestBody: content: @@ -442,7 +442,7 @@ paths: - Validation summary: Validate an OpenAPI Definition description: | - This operation can be used to validate an OpenAPI definition and retrieve a summary. Provide either `url` + Use this operation to validate an OpenAPI definition and retrieve a summary. Provide either the `url` or `file` to specify the definition. operationId: validateOpenAPIDefinition parameters: @@ -450,7 +450,7 @@ paths: in: query description: | Specify whether to return the full content of the OpenAPI definition in the response. This is only - applicable when using url based validation + applicable when using URL based validation. required: false style: form explode: true @@ -466,7 +466,7 @@ paths: "200": description: | OK. - API definition validation information is returned + API definition validation information is returned. headers: Content-Type: description: | @@ -496,9 +496,9 @@ paths: post: tags: - Validation - summary: Check Given API Context Name already Exists + summary: Check if the Given API Context Name Already Exists description: | - Using this operation, you can check a given API context is already used. You need to provide the context name you want to check. + You can use this operation to check if a given API context is already being used. You need to provide the context name you want to check. operationId: validateAPI parameters: - name: query @@ -506,9 +506,10 @@ paths: description: | **Search condition**. You can search in attributes by using an **":"** modifier. - Eg. + + Example: "name:wso2" will match an API if the provider of the API is exactly "wso2". - Supported attribute modifiers are [** version, context, name **] + The supported attribute modifiers are `version`, `context`, `name` If no advanced attribute modifier has been specified, search will match the given query string against API Name. required: true @@ -547,7 +548,7 @@ paths: - APIs summary: Get API Definition description: | - This operation can be used to retrieve the definition of an API. + Use this operation to retrieve the definition of an API. operationId: getAPIDefinition parameters: - name: apiId @@ -563,7 +564,7 @@ paths: "200": description: | OK. - Requested definition document of the API is returned + The requested definition document of the API is returned. headers: Content-Type: description: | @@ -593,7 +594,7 @@ paths: - APIs summary: Update API Definition description: | - This operation can be used to update the API definition of an existing API. API definition to be updated is passed as a form data parameter `apiDefinition`. + Use this operation to update the API definition of an existing API. API definition to be updated is passed as a form data parameter `apiDefinition`. operationId: updateAPIDefinition parameters: - name: apiId @@ -614,7 +615,7 @@ paths: "200": description: | OK. - Successful response with updated Swagger definition + Successful response with updated Open API Specification. headers: Location: description: | @@ -649,7 +650,7 @@ paths: - lang: Curl source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" -H "Content-Type: application/json" - -F apiDefinition=@swagger.json + -F apiDefinition=@oaspecification.json "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' /apis/export: get: @@ -657,7 +658,7 @@ paths: - Import Export summary: Export an API description: | - This operation can be used to export the details of a particular API as a zip file. + Use this operation to export the details of a particular API as a ZIP file. operationId: exportAPI parameters: - name: apiId @@ -689,7 +690,7 @@ paths: - name: format in: query description: | - Format of output documents. Can be YAML or JSON. + Format of output documents. This can be YAML or JSON. required: false style: form explode: true @@ -732,13 +733,13 @@ paths: - Import Export summary: Import an API description: | - This operation can be used to import an API. + Use this operation to import an API. operationId: importAPI parameters: - name: overwrite in: query description: | - Whether to update the API or not. This is used when updating already existing APIs + Whether to update the API or not. Use this when updating already existing APIs. required: false style: form explode: true @@ -774,7 +775,7 @@ paths: - APIs summary: Create a New API Version description: | - This operation can be used to create a new version of an existing API. The new version is specified as `newVersion` query parameter. New API will be in `CREATED` state. + Use this operation to create a new version of an existing API. The new version is specified as `newVersion` query parameter. New API will be in `CREATED` state. parameters: - name: newVersion in: query @@ -785,7 +786,7 @@ paths: type: string - name: serviceId in: query - description: Version of the Service that will used in creating new version + description: Version of the Service that you are using to create a new API version. schema: type: string required: false @@ -794,7 +795,7 @@ paths: 201: description: | Created. - Successful response with the newly created API as entity in the body. Location header contains URL of newly created API. + Successful response with the newly created API as the entity in the body. Location header contains the URL of the newly created API. headers: Location: description: | @@ -816,14 +817,14 @@ paths: operationId: createNewAPIVersion x-code-samples: - lang: Curl - source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/copy-api?apiId=01234567-0123-0123-0123-012345678901&newVersion=2.0.0" + source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/copy-api?apiId=01234567-0123-0123-0123-012345678901&newVersion=2.0.0" -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8"' /services: get: tags: - Services - summary: Retrieve/search services + summary: Retrieve/Search for Services description: | Retrieve or search services in the Cluster. operationId: searchServices @@ -852,7 +853,7 @@ paths: - name: sortOrder in: query description: | - Order of sorting(ascending/descending). + Order of sorting (ascending/descending). required: false style: form explode: true @@ -885,7 +886,7 @@ paths: responses: "200": description: | - Paginated matched list of services returned. + Paginated matched list of Services returned. content: application/json: schema: @@ -903,14 +904,14 @@ paths: get: tags: - Services - summary: Get details of a service + summary: Get Details of a Service description: | - Get details of a service using the id of the service. + Get details of a Service using the ID of the Service. operationId: getServiceById parameters: - name: serviceId in: path - description: UUID (unique across all namespaces) of the service + description: UUID (unique across all namespaces) of the Service required: true style: simple explode: false @@ -919,7 +920,7 @@ paths: responses: "200": description: | - Requested service in the Service Catalog is returned. + Requested Service in the Service Catalog is returned. content: application/json: schema: @@ -939,14 +940,14 @@ paths: get: tags: - Services - summary: Retrieve the usage of service + summary: Retrieve the Usage of a Service description: | Retrieve usage operationId: getServiceUsage parameters: - name: serviceId in: path - description: UUID(unique id across cluster) of the service + description: UUID (unique ID across cluster) of the Service required: true style: simple explode: false @@ -955,7 +956,7 @@ paths: responses: "200": description: | - List of APIs that uses the service in the Service Catalog is returned. + List of APIs that uses the Service in the Service Catalog is returned. content: application/json: schema: @@ -976,9 +977,9 @@ paths: tags: - Mediation Policies summary: | - Get all common mediation policies to all the APIs + Get All Common Mediation Policies For All the APIs description: | - This operation provides you a list of available operation Policies that can be used by any API + This operation provides you a list of the available Operation Policies that any API can use. operationId: getMediationPolicyList parameters: - name: limit @@ -1017,7 +1018,7 @@ paths: - name: sortOrder in: query description: | - Order of sorting(ascending/descending). + Order of sorting (ascending/descending). required: false style: form explode: true @@ -1037,7 +1038,7 @@ paths: - name: Accept in: header description: | - Media types acceptable for the response. Default is application/json. + Media types acceptable for the response. required: false style: simple explode: false @@ -1048,7 +1049,7 @@ paths: "200": description: | OK. - List of qualifying policies is returned. + List of qualifying Policies is returned. headers: Content-Type: description: The content type of the body. @@ -1073,14 +1074,14 @@ paths: get: tags: - Mediation Policies - summary: Get the details of a common mediation policy by providing mediation policy ID + summary: Get Details of a Specific Common Mediation Policy description: | - This operation can be used to retrieve a particular common mediation policy. + Use this operation to retrieve details of a specific Common Mediation Policy based on its Mediation Policy ID. operationId: getMediationPolicyByPolicyId parameters: - name: policyId in: path - description: Mediation policy Id + description: Mediation policy ID required: true style: simple explode: false @@ -1188,24 +1189,19 @@ components: example: 1.0.0 type: type: string - description: The api creation type to be used. Accepted values are REST, WS, GRAPHQL, WEBSUB, SSE, WEBHOOK, ASYNC + description: The API creation type. example: REST default: REST enum: - REST - - WS - - GRAPHQL - - WEBSUB - - SSE - - WEBHOOK - - ASYNC endpointConfig: type: object properties: {} description: | - Endpoint configuration of the API. This can be used to provide different types of endpoints including Simple REST Endpoints, Loadbalanced and Failover. + Endpoint configuration of the API. You can use this to provide different types of endpoints including Simple REST Endpoints, Loadbalanced and Failover. `Simple REST Endpoint` + ``` { "endpoint_type": "http", "sandbox_endpoints": { @@ -1215,6 +1211,7 @@ components: "url": "https://pizzashack-service:8080/am/sample/pizzashack/v3/api/" } } + ``` example: endpoint_type: http sandbox_endpoints: @@ -1259,14 +1256,18 @@ components: type: boolean example: true default: true - description: Authentication mode for resource (true/false) + description: Authentication mode for resource. + enum: + - true + - false endpointConfig: type: object properties: {} description: | - Endpoint configuration of the API. This can be used to provide different types of endpoints including Simple REST Endpoints, Loadbalanced and Failover. + Endpoint configuration of the API. You can use this to provide different types of endpoints including Simple REST Endpoints, Loadbalanced and Failover. `Simple REST Endpoint` + ``` { "endpoint_type": "http", "sandbox_endpoints": { @@ -1276,6 +1277,7 @@ components: "url": "https://pizzashack-service:8080/am/sample/pizzashack/v3/api/" } } + ``` example: endpoint_type: http sandbox_endpoints: @@ -1377,7 +1379,7 @@ components: example: Add Header description: type: string - example: With this policy, user can add a new header to the request + example: The user can add a new header to the request using this policy. applicableFlows: type: array items: @@ -1406,11 +1408,11 @@ components: example: Name of the header to be added required: type: boolean - description: Is this option mandatory for the policy + description: This defines whether or not this option is mandatory for the Policy example: true validationRegex: type: string - description: UI validation regex for the attribute + description: UI validation Regex for the attribute type: type: string description: Type of the attribute @@ -1435,15 +1437,15 @@ components: description: type: string description: | - A detail description about the error message. + A detailed description of the error message. moreInfo: type: string description: | - Preferably an url with more details about the error. + Preferably a URL with more details about the error. error: type: array description: | - If there are more than one error list them out. + If there is more than one error, list them out. For example, list out validation errors by each field. items: $ref: "#/components/schemas/ErrorListItem" @@ -1459,11 +1461,11 @@ components: message: type: string description: | - Description about individual errors occurred + A description on the individual errors that occurred. description: type: string description: | - A detail description about the error message. + A detailed description of the error message. APIDefinitionValidationResponse: title: API Definition Validation Response required: @@ -1484,7 +1486,7 @@ components: errors: type: array description: | - If there are more than one error list them out. + If there is more than one error, list them out. For example, list out validation errors by each field. items: $ref: "#/components/schemas/ErrorListItem" @@ -1631,7 +1633,7 @@ components: example: HTTP port: type: number - description: Port of the Listener + description: Port of the Listener. example: 8080 apis_importdefinition_body: properties: @@ -1641,11 +1643,11 @@ components: format: string file: type: string - description: Definition to upload as a file + description: Definition to upload as a file. format: binary url: type: string - description: Definition url + description: Definition URL additionalProperties: type: string description: Additional attributes specified as a stringified JSON with API's schema @@ -1656,7 +1658,7 @@ components: properties: url: type: string - description: API definition definition url + description: API definition definition URL file: type: string description: API definition as a file @@ -1666,18 +1668,18 @@ components: description: API definition type - OpenAPI/AsyncAPI/GraphQL inlineAPIDefinition: type: string - description: Inline content of the API definition + description: Inline content of the API definition. apiId_definition_body: properties: apiDefinition: type: string - description: API definition of the API + description: API definition of the API. url: type: string - description: API definition URL of the API + description: API definition URL of the API. file: type: string - description: API definition as a file + description: API definition as a file. format: binary apis_import_body: required: @@ -1685,7 +1687,7 @@ components: properties: file: type: string - description: Zip archive consisting on exported API configuration + description: ZIP archive consisting of exported API configuration. format: binary API_serviceInfo: type: object @@ -1718,7 +1720,7 @@ components: Context of the API description: type: string - example: A sample API that uses a petstore as an example to demonstrate swagger-2.0 specification + example: A sample API that uses a petstore as an example to demonstrate OpenAPI Specification 2.0 description: | Description of the API openAPIVersion: @@ -1779,7 +1781,7 @@ components: example: code: 403 message: Forbidden - description: The request must be conditional but no condition has been specified + description: The request must be conditional but no condition has been specified. moreInfo: "" error: [] InternalServerError: @@ -1791,7 +1793,7 @@ components: example: code: 500 message: Internal Server Error - description: The server encountered an internal error. Please contact administrator. + description: The server encountered an internal error. Please contact the Administrator. moreInfo: "" error: [] NotAcceptable: @@ -1803,7 +1805,7 @@ components: example: code: 406 message: Not Acceptable - description: The requested media type is not supported + description: The requested media type is not supported. moreInfo: "" error: [] NotFound: @@ -1815,11 +1817,11 @@ components: example: code: 404 message: Not Found - description: The specified resource does not exist + description: The specified resource does not exist. moreInfo: "" error: [] PreconditionFailed: - description: Precondition Failed. The request has not been performed because one of the preconditions is not met. + description: Precondition Failed. The request has not been performed because one of the preconditions was not met. content: application/json: schema: @@ -1827,7 +1829,7 @@ components: example: code: 412 message: Precondition Failed - description: The request has not been performed because one of the preconditions is not met + description: The request has not been performed because one of the preconditions was not met. moreInfo: "" error: [] Unauthorized: @@ -1839,7 +1841,7 @@ components: example: code: 401 message: Unauthorized - description: The user is not authorized + description: The user is not authorized. moreInfo: "" error: [] UnsupportedMediaType: @@ -1851,7 +1853,7 @@ components: example: code: 415 message: Unsupported media type - description: The entity of the request was not in a supported format + description: The entity of the request was not in a supported format. moreInfo: "" error: [] parameters: @@ -1870,7 +1872,7 @@ components: in: query description: | **API ID** consisting of the **UUID** of the API. - The combination of the provider of the API, name of the API and the version is also accepted as a valid API I. + The combination of the provider of the API, name of the API, and the version is also accepted as a valid API ID. Should be formatted as **provider-name-version**. required: true schema: @@ -1948,7 +1950,7 @@ components: name: sortOrder in: query description: | - Order of sorting(ascending/descending). + Order of sorting (ascending/descending). required: false style: form explode: true @@ -1961,7 +1963,7 @@ components: serviceId: name: serviceId in: path - description: name of the service + description: Name of the Service. required: true style: simple explode: false @@ -1970,7 +1972,7 @@ components: gatewayId: name: gatewayId in: path - description: name of the gateway + description: Name of the Gateway. required: true style: simple explode: false @@ -1979,7 +1981,7 @@ components: policyId: name: policyId in: path - description: policy uuid + description: Policy UUID required: true style: simple explode: false From b95c5b22412b8720cfeab058531b91b611e123a5 Mon Sep 17 00:00:00 2001 From: Mariangela Date: Fri, 24 Mar 2023 05:26:10 +0530 Subject: [PATCH 7/9] added multiform header --- en/docs/catalogs/runtime-api.yaml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/en/docs/catalogs/runtime-api.yaml b/en/docs/catalogs/runtime-api.yaml index e819c9583..2e65e8e0c 100644 --- a/en/docs/catalogs/runtime-api.yaml +++ b/en/docs/catalogs/runtime-api.yaml @@ -432,8 +432,7 @@ paths: - lang: Curl source: 'curl -k -X POST "https://api.am.wso2.com:9095/api/am/runtime/apis/import-definition" -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: application/json" - -H "Accept: application/json" + -H "Content-Type: multipart/form-data" -F file=@openapi.json -F additionalProperties=@data.json' /apis/validate-definition: @@ -488,8 +487,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: application/json" - -H "Accept: application/json" + -H "Content-Type: multipart/form-data" -F file=@openapi.json "https://api.am.wso2.com:9095/api/am/runtime/apis/validate-definition"' /apis/validate: @@ -649,7 +647,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: application/json" + -H "Content-Type: multipart/form-data" -F apiDefinition=@oaspecification.json "https://api.am.wso2.com:9095/api/am/runtime/apis/01234567-0123-0123-0123-012345678901/definition"' /apis/export: @@ -766,6 +764,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" + -H "Content-Type: multipart/form-data" -F file=@admin-PizzaShackAPI-1.0.0.zip "https://api.am.wso2.com:9095/api/am/runtime/apis/import?preserveProvider=false&overwrite=false"' From 42ab04c4810bbd90aefab7a1a761717931c907cc Mon Sep 17 00:00:00 2001 From: Mariangela Date: Fri, 24 Mar 2023 05:59:50 +0530 Subject: [PATCH 8/9] updated x-code-samples --- en/docs/catalogs/backoffice-api.yaml | 68 ++++++++++++++-------------- 1 file changed, 34 insertions(+), 34 deletions(-) diff --git a/en/docs/catalogs/backoffice-api.yaml b/en/docs/catalogs/backoffice-api.yaml index 45947d781..ed8ea5026 100644 --- a/en/docs/catalogs/backoffice-api.yaml +++ b/en/docs/catalogs/backoffice-api.yaml @@ -106,7 +106,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis"' operationId: getAllAPIs ###################################################### @@ -163,7 +163,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/7a2298c4-c905-403f-8fac-38c73301631f"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901"' operationId: getAPI put: tags: @@ -228,7 +228,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: application/json" -d @data.json "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33"' + -H "Content-Type: application/json" -d @data.json "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901"' operationId: updateAPI /apis/{apiId}/definition: @@ -283,7 +283,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/7a2298c4-c905-403f-8fac-38c73301631f/definition"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/definition"' operationId: getAPIDefinition /apis/{apiId}/resource-paths: @@ -341,7 +341,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/96077508-fd01-4fae-bc64-5de0e2baf43c/resource-paths"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/resource-paths"' operationId: getAPIResourcePaths /apis/{apiId}/thumbnail: @@ -396,7 +396,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33/thumbnail" + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/thumbnail" > image.jpeg' operationId: getAPIThumbnail @@ -466,7 +466,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: multipart/form-data" -F file=@image.jpeg "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/d48a3412-1b85-49be-99f4-b81a3722ae73/thumbnail"' + -H "Content-Type: multipart/form-data" -F file=@image.jpeg "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/thumbnail"' operationId: updateAPIThumbnail /apis/{apiId}/documents: @@ -518,7 +518,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33/documents"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/documents"' operationId: getAPIDocuments post: @@ -574,7 +574,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: application/json" -d @data.json "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33/documents"' + -H "Content-Type: application/json" -d @data.json "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/documents"' operationId: addAPIDocument /apis/{apiId}/documents/{documentId}: @@ -632,7 +632,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33/documents/83312daf-0d8a-427b-8f72-12755b7901d3"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/documents/83312daf-0d8a-427b-8f72-12755b7901d3"' operationId: getAPIDocument put: @@ -697,7 +697,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X PUT -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: application/json" -d @data.json "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33/documents/83312daf-0d8a-427b-8f72-12755b7901d3"' + -H "Content-Type: application/json" -d @data.json "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/documents/83312daf-0d8a-427b-8f72-12755b7901d3"' operationId: updateAPIDocument delete: @@ -727,7 +727,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X DELETE -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33/documents/83312daf-0d8a-427b-8f72-12755b7901d3"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/documents/83312daf-0d8a-427b-8f72-12755b7901d3"' operationId: deleteAPIDocument /apis/{apiId}/documents/{documentId}/content: @@ -743,7 +743,7 @@ paths: 1. **Inline type**: The content of the document will be retrieved in `text/plain` content type - _Sample cURL_ : `curl -k -H "Authorization:Bearer 579f0af4-37be-35c7-81a4-f1f1e9ee7c51" -F inlineContent=@"docs.txt" -X POST "https://localhost:9443/api/apk/backoffice/v1/apis/995a4972-3178-4b17-a374-756e0e19127c/documents/43c2bcce-60e7-405f-bc36-e39c0c5e189e/content` + _Sample cURL_ : `curl -k -H "Authorization:Bearer 579f0af4-37be-35c7-81a4-f1f1e9ee7c51" -F inlineContent=@"docs.txt" -X POST "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/documents/43c2bcce-60e7-405f-bc36-e39c0c5e189e/content` 2. **FILE type**: The file will be downloaded with the related content type (eg. `application/pdf`) 3. **URL type**: @@ -804,7 +804,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33/documents/83312daf-0d8a-427b-8f72-12755b7901d3/content"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/documents/83312daf-0d8a-427b-8f72-12755b7901d3/content"' operationId: getAPIDocumentContent post: @@ -879,7 +879,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: multipart/form-data" -F file=@sample.pdf "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/5bca47e1-8233-46a5-9295-525dca337f33/documents/83312daf-0d8a-427b-8f72-12755b7901d3/content"' + -H "Content-Type: multipart/form-data" -F file=@sample.pdf "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/documents/83312daf-0d8a-427b-8f72-12755b7901d3/content"' operationId: addAPIDocumentContent /apis/{apiId}/comments: @@ -916,7 +916,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://localhost:9443/api/apk/backoffice/v1/apis/e93fb282-b456-48fc-8981-003fb89086ae/comments"' + "https://localhost:9443/api/apk/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/comments"' post: tags: @@ -1042,7 +1042,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization:Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://localhost:9443/api/apk/backoffice/v1/apis/e93fb282-b456-48fc-8981-003fb89086ae/comments/d4cf1704-5d09-491c-bc48-4d19ce6ea9b4"' + "https://localhost:9443/api/apk/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/comments/d4cf1704-5d09-491c-bc48-4d19ce6ea9b4"' patch: tags: @@ -1114,7 +1114,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X PATCH -H "Authorization:Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - -H "Content-Type: application/json" -d @data.json "https://localhost:9443/api/apk/backoffice/v1/apis/e93fb282-b456-48fc-8981-003fb89086ae/comments/d4cf1704-5d09-491c-bc48-4d19ce6ea9b4"' + -H "Content-Type: application/json" -d @data.json "https://localhost:9443/api/apk/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/comments/d4cf1704-5d09-491c-bc48-4d19ce6ea9b4"' delete: tags: @@ -1154,7 +1154,7 @@ paths: x-code-samples: - lang: Curl source: curl -k -X DELETE -H "Authorization:Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://localhost:9443/api/apk/backoffice/v1/apis/e93fb282-b456-48fc-8981-003fb89086ae/comments/d4cf1704-5d09-491c-bc48-4d19ce6ea9b4" + "https://localhost:9443/api/apk/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/comments/d4cf1704-5d09-491c-bc48-4d19ce6ea9b4" /apis/{apiId}/comments/{commentId}/replies: get: @@ -1209,7 +1209,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization:Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://localhost:9443/api/apk/backoffice/v1/apis/e93fb282-b456-48fc-8981-003fb89086ae/comments/d4cf1704-5d09-491c-bc48-4d19ce6ea9b4/replies"' + "https://localhost:9443/api/apk/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/comments/d4cf1704-5d09-491c-bc48-4d19ce6ea9b4/replies"' ###################################################### @@ -1224,10 +1224,10 @@ paths: This operation can be used to retrieve a list of subscriptions of the user associated with the provided access token. This operation is capable of 1. Retrieving all subscriptions for the user's APIs. - `GET https://127.0.0.1:9443/api/apk/backoffice/v1/subscriptions` + `GET https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions` 2. Retrieving subscriptions for a specific API. - `GET https://127.0.0.1:9443/api/apk/backoffice/v1/subscriptions?apiId=c43a325c-260b-4302-81cb-768eafaa3aed` + `GET https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions?apiId=c43a325c-260b-4302-81cb-768eafaa3aed` parameters: - $ref: '#/components/parameters/apiId-Q-Opt' - $ref: '#/components/parameters/limit' @@ -1275,7 +1275,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/subscriptions?apiId=96077508-fd01-4fae-bc64-5de0e2baf43c"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions?apiId=96077508-fd01-4fae-bc64-5de0e2baf43c"' operationId: getSubscriptions /subscriptions/{subscriptionId}/subscriber-info: @@ -1306,7 +1306,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/subscriptions/64eca60b-2e55-4c38-8603-e9e6bad7d809/subscriber-info"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions/64eca60b-2e55-4c38-8603-e9e6bad7d809/subscriber-info"' operationId: getSubscriberInfoBySubscriptionId /subscriptions/block-subscription: @@ -1364,7 +1364,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/subscriptions/block-subscription?subscriptionId=64eca60b-2e55-4c38-8603-e9e6bad7d809&blockState=PROD_ONLY_BLOCKED"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions/block-subscription?subscriptionId=64eca60b-2e55-4c38-8603-e9e6bad7d809&blockState=PROD_ONLY_BLOCKED"' operationId: blockSubscription /subscriptions/unblock-subscription: @@ -1409,7 +1409,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/subscriptions/unblock-subscription?subscriptionId=64eca60b-2e55-4c38-8603-e9e6bad7d809"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions/unblock-subscription?subscriptionId=64eca60b-2e55-4c38-8603-e9e6bad7d809"' operationId: unBlockSubscription @@ -1462,7 +1462,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/usage-plans"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/usage-plans"' ###################################################### # The "Content Search Results" resource APIs @@ -1520,7 +1520,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/search?query=pizza"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/search?query=pizza"' operationId: search ###################################################### @@ -1551,7 +1551,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/am/backoffice/v1/settings"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/settings"' operationId: getSettings ###################################################### @@ -1580,7 +1580,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/api-categories"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/api-categories"' operationId: getAllAPICategories /apis/change-lifecycle: @@ -1636,7 +1636,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/change-lifecycle?apiId=890a4f4d-09eb-4877-a323-57f6ce2ed79b&action=Publish"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/change-lifecycle?apiId=890a4f4d-09eb-4877-a323-57f6ce2ed79b&action=Publish"' operationId: changeAPILifecycle /apis/{apiId}/lifecycle-history: @@ -1671,7 +1671,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/890a4f4d-09eb-4877-a323-57f6ce2ed79b/lifecycle-history"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/890a4f4d-09eb-4877-a323-57f6ce2ed79b/lifecycle-history"' operationId: getAPILifecycleHistory /apis/{apiId}/lifecycle-state: @@ -1707,7 +1707,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/apk/backoffice/v1/apis/890a4f4d-09eb-4877-a323-57f6ce2ed79b/lifecycle-state"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/890a4f4d-09eb-4877-a323-57f6ce2ed79b/lifecycle-state"' operationId: getAPILifecycleState ###################################################### # The "Business Plans Collection" resource API @@ -1745,7 +1745,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://127.0.0.1:9443/api/am/admin/business-plans"' + "https://api.am.wso2.com:9095/api/am/admin/business-plans"' operationId: getAllBusinessPlans components: schemas: From f48c344e61eb60fb120fb28a28769b5a96683640 Mon Sep 17 00:00:00 2001 From: Mariangela Date: Fri, 24 Mar 2023 07:26:22 +0530 Subject: [PATCH 9/9] updated x-code-samples part2 --- en/docs/catalogs/backoffice-api.yaml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/en/docs/catalogs/backoffice-api.yaml b/en/docs/catalogs/backoffice-api.yaml index ed8ea5026..33a188810 100644 --- a/en/docs/catalogs/backoffice-api.yaml +++ b/en/docs/catalogs/backoffice-api.yaml @@ -1227,7 +1227,7 @@ paths: `GET https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions` 2. Retrieving subscriptions for a specific API. - `GET https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions?apiId=c43a325c-260b-4302-81cb-768eafaa3aed` + `GET https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions?apiId=01234567-0123-0123-0123-012345678901` parameters: - $ref: '#/components/parameters/apiId-Q-Opt' - $ref: '#/components/parameters/limit' @@ -1275,7 +1275,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions?apiId=96077508-fd01-4fae-bc64-5de0e2baf43c"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/subscriptions?apiId=01234567-0123-0123-0123-012345678901"' operationId: getSubscriptions /subscriptions/{subscriptionId}/subscriber-info: @@ -1636,7 +1636,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -X POST -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/change-lifecycle?apiId=890a4f4d-09eb-4877-a323-57f6ce2ed79b&action=Publish"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/change-lifecycle?apiId=01234567-0123-0123-0123-012345678901&action=Publish"' operationId: changeAPILifecycle /apis/{apiId}/lifecycle-history: @@ -1671,14 +1671,14 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/890a4f4d-09eb-4877-a323-57f6ce2ed79b/lifecycle-history"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/lifecycle-history"' operationId: getAPILifecycleHistory /apis/{apiId}/lifecycle-state: get: tags: - API Lifecycle - summary: Get Lifecycle State Data of the API. + summary: Get Lifecycle State Data of the API description: | This operation can be used to retrieve Lifecycle state data of the API. parameters: @@ -1707,7 +1707,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/890a4f4d-09eb-4877-a323-57f6ce2ed79b/lifecycle-state"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/apis/01234567-0123-0123-0123-012345678901/lifecycle-state"' operationId: getAPILifecycleState ###################################################### # The "Business Plans Collection" resource API @@ -1718,7 +1718,7 @@ paths: - Business Plan (Collection) summary: Get all Business Plans description: | - This operation can be used to retrieve all Business Plans. + This operation can be used to retrieve all Business Plans parameters: - $ref: '#/components/parameters/Accept' responses: @@ -1745,7 +1745,7 @@ paths: x-code-samples: - lang: Curl source: 'curl -k -H "Authorization: Bearer ae4eae22-3f65-387b-a171-d37eaa366fa8" - "https://api.am.wso2.com:9095/api/am/admin/business-plans"' + "https://api.am.wso2.com:9095/api/am/backoffice/v1/business-plans"' operationId: getAllBusinessPlans components: schemas: