Skip to content
This repository was archived by the owner on Jan 5, 2026. It is now read-only.

Commit f8edfab

Browse files
committed
add initial setup
1 parent 09c1188 commit f8edfab

158 files changed

Lines changed: 17857 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/deploy.yml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
name: Deploy EventCatalog to GitHub Pages
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
# Allows you to run this workflow manually from the Actions tab
8+
workflow_dispatch:
9+
10+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
11+
permissions:
12+
contents: read
13+
pages: write
14+
id-token: write
15+
16+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
17+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
18+
concurrency:
19+
group: "pages"
20+
cancel-in-progress: false
21+
22+
jobs:
23+
# Build job
24+
build:
25+
runs-on: ubuntu-latest
26+
defaults:
27+
run:
28+
working-directory: ./eventcatalog
29+
steps:
30+
- name: Checkout
31+
uses: actions/checkout@v4
32+
33+
- name: Setup Node.js
34+
uses: actions/setup-node@v4
35+
with:
36+
node-version: '20'
37+
cache: 'yarn'
38+
cache-dependency-path: './eventcatalog/yarn.lock'
39+
40+
- name: Install dependencies
41+
run: yarn install --frozen-lockfile
42+
43+
- name: Create .env file
44+
run: |
45+
cat << EOF > .env
46+
EVENTCATALOG_SCALE_LICENSE_KEY=${{ secrets.EVENTCATALOG_SCALE_LICENSE_KEY }}
47+
EVENTCATALOG_LICENSE_KEY_ASYNCAPI=${{ secrets.EVENTCATALOG_LICENSE_KEY_ASYNCAPI }}
48+
EOF
49+
shell: bash
50+
51+
- name: Generate EventCatalog files
52+
run: yarn generate
53+
54+
- name: Build EventCatalog
55+
run: yarn build
56+
env:
57+
NODE_ENV: production
58+
59+
- name: Export static files
60+
run: yarn export || echo "No export command, using build output"
61+
62+
- name: Setup Pages
63+
uses: actions/configure-pages@v4
64+
65+
- name: Upload artifact
66+
uses: actions/upload-pages-artifact@v3
67+
with:
68+
path: './eventcatalog/dist'
69+
70+
# Deployment job
71+
deploy:
72+
environment:
73+
name: github-pages
74+
url: ${{ steps.deployment.outputs.page_url }}
75+
runs-on: ubuntu-latest
76+
needs: build
77+
steps:
78+
- name: Deploy to GitHub Pages
79+
id: deployment
80+
uses: actions/deploy-pages@v4
81+

eventcatalog/.env.template

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Add license key from eventcatalog
2+
EVENTCATALOG_SCALE_LICENSE_KEY=123
3+
EVENTCATALOG_LICENSE_KEY_ASYNCAPI=123

eventcatalog/.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
.env
2+
node_modules
3+
.eventcatalog-core
4+
dist

