supported-response-code
Overview
This rule belongs to the openapi-v3-apimatic-linting ruleset and states that:
If multiple responses are disabled via import settings provided in the APIMatic Metadata file, only response definitions in responses belonging to status code ranges 200-208 and 400-599 will be imported. Those outside the supported range will be ignored automatically during import/transformations in APIMatic.
| Property | Value |
|---|---|
| Enabled | Yes |
| Maximum Severity | Warning |
| Message | Provided response status code is not supported in the current import configuration. |
| Code | OPENAPI3APIMATIC_L970 |
| Type | Linting |
| Rule System | Semantic |
| Broad Category | Miscellaneous |
| Products Impacted | API Transformer, Code Generation, Developer Experience Portal |
| Tags | openapi3 openapi apimatic semantic linting http status code status code http response responses |
Suggested Fixes
- Enable import setting
ImportMultipleResponsesusing the APIMatic Metadata file. - Remove the response definition that uses the unsupported status code, from the
responsesobject.
For More Information
- https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#responses-object
- https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#responses-object
- https://docs.apimatic.io/manage-apis/create-or-import-api/#import-settings-object
- https://docs.apimatic.io/changelog/support-for-multiple-responses-added-in-api-transformer-across-all-formats
- https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md
- https://docs.apimatic.io/rulesets/overview/