@webhooks-cc/mcp 0.2.0 → 0.3.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/dist/bin/mcp.js CHANGED
@@ -92,7 +92,7 @@ function registerTools(server, client) {
92
92
  method: import_zod.z.enum(["GET", "POST", "PUT", "PATCH", "DELETE", "HEAD", "OPTIONS"]).default("POST").describe("HTTP method (default: POST)"),
93
93
  headers: import_zod.z.record(import_zod.z.string()).optional().describe("HTTP headers to include"),
94
94
  body: import_zod.z.unknown().optional().describe("Request body (will be JSON-serialized)"),
95
- provider: import_zod.z.enum(["stripe", "github", "shopify", "twilio"]).optional().describe("Optional provider template to send with signed headers"),
95
+ provider: import_zod.z.enum(["stripe", "github", "shopify", "twilio", "standard-webhooks"]).optional().describe("Optional provider template to send with signed headers"),
96
96
  template: import_zod.z.string().optional().describe("Optional provider-specific template preset (for example: pull_request.opened)"),
97
97
  event: import_zod.z.string().optional().describe("Optional provider event/topic name when provider template is used"),
98
98
  secret: import_zod.z.string().optional().describe(
@@ -194,6 +194,51 @@ function registerTools(server, client) {
194
194
  );
195
195
  })
196
196
  );
