Skip to content

Learn AsyncAPI by example

Event-driven APIs described in AsyncAPI: the structure of a document, the 2.x to 3.0 changes, the lint findings and their fixes. Each page comes with the output of the tools that read the example, and says when it was last checked.

  • AsyncAPI 2 to 3 migration: the same API in 2.6 and 3.0, side by side

    One small event API written in AsyncAPI 2.6 and in 3.0: publish and subscribe become operations with action send or receive, the channel key becomes an id with an address, messages move under the channel, servers split url into host and pathname. With the linter's output for each version and for a 2.6 file that only had its version changed.

  • AsyncAPI channels, operations and messages: the 3.0 structure, step by step

    In AsyncAPI 3.0 a channel is an address with the messages on it, an operation says whether the application sends to or receives from a channel, and messages live under the channel. Each part built up in a working document, with the linter's message when it is missing or wrong, and four mistakes the linter does not catch.

  • AsyncAPI documentation: render it locally, then publish it from Git

    An AsyncAPI file becomes a documentation page with its servers, channels, messages and operations. How to see it on your machine with apigit preview before committing, what the page shows, and how to publish a version from a commit in the browser or with apigit doc publish.

  • AsyncAPI linter: every finding apigit lint reports, with its fix

    apigit lint checks AsyncAPI 2.x and 3.x files offline with Spectral's AsyncAPI rules. The findings it printed on real documents, what each rule asks for, how to fix it, how to change the rule set, and the version string that stops every rule.

  • What is AsyncAPI? A minimal 3.0 document, linted and rendered

    AsyncAPI describes message-driven APIs: the channels an application sends to or receives from, and the messages on them. How it differs from OpenAPI, a 21-line AsyncAPI 3.0 document, what a linter says about it, and how it renders as documentation.

Try it with your own API

Create a free workspace, add your API files, and publish their documentation and a mock server from the same repository.

Free for individuals. No credit card.

$ npm install -g @apigit/cli$ apigit auth login$ apigit doc publish