eventcatalog/README.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# EventCatalog AsyncAPI Example
2+
3+
This is an example project for EventCatalog with the AsyncAPI generator plugin.
4+
5+
This example contains
6+
7+
- Generating EventCatalog from AsyncAPI files
8+
- Mapping multiple AsyncAPI files into a domain
9+
- EventCatalog generated by AsyncAPI files
10+
11+
### Getting Started
12+
13+
1. Clone this project
14+
1. Run `npm install`
15+
1. Get and configure a AsyncAPI license key from [AsyncAPI](https://eventcatalog.cloud) (14 day free trial)
16+
1. Run the generators `npm run generate`
17+
1. Run the catalog `npm run dev`
18+
1. View your catalog at https://localhost:3000
19+
20+
### Features for OpenAPI Plugin
21+
22+
- Auto versioning of domains, services and messages
23+
- Document events, queries and commands using custom extensions to AsyncAPI
24+
- Assign each route/message a version independent of your AsyncAPI version
25+
- Visually see AsyncAPI files in your catalog.
26+
- And much more...
27+
28+
To dive into how this plugin can help you, you can read the [AsyncAPI Plugin Docs](https://www.eventcatalog.dev/integrations/asyncapi)
29+
Lines changed: 141 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,141 @@
1+
asyncapi: 3.0.0
2+
info:
3+
title: Fraud Detection Service
4+
version: 1.0.1
5+
description: This service monitors transactions to detect potentially fraudulent activities.
6+
7+
operations:
8+
sendFraudAlert:
9+
action: send
10+
channel:
11+
$ref: '#/channels/fraudAlert'
12+
messages:
13+
- $ref: '#/channels/fraudAlert/messages/FraudAlert'
14+
15+
receiveTransactionEvaluated:
16+
action: receive
17+
channel:
18+
$ref: '#/channels/transactionEvaluated'
19+
messages:
20+
- $ref: '#/channels/transactionEvaluated/messages/TransactionEvaluated'
21+
22+
receiveTransactionReview:
23+
action: receive
24+
channel:
25+
$ref: '#/channels/transactionReview'
26+
messages:
27+
- $ref: '#/channels/transactionReview/messages/TransactionReview'
28+
29+
channels:
30+
fraudAlert:
31+
address: fraud/alert
32+
messages:
33+
FraudAlert:
34+
$ref: '#/components/messages/FraudAlert'
35+
36+
transactionEvaluated:
37+
address: transaction/evaluated
38+
messages:
39+
TransactionEvaluated:
40+
$ref: '#/components/messages/TransactionEvaluated'
41+
42+
transactionReview:
43+
address: transaction/review
44+
messages:
45+
TransactionReview:
46+
$ref: '#/components/messages/TransactionReview'
47+
48+
components:
49+
messages:
50+
FraudAlert:
51+
description: 'Fraud alert triggered by a suspicious transaction'
52+
x-eventcatalog-message-type: event
53+
tags:
54+
- name: 'Fraud'
55+
description: 'Fraud detection event'
56+
headers:
57+
type: object
58+
properties:
59+
ec-message-type:
60+
type: string
61+
default: event
62+
description: Type of message for EventCatalog
63+
payload:
64+
type: object
65+
properties:
66+
alertId:
67+
type: string
68+
description: Unique identifier for the fraud alert
69+
transactionId:
70+
type: string
71+
description: Unique identifier for the transaction
72+
alertTime:
73+
type: string
74+
format: date-time
75+
description: Time when the fraud alert was triggered
76+
severity:
77+
type: string
78+
description: Severity level of the fraud alert
79+
details:
80+
type: string
81+
description: Additional details about the fraud alert
82+
83+
TransactionEvaluated:
84+
description: 'Evaluation results of a transaction for fraud risk'
85+
x-eventcatalog-message-type: event
86+
tags:
87+
- name: 'Evaluation'
88+
description: 'Transaction evaluation event'
89+
headers:
90+
type: object
91+
properties:
92+
ec-message-type:
93+
type: string
94+
default: event
95+
description: Type of message for EventCatalog
96+
payload:
97+
type: object
98+
properties:
99+
transactionId:
100+
type: string
101+
description: Unique identifier for the transaction
102+
evaluationTime:
103+
type: string
104+
format: date-time
105+
description: Time when the transaction was evaluated
106+
isFraudulent:
107+
type: boolean
108+
description: Indicates whether the transaction was flagged as fraudulent
109+
riskScore:
110+
type: number
111+
description: Risk score assigned to the transaction
112+
113+
TransactionReview:
114+
description: 'Manual review of a flagged transaction'
115+
x-eventcatalog-message-type: command
116+
tags:
117+
- name: 'Review'
118+
description: 'Transaction review command'
119+
headers:
120+
type: object
121+
properties:
122+
ec-message-type:
123+
type: string
124+
default: command
125+
description: Type of message for EventCatalog
126+
payload:
127+
type: object
128+
properties:
129+
transactionId:
130+
type: string
131+
description: Unique identifier for the transaction
132+
reviewTime:
133+
type: string
134+
format: date-time
135+
description: Time when the transaction was reviewed
136+
reviewOutcome:
137+
type: string
138+
description: Outcome of the manual review (e.g., Approved, Declined, Escalated)
139+
reviewerId:
140+
type: string
141+
description: Identifier for the reviewer who conducted the review

0 commit comments

Comments
 (0)