Home

Awesome

AsyncAPI Converter

Go Doc Release Go Report Card

Overview

The AsyncAPI Converter converts AsyncAPI documents from versions 1.0.0, 1.1.0 and 1.2.0 to version 2.0.0. It supports both json and yaml formats on input and output. By default, the AsyncAPI Converter converts a document into the json format.

Prerequisites

Installation

To install the AsyncAPI Converter package, run:

go get github.com/asyncapi/converter-go/...

TIP: You can also get binaries from the latest GitHub release.

Usage

You can use the AsyncAPI Converter in the terminal or as a package.

In CLI

Before you use the AsyncAPI Converter in the terminal, build the application. Run:

git clone https://github.com/asyncapi/converter-go.git
cd ./converter-go
go build -o=asyncapi-converter ./cmd/api-converter/main.go

To convert a document use the following command:

asyncapi-converter <document_path> [--toYAML] [--id=<id>]

where:

Examples

See the following minimal examples of the AsyncAPI Converter usage in the terminal:

As a package

To see examples of how to use the AsyncAPI Converter as a package, go to the README.md.

Contribution

If you have a feature request, add it as an issue or propose changes in a pull request (PR). If you create a feature request, use the dedicated Feature request issue template. When you create a PR, follow the contributing rules described in the CONTRIBUTING.md document.

Credits

<p align="center"> <a href="https://kyma-project.io/" target="_blank"> <img src="https://raw.githubusercontent.com/kyma-project/kyma/master/logo.png" width="235"> </a> </p>