@stepflowjs/trigger-http 0.0.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.
@@ -0,0 +1,107 @@
1
+ import { Trigger, TriggerHandler } from '@stepflowjs/core';
2
+
3
+ interface HttpTriggerConfig {
4
+ /** The route path for this trigger */
5
+ path: string;
6
+ /** HTTP method to accept */
7
+ method: "GET" | "POST" | "PUT" | "DELETE" | "PATCH";
8
+ /** Optional signature validation */
9
+ validateSignature?: {
10
+ /** Header name containing the signature (e.g., 'x-signature') */
11
+ header: string;
12
+ /** Secret key for signature verification */
13
+ secret: string;
14
+ /** Hash algorithm to use */
15
+ algorithm: "sha256" | "sha1";
16
+ };
17
+ }
18
+ interface HttpTriggerResponse {
19
+ success: boolean;
20
+ eventId: string;
21
+ }
22
+ /**
23
+ * HTTP trigger for Stepflow workflows
24
+ *
25
+ * Allows workflows to be triggered via HTTP requests with optional signature validation.
26
+ * Works with any framework adapter (Hono, Express, Fastify, etc.) via the `handleRequest` method.
27
+ *
28
+ * @example
29
+ * ```typescript
30
+ * const trigger = new HttpTrigger({
31
+ * path: '/webhooks/github',
32
+ * method: 'POST',
33
+ * validateSignature: {
34
+ * header: 'x-hub-signature-256',
35
+ * secret: process.env.GITHUB_WEBHOOK_SECRET,
36
+ * algorithm: 'sha256',
37
+ * },
38
+ * });
39
+ *
40
+ * await trigger.start(async (event) => {
41
+ * await stepflow.trigger('github-webhook', event.data);
42
+ * });
43
+ *
44
+ * // In your framework adapter:
45
+ * app.post('/webhooks/github', async (req) => {
46
+ * const response = await trigger.handleRequest(req);
47
+ * return response;
48
+ * });
49
+ * ```
50
+ */
51
+ declare class HttpTrigger implements Trigger<HttpTriggerConfig> {
52
+ readonly config: HttpTriggerConfig;
53
+ readonly type = "http";
54
+ private handler?;
55
+ constructor(config: HttpTriggerConfig);
56
+ /**
57
+ * Start the trigger with a handler function
58
+ * @param handler Function to call when HTTP requests are received
59
+ */
60
+ start(handler: TriggerHandler): Promise<void>;
61
+ /**
62
+ * Stop the trigger
63
+ */
64
+ stop(): Promise<void>;
65
+ /**
66
+ * Health check - returns true if handler is registered
67
+ */
68
+ healthCheck(): Promise<boolean>;
69
+ /**
70
+ * Handle an incoming HTTP request
71
+ *
72
+ * This method should be called by framework adapters to process HTTP requests.
73
+ * It validates the signature (if configured), creates a trigger event, and
74
+ * invokes the registered handler.
75
+ *
76
+ * @param request Web standard Request object
77
+ * @returns Web standard Response object
78
+ *
79
+ * @example
80
+ * ```typescript
81
+ * // Hono adapter
82
+ * app.post('/webhook', async (c) => {
83
+ * const response = await trigger.handleRequest(c.req.raw);
84
+ * return response;
85
+ * });
86
+ *
87
+ * // Express adapter
88
+ * app.post('/webhook', async (req, res) => {
89
+ * const request = new Request(`http://localhost${req.url}`, {
90
+ * method: req.method,
91
+ * headers: req.headers,
92
+ * body: JSON.stringify(req.body),
93
+ * });
94
+ * const response = await trigger.handleRequest(request);
95
+ * res.status(response.status).json(await response.json());
96
+ * });
97
+ * ```
98
+ */
99
+ handleRequest(request: Request): Promise<Response>;
100
+ /**
101
+ * Validate request signature using Web Crypto API
102
+ * @private
103
+ */
104
+ private validateSignature;
105
+ }
106
+
107
+ export { HttpTrigger, type HttpTriggerConfig, type HttpTriggerResponse };
package/dist/index.js ADDED
@@ -0,0 +1,178 @@
1
+ // src/index.ts
2
+ var HttpTrigger = class {
3
+ constructor(config) {
4
+ this.config = config;
5
+ }
6
+ type = "http";
7
+ handler;
8
+ /**
9
+ * Start the trigger with a handler function
10
+ * @param handler Function to call when HTTP requests are received
11
+ */
12
+ async start(handler) {
13
+ this.handler = handler;
14
+ }
15
+ /**
16
+ * Stop the trigger
17
+ */
18
+ async stop() {
19
+ this.handler = void 0;
20
+ }
21
+ /**
22
+ * Health check - returns true if handler is registered
23
+ */
24
+ async healthCheck() {
25
+ return this.handler !== void 0;
26
+ }
27
+ /**
28
+ * Handle an incoming HTTP request
29
+ *
30
+ * This method should be called by framework adapters to process HTTP requests.
31
+ * It validates the signature (if configured), creates a trigger event, and
32
+ * invokes the registered handler.
33
+ *
34
+ * @param request Web standard Request object
35
+ * @returns Web standard Response object
36
+ *
37
+ * @example
38
+ * ```typescript
39
+ * // Hono adapter
40
+ * app.post('/webhook', async (c) => {
41
+ * const response = await trigger.handleRequest(c.req.raw);
42
+ * return response;
43
+ * });
44
+ *
45
+ * // Express adapter
46
+ * app.post('/webhook', async (req, res) => {
47
+ * const request = new Request(`http://localhost${req.url}`, {
48
+ * method: req.method,
49
+ * headers: req.headers,
50
+ * body: JSON.stringify(req.body),
51
+ * });
52
+ * const response = await trigger.handleRequest(request);
53
+ * res.status(response.status).json(await response.json());
54
+ * });
55
+ * ```
56
+ */
57
+ async handleRequest(request) {
58
+ if (!this.handler) {
59
+ return new Response(JSON.stringify({ error: "Trigger not started" }), {
60
+ status: 503,
61
+ headers: { "Content-Type": "application/json" }
62
+ });
63
+ }
64
+ if (request.method !== this.config.method) {
65
+ return new Response(
66
+ JSON.stringify({
67
+ error: `Method not allowed. Expected ${this.config.method}`
68
+ }),
69
+ {
70
+ status: 405,
71
+ headers: { "Content-Type": "application/json" }
72
+ }
73
+ );
74
+ }
75
+ try {
76
+ const contentType = request.headers.get("content-type") || "";
77
+ let data;
78
+ if (contentType.includes("application/json")) {
79
+ data = await request.json();
80
+ } else if (contentType.includes("application/x-www-form-urlencoded")) {
81
+ const formData = await request.formData();
82
+ data = Object.fromEntries(formData.entries());
83
+ } else if (contentType.includes("text/")) {
84
+ data = await request.text();
85
+ } else {
86
+ data = await request.text();
87
+ }
88
+ if (this.config.validateSignature) {
89
+ const isValid = await this.validateSignature(request, data);
90
+ if (!isValid) {
91
+ return new Response(JSON.stringify({ error: "Invalid signature" }), {
92
+ status: 401,
93
+ headers: { "Content-Type": "application/json" }
94
+ });
95
+ }
96
+ }
97
+ const eventId = crypto.randomUUID();
98
+ const event = {
99
+ id: eventId,
100
+ type: this.type,
101
+ source: `${this.config.method} ${this.config.path}`,
102
+ data,
103
+ metadata: {
104
+ method: request.method,
105
+ path: this.config.path,
106
+ headers: Object.fromEntries(request.headers.entries())
107
+ },
108
+ timestamp: /* @__PURE__ */ new Date()
109
+ };
110
+ await this.handler(event);
111
+ const response = {
112
+ success: true,
113
+ eventId
114
+ };
115
+ return new Response(JSON.stringify(response), {
116
+ status: 200,
117
+ headers: { "Content-Type": "application/json" }
118
+ });
119
+ } catch (error) {
120
+ return new Response(
121
+ JSON.stringify({
122
+ error: "Internal server error",
123
+ message: error.message
124
+ }),
125
+ {
126
+ status: 500,
127
+ headers: { "Content-Type": "application/json" }
128
+ }
129
+ );
130
+ }
131
+ }
132
+ /**
133
+ * Validate request signature using Web Crypto API
134
+ * @private
135
+ */
136
+ async validateSignature(request, data) {
137
+ if (!this.config.validateSignature) {
138
+ return true;
139
+ }
140
+ const { header, secret, algorithm } = this.config.validateSignature;
141
+ const signature = request.headers.get(header);
142
+ if (!signature) {
143
+ return false;
144
+ }
145
+ try {
146
+ const payload = typeof data === "string" ? data : JSON.stringify(data);
147
+ const encoder = new TextEncoder();
148
+ const keyData = encoder.encode(secret);
149
+ const messageData = encoder.encode(payload);
150
+ const cryptoKey = await crypto.subtle.importKey(
151
+ "raw",
152
+ keyData,
153
+ {
154
+ name: "HMAC",
155
+ hash: algorithm === "sha256" ? "SHA-256" : "SHA-1"
156
+ },
157
+ false,
158
+ ["sign"]
159
+ );
160
+ const signatureBuffer = await crypto.subtle.sign(
161
+ "HMAC",
162
+ cryptoKey,
163
+ messageData
164
+ );
165
+ const hashArray = Array.from(new Uint8Array(signatureBuffer));
166
+ const hashHex = hashArray.map((b) => b.toString(16).padStart(2, "0")).join("");
167
+ const expectedSignature = signature.includes("=") ? signature.split("=")[1] : signature;
168
+ return hashHex === expectedSignature;
169
+ } catch (error) {
170
+ console.error("Signature validation error:", error);
171
+ return false;
172
+ }
173
+ }
174
+ };
175
+ export {
176
+ HttpTrigger
177
+ };
178
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["import type { Trigger, TriggerHandler, TriggerEvent } from \"@stepflowjs/core\";\n\n// ============================================================================\n// Types\n// ============================================================================\n\nexport interface HttpTriggerConfig {\n /** The route path for this trigger */\n path: string;\n /** HTTP method to accept */\n method: \"GET\" | \"POST\" | \"PUT\" | \"DELETE\" | \"PATCH\";\n /** Optional signature validation */\n validateSignature?: {\n /** Header name containing the signature (e.g., 'x-signature') */\n header: string;\n /** Secret key for signature verification */\n secret: string;\n /** Hash algorithm to use */\n algorithm: \"sha256\" | \"sha1\";\n };\n}\n\nexport interface HttpTriggerResponse {\n success: boolean;\n eventId: string;\n}\n\n// ============================================================================\n// HttpTrigger Implementation\n// ============================================================================\n\n/**\n * HTTP trigger for Stepflow workflows\n *\n * Allows workflows to be triggered via HTTP requests with optional signature validation.\n * Works with any framework adapter (Hono, Express, Fastify, etc.) via the `handleRequest` method.\n *\n * @example\n * ```typescript\n * const trigger = new HttpTrigger({\n * path: '/webhooks/github',\n * method: 'POST',\n * validateSignature: {\n * header: 'x-hub-signature-256',\n * secret: process.env.GITHUB_WEBHOOK_SECRET,\n * algorithm: 'sha256',\n * },\n * });\n *\n * await trigger.start(async (event) => {\n * await stepflow.trigger('github-webhook', event.data);\n * });\n *\n * // In your framework adapter:\n * app.post('/webhooks/github', async (req) => {\n * const response = await trigger.handleRequest(req);\n * return response;\n * });\n * ```\n */\nexport class HttpTrigger implements Trigger<HttpTriggerConfig> {\n readonly type = \"http\";\n private handler?: TriggerHandler;\n\n constructor(readonly config: HttpTriggerConfig) {}\n\n /**\n * Start the trigger with a handler function\n * @param handler Function to call when HTTP requests are received\n */\n async start(handler: TriggerHandler): Promise<void> {\n this.handler = handler;\n }\n\n /**\n * Stop the trigger\n */\n async stop(): Promise<void> {\n this.handler = undefined;\n }\n\n /**\n * Health check - returns true if handler is registered\n */\n async healthCheck(): Promise<boolean> {\n return this.handler !== undefined;\n }\n\n /**\n * Handle an incoming HTTP request\n *\n * This method should be called by framework adapters to process HTTP requests.\n * It validates the signature (if configured), creates a trigger event, and\n * invokes the registered handler.\n *\n * @param request Web standard Request object\n * @returns Web standard Response object\n *\n * @example\n * ```typescript\n * // Hono adapter\n * app.post('/webhook', async (c) => {\n * const response = await trigger.handleRequest(c.req.raw);\n * return response;\n * });\n *\n * // Express adapter\n * app.post('/webhook', async (req, res) => {\n * const request = new Request(`http://localhost${req.url}`, {\n * method: req.method,\n * headers: req.headers,\n * body: JSON.stringify(req.body),\n * });\n * const response = await trigger.handleRequest(request);\n * res.status(response.status).json(await response.json());\n * });\n * ```\n */\n async handleRequest(request: Request): Promise<Response> {\n if (!this.handler) {\n return new Response(JSON.stringify({ error: \"Trigger not started\" }), {\n status: 503,\n headers: { \"Content-Type\": \"application/json\" },\n });\n }\n\n // Validate HTTP method\n if (request.method !== this.config.method) {\n return new Response(\n JSON.stringify({\n error: `Method not allowed. Expected ${this.config.method}`,\n }),\n {\n status: 405,\n headers: { \"Content-Type\": \"application/json\" },\n },\n );\n }\n\n try {\n // Parse request body\n const contentType = request.headers.get(\"content-type\") || \"\";\n let data: unknown;\n\n if (contentType.includes(\"application/json\")) {\n data = await request.json();\n } else if (contentType.includes(\"application/x-www-form-urlencoded\")) {\n const formData = await request.formData();\n data = Object.fromEntries(formData.entries());\n } else if (contentType.includes(\"text/\")) {\n data = await request.text();\n } else {\n // For other content types, try to read as text\n data = await request.text();\n }\n\n // Validate signature if configured\n if (this.config.validateSignature) {\n const isValid = await this.validateSignature(request, data);\n if (!isValid) {\n return new Response(JSON.stringify({ error: \"Invalid signature\" }), {\n status: 401,\n headers: { \"Content-Type\": \"application/json\" },\n });\n }\n }\n\n // Create trigger event\n const eventId = crypto.randomUUID();\n const event: TriggerEvent = {\n id: eventId,\n type: this.type,\n source: `${this.config.method} ${this.config.path}`,\n data,\n metadata: {\n method: request.method,\n path: this.config.path,\n headers: Object.fromEntries(request.headers.entries()),\n },\n timestamp: new Date(),\n };\n\n // Invoke handler\n await this.handler(event);\n\n // Return success response\n const response: HttpTriggerResponse = {\n success: true,\n eventId,\n };\n\n return new Response(JSON.stringify(response), {\n status: 200,\n headers: { \"Content-Type\": \"application/json\" },\n });\n } catch (error) {\n return new Response(\n JSON.stringify({\n error: \"Internal server error\",\n message: (error as Error).message,\n }),\n {\n status: 500,\n headers: { \"Content-Type\": \"application/json\" },\n },\n );\n }\n }\n\n /**\n * Validate request signature using Web Crypto API\n * @private\n */\n private async validateSignature(\n request: Request,\n data: unknown,\n ): Promise<boolean> {\n if (!this.config.validateSignature) {\n return true;\n }\n\n const { header, secret, algorithm } = this.config.validateSignature;\n const signature = request.headers.get(header);\n\n if (!signature) {\n return false;\n }\n\n try {\n // Convert data to string for hashing\n const payload = typeof data === \"string\" ? data : JSON.stringify(data);\n\n // Create HMAC signature using Web Crypto API\n const encoder = new TextEncoder();\n const keyData = encoder.encode(secret);\n const messageData = encoder.encode(payload);\n\n // Import key for HMAC\n const cryptoKey = await crypto.subtle.importKey(\n \"raw\",\n keyData,\n {\n name: \"HMAC\",\n hash: algorithm === \"sha256\" ? \"SHA-256\" : \"SHA-1\",\n },\n false,\n [\"sign\"],\n );\n\n // Generate signature\n const signatureBuffer = await crypto.subtle.sign(\n \"HMAC\",\n cryptoKey,\n messageData,\n );\n\n // Convert to hex string\n const hashArray = Array.from(new Uint8Array(signatureBuffer));\n const hashHex = hashArray\n .map((b) => b.toString(16).padStart(2, \"0\"))\n .join(\"\");\n\n // Compare signatures (handle different formats)\n // Some services prefix with algorithm (e.g., \"sha256=...\")\n const expectedSignature = signature.includes(\"=\")\n ? signature.split(\"=\")[1]\n : signature;\n\n return hashHex === expectedSignature;\n } catch (error) {\n console.error(\"Signature validation error:\", error);\n return false;\n }\n }\n}\n"],"mappings":";AA4DO,IAAM,cAAN,MAAwD;AAAA,EAI7D,YAAqB,QAA2B;AAA3B;AAAA,EAA4B;AAAA,EAHxC,OAAO;AAAA,EACR;AAAA;AAAA;AAAA;AAAA;AAAA,EAQR,MAAM,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IACT;AAEA,UAAM,EAAE,QAAQ,QAAQ,UAAU,IAAI,KAAK,OAAO;AAClD,UAAM,YAAY,QAAQ,QAAQ,IAAI,MAAM;AAE5C,QAAI,CAAC,WAAW;AACd,aAAO;AAAA,IACT;AAEA,QAAI;AAEF,YAAM,UAAU,OAAO,SAAS,WAAW,OAAO,KAAK,UAAU,IAAI;AAGrE,YAAM,UAAU,IAAI,YAAY;AAChC,YAAM,UAAU,QAAQ,OAAO,MAAM;AACrC,YAAM,cAAc,QAAQ,OAAO,OAAO;AAG1C,YAAM,YAAY,MAAM,OAAO,OAAO;AAAA,QACpC;AAAA,QACA;AAAA,QACA;AAAA,UACE,MAAM;AAAA,UACN,MAAM,cAAc,WAAW,YAAY;AAAA,QAC7C;AAAA,QACA;AAAA,QACA,CAAC,MAAM;AAAA,MACT;AAGA,YAAM,kBAAkB,MAAM,OAAO,OAAO;AAAA,QAC1C;AAAA,QACA;AAAA,QACA;AAAA,MACF;AAGA,YAAM,YAAY,MAAM,KAAK,IAAI,WAAW,eAAe,CAAC;AAC5D,YAAM,UAAU,UACb,IAAI,CAAC,MAAM,EAAE,SAAS,EAAE,EAAE,SAAS,GAAG,GAAG,CAAC,EAC1C,KAAK,EAAE;AAIV,YAAM,oBAAoB,UAAU,SAAS,GAAG,IAC5C,UAAU,MAAM,GAAG,EAAE,CAAC,IACtB;AAEJ,aAAO,YAAY;AAAA,IACrB,SAAS,OAAO;AACd,cAAQ,MAAM,+BAA+B,KAAK;AAClD,aAAO;AAAA,IACT;AAAA,EACF;AACF;","names":[]}
package/package.json ADDED
@@ -0,0 +1,57 @@
1
+ {
2
+ "name": "@stepflowjs/trigger-http",
3
+ "version": "0.0.1",
4
+ "description": "HTTP trigger for Stepflow workflows",
5
+ "type": "module",
6
+ "main": "./dist/index.js",
7
+ "module": "./dist/index.js",
8
+ "types": "./dist/index.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "import": "./dist/index.js",
12
+ "types": "./dist/index.d.ts"
13
+ }
14
+ },
15
+ "files": [
16
+ "dist"
17
+ ],
18
+ "dependencies": {
19
+ "@stepflowjs/core": "0.0.1"
20
+ },
21
+ "devDependencies": {
22
+ "tsup": "^8.5.1",
23
+ "vitest": "^4.0.17"
24
+ },
25
+ "peerDependencies": {
26
+ "typescript": "^5.0.0"
27
+ },
28
+ "license": "MIT",
29
+ "author": "Stepflow Contributors",
30
+ "repository": {
31
+ "type": "git",
32
+ "url": "https://stepflow-production.up.railway.app",
33
+ "directory": "packages/triggers/http"
34
+ },
35
+ "homepage": "https://stepflow-production.up.railway.app",
36
+ "bugs": {
37
+ "url": "https://stepflow-production.up.railway.app"
38
+ },
39
+ "keywords": [
40
+ "stepflow",
41
+ "trigger",
42
+ "http",
43
+ "webhook",
44
+ "workflow",
45
+ "orchestration"
46
+ ],
47
+ "publishConfig": {
48
+ "access": "public"
49
+ },
50
+ "scripts": {
51
+ "build": "tsup",
52
+ "dev": "tsup --watch",
53
+ "typecheck": "tsc --noEmit",
54
+ "test": "vitest",
55
+ "clean": "rm -rf dist"
56
+ }
57
+ }