3

Can we pass input yml specification HTTP URL in openapi-generator-maven-plugin?

I wanted to keep the input specification and generated code in sync.

1 Answer 1

5

Yes, with openapi-generator-maven-plugin that is possible by simply giving URL including protocol as inputSpec:

<plugin>
    <groupId>org.openapitools</groupId>
    <artifactId>openapi-generator-maven-plugin</artifactId>
    <version>5.4.0</version>
    <executions>
        <execution>
            ...
            <configuration>
                <inputSpec>https://petstore3.swagger.io/api/v3/openapi.yaml</inputSpec>
                ...
            </configuration>
        </execution>
    </executions>
</plugin>

Updating plugin version might be necessary.

Sign up to request clarification or add additional context in comments.

1 Comment

how to pass the bitbucket url which needs auth token?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.