@journal.one/gateway-protocol 0.1.0 → 0.2.0

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 +41 -0
  2. package/package.json +2 -1
package/README.md ADDED
@@ -0,0 +1,41 @@
1
+ # @journal.one/gateway-protocol
2
+
3
+ Shared TypeScript types and [Zod](https://zod.dev) schemas for the Journal Gateway protocol (v2). Used by both the gateway and client libraries — you typically don't install this directly.
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ npm install @journal.one/gateway-protocol
9
+ ```
10
+
11
+ ## What's inside
12
+
13
+ - **Message schemas** — every WebSocket message type (`authenticate`, `tool_call`, `version_changed`, pull requests/responses, etc.)
14
+ - **Integration types** — `Integration`, `ToolDefinition`, `ToolResult`, and content blocks
15
+ - **Skill types** — `Skill` schema
16
+ - **Error types** — `GatewayError` with typed error codes
17
+ - **Provider interface** — `IntegrationProvider`, `GatewayConfig`, `GatewayVersions`
18
+
19
+ All exports are pure types and Zod schemas with no runtime dependencies beyond Zod.
20
+
21
+ ## Usage
22
+
23
+ ```ts
24
+ import {
25
+ GatewayMessageSchema,
26
+ ServiceMessageSchema,
27
+ type Integration,
28
+ type ToolResult,
29
+ } from "@journal.one/gateway-protocol";
30
+
31
+ // Validate an incoming message
32
+ const msg = GatewayMessageSchema.parse(JSON.parse(raw));
33
+ ```
34
+
35
+ ## Full documentation
36
+
37
+ See the [root README](https://github.com/journal-ai/journal-edge#readme) for protocol details, architecture, and configuration reference.
38
+
39
+ ## License
40
+
41
+ MIT
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@journal.one/gateway-protocol",
3
- "version": "0.1.0",
3
+ "version": "0.2.0",
4
+ "license": "MIT",
4
5
  "type": "module",
5
6
  "main": "./dist/index.js",
6
7
  "types": "./dist/index.d.ts",