Skip to content

business-messaging-api_v23.0.yaml is not valid #4

Description

@WernerRaath

The OpenAPI spec seems to not be fully valid. When we try and validate the Swagger Doc using the following command, we see it returning business-messaging-api_v23.0.yaml: attribute components.parameterGroups is unexpected

docker run --rm node:26-alpine sh -c "apk add wget && npm i -g swagger-spec-validator && wget https://raw.githubusercontent.com/facebook/openapi/main/business-messaging-api_v23.0.yaml && swagger-spec-validator business-messaging-api_v23.0.yaml"

When we try and to a TS codegen from it, it also fails

docker run --rm node:26-alpine sh -c "apk add --no-cache openjdk17-jdk && npm install -g openapi-typescript @openapitools/openapi-generator-cli && npx @openapitools/openapi-generator-cli generate -i https://raw.githubusercontent.com/facebook/openapi/main/business-messaging-api_v23.0.yaml -g typescript-axios -o /tmp/"

returns

Exception in thread "main" org.openapitools.codegen.SpecValidationException: There were issues with the specification. The option can be disabled via validateSpec (Maven/Gradle) or --skip-validate-spec (CLI).
 | Error count: 1, Warning count: 105
Errors: 
        -attribute components.parameterGroups is unexpected
Warnings: 
        -attribute components.parameterGroups is unexpected

        at org.openapitools.codegen.config.CodegenConfigurator.toContext(CodegenConfigurator.java:718)
        at org.openapitools.codegen.config.CodegenConfigurator.toClientOptInput(CodegenConfigurator.java:745)
        at org.openapitools.codegen.cmd.Generate.execute(Generate.java:527)
        at org.openapitools.codegen.cmd.OpenApiGeneratorCommand.run(OpenApiGeneratorCommand.java:32)
        at org.openapitools.codegen.OpenAPIGenerator.main(OpenAPIGenerator.java:66)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions