From f358e71e3af6d99cc9e59fd4fb66c634b8c79cd9 Mon Sep 17 00:00:00 2001 From: AsabuHere Date: Mon, 22 Jul 2024 13:14:38 +0530 Subject: [PATCH] Removing pascal case rule for query and path params. Changing the spec files for orgs api --- spec/json/twilio_iam_organizations.json | 16 ++++++++-------- spec/yaml/twilio_iam_organizations.yaml | 16 ++++++++-------- spectral.yaml | 11 ----------- 3 files changed, 16 insertions(+), 27 deletions(-) diff --git a/spec/json/twilio_iam_organizations.json b/spec/json/twilio_iam_organizations.json index 097bdd84..39727f67 100644 --- a/spec/json/twilio_iam_organizations.json +++ b/spec/json/twilio_iam_organizations.json @@ -71,7 +71,7 @@ } }, { - "name": "Filter", + "name": "filter", "in": "query", "schema": { "type": "string" @@ -2042,7 +2042,7 @@ } }, { - "name": "Scope", + "name": "scope", "in": "query", "required": false, "schema": { @@ -2559,7 +2559,7 @@ "operationId": "FetchAuthorize", "parameters": [ { - "name": "Response_type", + "name": "response_type", "in": "query", "description": "Response Type", "schema": { @@ -2568,7 +2568,7 @@ } }, { - "name": "Client_id", + "name": "client_id", "in": "query", "description": "The Client Identifier", "schema": { @@ -2577,7 +2577,7 @@ } }, { - "name": "Redirect_uri", + "name": "redirect_uri", "in": "query", "description": "The url to which response will be redirected to", "schema": { @@ -2586,7 +2586,7 @@ } }, { - "name": "Scope", + "name": "scope", "in": "query", "description": "The scope of the access request", "schema": { @@ -2595,7 +2595,7 @@ } }, { - "name": "State", + "name": "state", "in": "query", "description": "An opaque value which can be used to maintain state between the request and callback", "schema": { @@ -2614,7 +2614,7 @@ "examples": { "fetch": { "value": { - "redirect_to": "https://www.twilio.com/authorize?Response_type=code&Client_id=OQ7cda1a615f05a95634e643aaaf7081d7&Redirect_uri=www.twilio.com&Scope=offline_access&State=xvz" + "redirect_to": "https://www.twilio.com/authorize?response_type=code&client_id=OQ7cda1a615f05a95634e643aaaf7081d7&redirect_uri=www.twilio.com&scope=offline_access&state=xvz" } } } diff --git a/spec/yaml/twilio_iam_organizations.yaml b/spec/yaml/twilio_iam_organizations.yaml index 46a41c0a..fc057545 100644 --- a/spec/yaml/twilio_iam_organizations.yaml +++ b/spec/yaml/twilio_iam_organizations.yaml @@ -41,7 +41,7 @@ paths: type: string format: OrganizationSid example: OR33f4f3aa6fffe840d000f8ef22e883db - - name: Filter + - name: filter in: query schema: type: string @@ -1365,7 +1365,7 @@ paths: type: string format: Sid example: USa36de9717566c7eb6363671f54b87ba9 - - name: Scope + - name: scope in: query required: false schema: @@ -1712,31 +1712,31 @@ paths: summary: Retrieves authorize uri operationId: FetchAuthorize parameters: - - name: Response_type + - name: response_type in: query description: Response Type schema: type: string example: code - - name: Client_id + - name: client_id in: query description: The Client Identifier schema: type: string example: OQ7cda1a615f05a95634e643aaaf7081d7 - - name: Redirect_uri + - name: redirect_uri in: query description: The url to which response will be redirected to schema: type: string example: www.twilio.com - - name: Scope + - name: scope in: query description: The scope of the access request schema: type: string example: offline_access - - name: State + - name: state in: query description: An opaque value which can be used to maintain state between the request and callback @@ -1752,7 +1752,7 @@ paths: examples: fetch: value: - redirect_to: https://www.twilio.com/authorize?Response_type=code&Client_id=OQ7cda1a615f05a95634e643aaaf7081d7&Redirect_uri=www.twilio.com&Scope=offline_access&State=xvz + redirect_to: https://www.twilio.com/authorize?response_type=code&client_id=OQ7cda1a615f05a95634e643aaaf7081d7&redirect_uri=www.twilio.com&scope=offline_access&state=xvz description: Found /v1/token: servers: diff --git a/spectral.yaml b/spectral.yaml index a3104866..2ca50bf7 100644 --- a/spectral.yaml +++ b/spectral.yaml @@ -23,17 +23,6 @@ rules: functionOptions: type: pascal - pascal-case-param-name-rule: - severity: error - recommended: true - message: Path parameter names should be capitalized. - type: style - given: "$.paths.[*].parameters.[*].name" - then: - function: pattern - functionOptions: - match: "^[A-Z].*" - require-openapi-rule: severity: error message: openapi field must be present with a non empty value