callback-extension-group-must-exist-when-referenced
Overview
This rule belongs to the openapi-v3-apimatic-linting ruleset and states that:
When a callback operation references a callback group name, that group must be defined in the x-callback-groups extension at the root level. Referencing a non-existent group will result in an invalid configuration.
| Property | Value |
|---|---|
| Enabled | Yes |
| Maximum Severity | Error |
| Message | The referenced callback group does not exist in the callback groups extension. |
| Code | OPENAPI3APIMATIC_L521 |
| Type | Linting |
| Rule System | Semantic |
| Broad Category | OpenAPI Callbacks |
| Products Impacted | Code Generation, Developer Experience Portal |
| Tags | openapi3 openapi apimatic semantic linting callback group extension reference |
Suggested Fixes
- Define the referenced callback group in the
x-callback-groupsextension at the root level. - Verify that the callback group name is correctly spelled and matches the definition.
For More Information
- https://docs.apimatic.io/specification-extensions/swagger-codegen-extensions/#callback-group-extension
- https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md#callback-object
- https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.0.3.md
- https://docs.apimatic.io/rulesets/overview/