197
+ server.tool(
198
+ "send_to",
199
+ "Send a webhook directly to any URL with optional provider signing. Use this for local integration testing \u2014 send properly signed webhooks to localhost handlers without routing through webhooks.cc infrastructure.",
200
+ {
201
+ url: import_zod.z.string().url().refine(
202
+ (u) => {
203
+ try {
204
+ const p = new URL(u).protocol;
205
+ return p === "http:" || p === "https:";
206
+ } catch {
207
+ return false;
208
+ }
209
+ },
210
+ { message: "Only http and https URLs are supported" }
211
+ ).describe("Target URL to send the webhook to"),
212
+ method: import_zod.z.enum(["GET", "POST", "PUT", "PATCH", "DELETE", "HEAD", "OPTIONS"]).default("POST").describe("HTTP method (default: POST)"),
213
+ headers: import_zod.z.record(import_zod.z.string()).optional().describe("HTTP headers to include"),
214
+ body: import_zod.z.unknown().optional().describe("Request body (will be JSON-serialized)"),
215
+ provider: import_zod.z.enum(["stripe", "github", "shopify", "twilio", "standard-webhooks"]).optional().describe("Optional provider template for signing"),
216
+ template: import_zod.z.string().optional().describe("Provider-specific template preset (not used for standard-webhooks)"),
217
+ event: import_zod.z.string().optional().describe("Provider event/topic name"),
218
+ secret: import_zod.z.string().optional().describe(
219
+ "Shared secret for provider signature generation (required when provider is set)"
220
+ )
221
+ },
222
+ withErrorHandling(async ({ url, method, headers, body, provider, template, event, secret }) => {
223
+ const response = await client.sendTo(url, {
224
+ method,
225
+ headers,
226
+ body,
227
+ provider,
228
+ template,
229
+ event,
230
+ secret
231
+ });
232
+ const responseBody = await readBodyTruncated(response);
233
+ return textContent(
234
+ JSON.stringify(
235
+ { status: response.status, statusText: response.statusText, body: responseBody },
236
+ null,
237
+ 2
238
+ )
239
+ );
240
+ })
241
+ );
197
242
  server.tool(
198
243
  "describe",
199
244
  "Describe all available SDK operations, their parameters, and types. Useful for discovering what actions are possible.",
@@ -206,7 +251,7 @@ function registerTools(server, client) {
206
251
  }
207
252
 
208
253
  // src/index.ts
209
- var VERSION = true ? "0.2.0" : "0.0.0-dev";
254
+ var VERSION = true ? "0.3.0" : "0.0.0-dev";
210
255
  function createServer(options = {}) {
211
256
  const apiKey = options.apiKey ?? process.env.WHK_API_KEY;
212
257
  if (!apiKey) {
package/dist/index.js CHANGED
@@ -111,7 +111,7 @@ function registerTools(server, client) {
111
111
  method: import_zod.z.enum(["GET", "POST", "PUT", "PATCH", "DELETE", "HEAD", "OPTIONS"]).default("POST").describe("HTTP method (default: POST)"),
112
112
  headers: import_zod.z.record(import_zod.z.string()).optional().describe("HTTP headers to include"),
113
113
  body: import_zod.z.unknown().optional().describe("Request body (will be JSON-serialized)"),
114
- provider: import_zod.z.enum(["stripe", "github", "shopify", "twilio"]).optional().describe("Optional provider template to send with signed headers"),
114
+ provider: import_zod.z.enum(["stripe", "github", "shopify", "twilio", "standard-webhooks"]).optional().describe("Optional provider template to send with signed headers"),
115
115
  template: import_zod.z.string().optional().describe("Optional provider-specific template preset (for example: pull_request.opened)"),
116
116
  event: import_zod.z.string().optional().describe("Optional provider event/topic name when provider template is used"),
117
117
  secret: import_zod.z.string().optional().describe(
@@ -213,6 +213,51 @@ function registerTools(server, client) {
213
213
  );
214
214
  })
215
215
  );
216
+ server.tool(
217
+ "send_to",
218
+ "Send a webhook directly to any URL with optional provider signing. Use this for local integration testing \u2014 send properly signed webhooks to localhost handlers without routing through webhooks.cc infrastructure.",
219
+ {
220
+ url: import_zod.z.string().url().refine(
221
+ (u) => {
222
+ try {
223
+ const p = new URL(u).protocol;
224
+ return p === "http:" || p === "https:";
225
+ } catch {
226
+ return false;
227
+ }
228
+ },
229
+ { message: "Only http and https URLs are supported" }
230
+ ).describe("Target URL to send the webhook to"),
231
+ method: import_zod.z.enum(["GET", "POST", "PUT", "PATCH", "DELETE", "HEAD", "OPTIONS"]).default("POST").describe("HTTP method (default: POST)"),
232
+ headers: import_zod.z.record(import_zod.z.string()).optional().describe("HTTP headers to include"),
233
+ body: import_zod.z.unknown().optional().describe("Request body (will be JSON-serialized)"),
234
+ provider: import_zod.z.enum(["stripe", "github", "shopify", "twilio", "standard-webhooks"]).optional().describe("Optional provider template for signing"),
235
+ template: import_zod.z.string().optional().describe("Provider-specific template preset (not used for standard-webhooks)"),
236
+ event: import_zod.z.string().optional().describe("Provider event/topic name"),
237
+ secret: import_zod.z.string().optional().describe(
238
+ "Shared secret for provider signature generation (required when provider is set)"
239
+ )
240
+ },
241
+ withErrorHandling(async ({ url, method, headers, body, provider, template, event, secret }) => {
242
+ const response = await client.sendTo(url, {
243
+ method,
244
+ headers,
245
+ body,
246
+ provider,
247
+ template,
248
+ event,
249
+ secret
250
+ });
251
+ const responseBody = await readBodyTruncated(response);
252
+ return textContent(
253
+ JSON.stringify(
254
+ { status: response.status, statusText: response.statusText, body: responseBody },
255
+ null,
256
+ 2
257
+ )
258
+ );
259
+ })
260
+ );
216
261
  server.tool(
217
262
  "describe",
218
263
  "Describe all available SDK operations, their parameters, and types. Useful for discovering what actions are possible.",
@@ -225,7 +270,7 @@ function registerTools(server, client) {
225
270
  }
226
271
 
227
272
  // src/index.ts
228
- var VERSION = true ? "0.2.0" : "0.0.0-dev";
273
+ var VERSION = true ? "0.3.0" : "0.0.0-dev";
229
274
  function createServer(options = {}) {
230
275
  const apiKey = options.apiKey ?? process.env.WHK_API_KEY;
231
276
  if (!apiKey) {
package/dist/index.mjs CHANGED
@@ -86,7 +86,7 @@ function registerTools(server, client) {
86
86
  method: z.enum(["GET", "POST", "PUT", "PATCH", "DELETE", "HEAD", "OPTIONS"]).default("POST").describe("HTTP method (default: POST)"),
87
87
  headers: z.record(z.string()).optional().describe("HTTP headers to include"),
88
88
  body: z.unknown().optional().describe("Request body (will be JSON-serialized)"),
89
- provider: z.enum(["stripe", "github", "shopify", "twilio"]).optional().describe("Optional provider template to send with signed headers"),
89
+ provider: z.enum(["stripe", "github", "shopify", "twilio", "standard-webhooks"]).optional().describe("Optional provider template to send with signed headers"),
90
90
  template: z.string().optional().describe("Optional provider-specific template preset (for example: pull_request.opened)"),
91
91
  event: z.string().optional().describe("Optional provider event/topic name when provider template is used"),
92
92
  secret: z.string().optional().describe(
@@ -188,6 +188,51 @@ function registerTools(server, client) {
188
188
  );
189
189
  })
190
190
  );
191
+ server.tool(
192
+ "send_to",
193
+ "Send a webhook directly to any URL with optional provider signing. Use this for local integration testing \u2014 send properly signed webhooks to localhost handlers without routing through webhooks.cc infrastructure.",
194
+ {
195
+ url: z.string().url().refine(
196
+ (u) => {
197
+ try {
198
+ const p = new URL(u).protocol;
199
+ return p === "http:" || p === "https:";
200
+ } catch {
201
+ return false;
202
+ }
203
+ },
204
+ { message: "Only http and https URLs are supported" }
205
+ ).describe("Target URL to send the webhook to"),
206
+ method: z.enum(["GET", "POST", "PUT", "PATCH", "DELETE", "HEAD", "OPTIONS"]).default("POST").describe("HTTP method (default: POST)"),
207
+ headers: z.record(z.string()).optional().describe("HTTP headers to include"),
208
+ body: z.unknown().optional().describe("Request body (will be JSON-serialized)"),
209
+ provider: z.enum(["stripe", "github", "shopify", "twilio", "standard-webhooks"]).optional().describe("Optional provider template for signing"),
210
+ template: z.string().optional().describe("Provider-specific template preset (not used for standard-webhooks)"),
211
+ event: z.string().optional().describe("Provider event/topic name"),
212
+ secret: z.string().optional().describe(
213
+ "Shared secret for provider signature generation (required when provider is set)"
214
+ )
215
+ },
216
+ withErrorHandling(async ({ url, method, headers, body, provider, template, event, secret }) => {
217
+ const response = await client.sendTo(url, {
218
+ method,
219
+ headers,
220
+ body,
221
+ provider,
222
+ template,
223
+ event,
224
+ secret
225
+ });
226
+ const responseBody = await readBodyTruncated(response);
227
+ return textContent(
228
+ JSON.stringify(
229
+ { status: response.status, statusText: response.statusText, body: responseBody },
230
+ null,
231
+ 2
232
+ )
233
+ );
234
+ })
235
+ );
191
236
  server.tool(
192
237
  "describe",
193
238
  "Describe all available SDK operations, their parameters, and types. Useful for discovering what actions are possible.",
@@ -200,7 +245,7 @@ function registerTools(server, client) {
200
245
  }
201
246
 
202
247
  // src/index.ts
203
- var VERSION = true ? "0.2.0" : "0.0.0-dev";
248
+ var VERSION = true ? "0.3.0" : "0.0.0-dev";
204
249
  function createServer(options = {}) {
205
250
  const apiKey = options.apiKey ?? process.env.WHK_API_KEY;
206
251
  if (!apiKey) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webhooks-cc/mcp",
3
- "version": "0.2.0",
3
+ "version": "0.3.0",
4
4
  "description": "MCP server for webhooks.cc — AI agent integration for webhook testing",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -36,9 +36,9 @@
36
36
  },
37
37
  "homepage": "https://webhooks.cc",
38
38
  "dependencies": {
39
- "@modelcontextprotocol/sdk": "^1.12.1",
39
+ "@modelcontextprotocol/sdk": "^1.27.1",
40
40
  "zod": "^3.25.0",
41
- "@webhooks-cc/sdk": "0.4.0"
41
+ "@webhooks-cc/sdk": "0.5.0"
42
42
  },
43
43
  "devDependencies": {
44
44
  "tsup": "^8.5.1",