Skip to content

setup-openapi

Actions
Set up GitHub Actions workflow with OpenAPI Generator
v1.0.0
Latest
Star (2)

setup-openapi

version test License: MIT

🟢 Set up GitHub Actions workflow with OpenAPI Generator.

Quick Start

# .github/workflows/openapi.yml
on: push
jobs:
  openapi:
    runs-on: ubuntu-latest
    steps:
      - name: Setup OpenAPI
        uses: remarkablemark/setup-openapi@v1

      - name: Generate Ruby Client
        run: openapi-generator-cli generate -i petstore.yaml -g ruby -o /tmp/test/

Usage

Install OpenAPI Generator CLI tool:

- uses: remarkablemark/setup-openapi@v1

Generate a Ruby client from a valid petstore.yaml doc:

- run: openapi-generator-cli generate -i petstore.yaml -g ruby -o /tmp/test/

See action.yml

Note

On Windows, you'll need to install a higher Java version:

on: push
jobs:
  openapi:
    runs-on: windows-latest
    steps:
      - uses: actions/setup-java@v4
        with:
          distribution: temurin
          java-version: 21
      - uses: remarkablemark/setup-openapi@v1

Inputs

version

Optional: The OpenAPI Generator version. Defaults to latest.

- uses: remarkablemark/setup-openapi@v1
  with:
    version: 7.9.0

License

MIT

setup-openapi is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.

About

Set up GitHub Actions workflow with OpenAPI Generator
v1.0.0
Latest

setup-openapi is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.