@eventlane/board-api 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +15 -11
  2. package/package.json +16 -3
package/README.md CHANGED
@@ -1,8 +1,6 @@
1
1
  # @eventlane/board-api
2
2
 
3
- The framework-neutral JSON API of the EventLane dashboard: `createBoardApi(options).handle(request)` answers `{ status, body }` for topics, events, consumers and dead letters, and for the write actions. It has no HTTP framework dependency; the adapters translate requests.
4
-
5
- > Part of [EventLane](https://github.com/eventlane-dev/eventlane).
3
+ The framework-neutral JSON API behind the [EventLane](https://www.npmjs.com/package/@eventlane/core) dashboard. Use it to build a dashboard adapter for a framework that has none; for Express, Fastify or NestJS use the ready-made adapters instead.
6
4
 
7
5
  ## Install
8
6
 
@@ -10,17 +8,23 @@ The framework-neutral JSON API of the EventLane dashboard: `createBoardApi(optio
10
8
  npm install @eventlane/board-api @eventlane/core
11
9
  ```
12
10
 
13
- ## Build and test
11
+ ## Use it
14
12
 
15
- ```bash
16
- pnpm --filter @eventlane/board-api build
17
- pnpm --filter @eventlane/board-api dev # rebuild on every change (watch mode)
18
- pnpm --filter @eventlane/board-api test # needs Redis; it runs against the sources of `@eventlane/core`
19
- pnpm --filter @eventlane/board-api typecheck
13
+ ```ts
14
+ import { createBoardApi } from '@eventlane/board-api';
15
+
16
+ const api = createBoardApi({ buses: bus, readOnly: true });
17
+
18
+ // translate your framework's request, then write the answer; handle never throws
19
+ const { status, body } = await api.handle({ method: 'GET', path: '/topics', query: {}, raw: request });
20
20
  ```
21
21
 
22
- To build an adapter for another framework, see "Other frameworks" in the dashboard docs.
22
+ It covers topics, events, consumers and dead letters, with rate limiting, payload redaction and protection of write actions built in.
23
23
 
24
24
  ## Documentation
25
25
 
26
- - [Dashboard: getting started](https://eventlane-dev.github.io/eventlane/dashboard/getting-started) (options), [HTTP API](https://eventlane-dev.github.io/eventlane/dashboard/api)
26
+ - [HTTP API](https://eventlane-dev.github.io/eventlane/dashboard/api), [Other frameworks](https://eventlane-dev.github.io/eventlane/dashboard/getting-started#other-frameworks)
27
+
28
+ ## License
29
+
30
+ MIT. Source and issues: [github.com/eventlane-dev/eventlane](https://github.com/eventlane-dev/eventlane).
package/package.json CHANGED
@@ -1,7 +1,20 @@
1
1
  {
2
2
  "name": "@eventlane/board-api",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "EventLane board: framework-agnostic JSON API for inspecting topics, events, consumers and dead letters",
5
+ "keywords": [
6
+ "admin",
7
+ "dashboard",
8
+ "dead-letter-queue",
9
+ "event-bus",
10
+ "eventlane",
11
+ "events",
12
+ "monitoring",
13
+ "nodejs",
14
+ "redis",
15
+ "redis-streams",
16
+ "typescript"
17
+ ],
5
18
  "license": "MIT",
6
19
  "repository": {
7
20
  "type": "git",
@@ -36,11 +49,11 @@
36
49
  "node": ">=20"
37
50
  },
38
51
  "peerDependencies": {
39
- "@eventlane/core": "0.1.0"
52
+ "@eventlane/core": "0.1.1"
40
53
  },
41
54
  "devDependencies": {
42
55
  "ioredis": "^6.0.0",
43
- "@eventlane/core": "0.1.0"
56
+ "@eventlane/core": "0.1.1"
44
57
  },
45
58
  "publishConfig": {
46
59
  "access": "public"