From f4cb30013bf8fc649514d7dc43cd8298fdfd5c5b Mon Sep 17 00:00:00 2001 From: VijayKesharwani <122533719+VijayKesharwani@users.noreply.github.com> Date: Tue, 7 Nov 2023 11:50:38 +0530 Subject: [PATCH] Update .spectral-oas.yml --- .spectral-oas.yml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/.spectral-oas.yml b/.spectral-oas.yml index c952c03ee1..1daefeffe9 100644 --- a/.spectral-oas.yml +++ b/.spectral-oas.yml @@ -1,4 +1,27 @@ +functions: + - camara-language-spelling + - camara-language-avoid-telco +functionsDir: "./lint_function" rules: + camara-language-spelling: + message: "{{error}}" + severity: warn + given: + - "$.info.title" + - "$.info.summary" + - "$.info.description" + - "$.paths.*.*.parameters[?(@.in==='query' || @.in==='path' || @.in==='cookie')].description" + - "$..properties.*.description" + then: + function: camara-language-spelling + camara-language-avoid-telco: + message: "{{error}}" + severity: hint + description: | + This rule checks for telco-specific terminology in your API definitions and suggests more inclusive terms. + given: "$..*.*" + then: + function: camara-language-avoid-telco camara-operationid-casing-convention: message: Operation Id must be in Camel case "{{error}}" severity: hint