@smithers-orchestrator/server 0.18.0 → 0.20.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithers-orchestrator/server",
3
- "version": "0.18.0",
3
+ "version": "0.20.0",
4
4
  "description": "HTTP, WebSocket, gateway, cron, webhook, and metrics servers for Smithers",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -26,24 +26,24 @@
26
26
  "effect": "^3.21.1",
27
27
  "hono": "^4.12.14",
28
28
  "ws": "^8.20.0",
29
- "@smithers-orchestrator/db": "0.18.0",
30
- "@smithers-orchestrator/devtools": "0.18.0",
31
- "@smithers-orchestrator/engine": "0.18.0",
32
- "@smithers-orchestrator/errors": "0.18.0",
33
- "@smithers-orchestrator/components": "0.18.0",
34
- "@smithers-orchestrator/driver": "0.18.0",
35
- "@smithers-orchestrator/observability": "0.18.0",
36
- "@smithers-orchestrator/gateway": "0.18.0",
37
- "@smithers-orchestrator/protocol": "0.18.0",
38
- "@smithers-orchestrator/scheduler": "0.18.0",
39
- "@smithers-orchestrator/time-travel": "0.18.0"
29
+ "@smithers-orchestrator/engine": "0.20.0",
30
+ "@smithers-orchestrator/driver": "0.20.0",
31
+ "@smithers-orchestrator/db": "0.20.0",
32
+ "@smithers-orchestrator/gateway": "0.20.0",
33
+ "@smithers-orchestrator/protocol": "0.20.0",
34
+ "@smithers-orchestrator/observability": "0.20.0",
35
+ "@smithers-orchestrator/errors": "0.20.0",
36
+ "@smithers-orchestrator/scheduler": "0.20.0",
37
+ "@smithers-orchestrator/components": "0.20.0",
38
+ "@smithers-orchestrator/time-travel": "0.20.0",
39
+ "@smithers-orchestrator/devtools": "0.20.0"
40
40
  },
41
41
  "devDependencies": {
42
42
  "@types/bun": "latest",
43
43
  "react": "^19.2.5",
44
44
  "typescript": "~5.9.3",
45
45
  "zod": "^4.3.6",
46
- "@smithers-orchestrator/graph": "0.18.0"
46
+ "@smithers-orchestrator/graph": "0.20.0"
47
47
  },
48
48
  "scripts": {
49
49
  "test": "bun test tests",
package/src/gateway.js CHANGED
@@ -2114,7 +2114,7 @@ export class Gateway {
2114
2114
  return this;
2115
2115
  }
2116
2116
  /**
2117
- * @param {{ port?: number; host?: string }} [options]
2117
+ * @param {{ port?: number; host?: string; path?: string }} [options]
2118
2118
  */
2119
2119
  async listen(options = {}) {
2120
2120
  if (this.server) {
@@ -2185,6 +2185,10 @@ export class Gateway {
2185
2185
  });
2186
2186
  });
2187
2187
  await new Promise((resolve) => {
2188
+ if (options.path !== undefined) {
2189
+ server.listen(options.path, () => resolve());
2190
+ return;
2191
+ }
2188
2192
  if (options.host === undefined) {
2189
2193
  server.listen(options.port ?? 7331, () => resolve());
2190
2194
  return;
package/src/index.d.ts CHANGED
@@ -543,11 +543,12 @@ declare class Gateway {
543
543
  */
544
544
  register(key: string, workflow: SmithersWorkflow, options?: GatewayRegisterOptions): this;
545
545
  /**
546
- * @param {{ port?: number; host?: string }} [options]
546
+ * @param {{ port?: number; host?: string; path?: string }} [options]
547
547
  */
548
548
  listen(options?: {
549
549
  port?: number;
550
550
  host?: string;
551
+ path?: string;
551
552
  }): Promise<node_http.Server<typeof node_http.IncomingMessage, typeof node_http.ServerResponse>>;
552
553
  close(): Promise<void>;
553
554
  startScheduler(): void;