callback-discriminator-property-pointer-references-string-type
Overview
This rule belongs to the openapi-v3-apimatic-linting ruleset and states that:
The property referenced by the event discriminator pointer must be of type string. Non-string types cannot be used as discriminator values for identifying different event types.
| Property | Value |
|---|---|
| Enabled | Yes |
| Maximum Severity | Error |
| Message | The event discriminator property pointer must reference a string-typed property. |
| Code | OPENAPI3APIMATIC_L511 |
| Type | Linting |
| Rule System | Semantic |
| Broad Category | OpenAPI Callbacks |
| Products Impacted | Code Generation, Developer Experience Portal |
| Tags | openapi3 openapi apimatic semantic linting callback discriminator property pointer string type |
Suggested Fixes
- Ensure the property referenced by the discriminator pointer is of type
string. - Change the property type to
stringif it is currently a different type.
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/