unique-server-parameters
Overview
This rule belongs to the openapi-v3-apimatic-linting ruleset and states that:
The server parameters defined in the server configuration of the API must have unique names.
| Property | Value |
|---|---|
| Enabled | Yes |
| Maximum Severity | Error |
| Message | Duplicate definitions of server parameter found in the server configuration. |
| Code | OPENAPI3APIMATIC_L114 |
| Type | Linting |
| Rule System | Semantic |
| Broad Category | OpenAPI Servers |
| Products Impacted | API Transformer, Code Generation |
| Tags | openapi3 openapi apimatic semantic linting server parameter |
Suggested Fixes
- Remove duplicate server variables.
- Rename server variables to enure the uniqueness of variable names.
- Make sure all server variables are assigned unique names.
For More Information
- https://docs.apimatic.io/specification-extensions/swagger-server-configuration-extensions/#server-configuration-object
- https://docs.apimatic.io/specification-extensions/swagger-server-configuration-extensions/#parameter-object
- https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md
- https://docs.apimatic.io/rulesets/overview/