Define & Validate APIsValidation RulesetsOpenAPI Rulesets

Swagger v2.0 APIMatic Linting

Linting checks performed by APIMatic on provided Swagger v2.0 file to check its conformance to recommended practices for better API consumption.

PropertyValue
Ruleset IDswagger-v2-apimatic-linting
Code prefixSWAGGER20APIMATIC_L
TypeLinting
Default severityWarning
Rule systemSemantic
Rules3

Security

CodeRuleSeverityWhat it checks
SWAGGER20APIMATIC_L001security-options-meta-count-matches-security-items-countWarningYou can extend the security information you apply globally or at operation level by using the x-security-options-meta extension. It can help you provide more details for each of the security options available. However, the number of items inside the x-security-options-meta extension must match the number of items inside the security list.

Operations

CodeRuleSeverityWhat it checks
SWAGGER20APIMATIC_L100get-operation-cannot-have-body-or-form-parametersWarningA GET operation must not define a parameter with location in set as body or formData in the parameters list. This is because such methods do not expect a request body and, therefore, all related information will be ignored automatically during import/transformations in APIMatic.
SWAGGER20APIMATIC_L101supported-response-codeWarningIf 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.

Learn more

On this page