Skip to content

aleios-cloud/eventbridge-toolbox-schema-generator

Repository files navigation

eventbridge-toolbox-schema-generator

Eventbridge Toolbox Schema Generator is cli tool that automates the initial creation of a schema registry in your documentation of your event-driven architecture.

This is designed to work with the eventbridge-toolbox package.

Eventbridge Contracts

Within event-driven architectures, events facilitate communication between loosely connected services in an application. EventBridge is AWS's tool for implementing asynchronous event-driven workflows.

Event emitters are responsible for broadcasting events to event channels, while event consumers are responsible for executing business logic whenever they encounter a relevant event.

EventBridge contracts ensure a stable and reliable interaction emitters and consumers. These contract acts as a guiding agreement which guarantees that emitters' published events will consistently trigger the corresponding business logic on the consumer side.

Key Features

  • Generate documentation skeletons for events
  • Generate json schemas for events from contracts

Getting Started

Prerequisites

Installation

With npm:

npm install --save-dev @aleios-cloud/eventbridge-toolbox-schema-generator

With yarn:

yarn add -D @aleios-cloud/eventbridge-toolbox-schema-generator

With pnpm:

pnpm add -D @aleios-cloud/eventbridge-toolbox-schema-generator

Usage

You can create a documentation website based on eventcatalog.dev and generate docs directly from your event contracts.

  1. Set up an event catalog site and give it a name:
npx @eventcatalog/create-eventcatalog@latest <name your event catalog>
  1. Edit eventcatalog.config.js with your details

  2. Remove the example events from the events folder, as well as everything in the services and domains folders

  3. Run eventbridge-toolbox-schema-generator with the following arguments:

  • The path from the root to your event contracts
  • The path from the root to the event catalog events folder
npx schema-generator <path from root to your event contracts> <path from root to event catalog events>
  1. You can start a local development server by running:
npm run dev
  1. You can find out more about how to deploy your documentation site in the event catalog docs

Contributors

Ryan Schuller
Ryan Schuller
Luke Yianni
Luke Yianni
April Bates
April Bates

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published