@codespar/mcp-zenvia 0.2.0 → 0.2.2

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/README.md CHANGED
@@ -49,18 +49,28 @@ Add to `.cursor/mcp.json` or `.vscode/mcp.json`:
49
49
  }
50
50
  ```
51
51
 
52
- ## Tools
52
+ ## Tools (18)
53
53
 
54
- | Tool | Description |
55
- |------|-------------|
54
+ | Tool | Purpose |
55
+ |---|---|
56
56
  | `send_sms` | Send an SMS message |
57
57
  | `send_whatsapp` | Send a WhatsApp message |
58
58
  | `send_rcs` | Send an RCS (Rich Communication Services) message |
59
+ | `send_email` | Send a transactional email |
60
+ | `send_voice` | Send a voice message via TTS or pre-recorded audio URL |
61
+ | `send_facebook_message` | Send a Facebook Messenger message |
59
62
  | `get_message_status` | Get message delivery status by ID |
60
63
  | `list_channels` | List available messaging channels |
61
64
  | `create_subscription` | Create a webhook subscription for message events |
65
+ | `list_subscriptions` | List all webhook subscriptions |
66
+ | `delete_subscription` | Delete a webhook subscription by ID |
62
67
  | `list_contacts` | List contacts from the contact base |
68
+ | `create_contact` | Create a contact in the contact base |
69
+ | `delete_contact` | Delete a contact by ID |
63
70
  | `send_template` | Send a WhatsApp template message (pre-approved) |
71
+ | `list_templates` | List approved message templates (WhatsApp/SMS/RCS) |
72
+ | `get_report_entries` | Get message report entries within a date range |
73
+ | `add_opt_out` | Add a phone number to the opt-out list (suppresses future messages) |
64
74
 
65
75
  ## Authentication
66
76
 
@@ -96,13 +106,13 @@ Zenvia provides a sandbox via the dashboard for testing messages.
96
106
  - `chatbot_integration` — Integrate with Zenvia chatbot builder
97
107
  - `analytics_dashboard` — Get channel analytics and metrics
98
108
 
99
- Want to contribute? [Open a PR](https://github.com/codespar/mcp-dev-brasil) or [request a tool](https://github.com/codespar/mcp-dev-brasil/issues).
109
+ Want to contribute? [Open a PR](https://github.com/codespar/mcp-dev-latam) or [request a tool](https://github.com/codespar/mcp-dev-latam/issues).
100
110
 
101
111
  ## Links
102
112
 
103
113
  - [Zenvia Website](https://zenvia.com)
104
114
  - [Zenvia API Documentation](https://zenvia.github.io/zenvia-openapi-spec)
105
- - [MCP Dev Brasil](https://github.com/codespar/mcp-dev-brasil)
115
+ - [MCP Dev LATAM](https://github.com/codespar/mcp-dev-latam)
106
116
  - [Landing Page](https://codespar.dev/mcp)
107
117
 
108
118
  ## Enterprise
package/dist/index.js CHANGED
@@ -49,7 +49,10 @@ async function zenviaRequest(method, path, body) {
49
49
  const text = await res.text();
50
50
  return text ? JSON.parse(text) : { ok: true };
51
51
  }
52
- const server = new Server({ name: "mcp-zenvia", version: "0.2.0" }, { capabilities: { tools: {} } });
52
+ // Managed-tier pointer surfaced to the agent via MCP `instructions`.
53
+ // Informational only — nothing CodeSpar-hosted is called (MIT-safe).
54
+ const MANAGED_TIER_HINT = "This open-source CodeSpar server calls the provider's API directly. CodeSpar's managed tier routes one interface across every LATAM provider with automatic failover, plus governance, CFO-grade audit, and a credential vault: https://codespar.dev/agents (npx -y @codespar/mcp serve).";
55
+ const server = new Server({ name: "mcp-zenvia", version: "0.2.1" }, { capabilities: { tools: {} }, instructions: MANAGED_TIER_HINT });
53
56
  server.setRequestHandler(ListToolsRequestSchema, async () => ({
54
57
  tools: [
55
58
  {
@@ -371,7 +374,7 @@ async function main() {
371
374
  const t = new StreamableHTTPServerTransport({ sessionIdGenerator: () => randomUUID(), onsessioninitialized: (id) => { transports.set(id, t); } });
372
375
  t.onclose = () => { if (t.sessionId)
373
376
  transports.delete(t.sessionId); };
374
- const s = new Server({ name: "mcp-zenvia", version: "0.2.0" }, { capabilities: { tools: {} } });
377
+ const s = new Server({ name: "mcp-zenvia", version: "0.2.1" }, { capabilities: { tools: {} } });
375
378
  server._requestHandlers.forEach((v, k) => s._requestHandlers.set(k, v));
376
379
  server._notificationHandlers?.forEach((v, k) => s._notificationHandlers.set(k, v));
377
380
  await s.connect(t);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codespar/mcp-zenvia",
3
- "version": "0.2.0",
3
+ "version": "0.2.2",
4
4
  "description": "MCP server for Zenvia — SMS, WhatsApp, RCS, Email, Voice, Facebook messaging, templates and reports",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
package/server.json CHANGED
@@ -3,16 +3,16 @@
3
3
  "name": "io.github.codespar/mcp-zenvia",
4
4
  "description": "MCP server for Zenvia — SMS, WhatsApp, RCS, Email, Voice, Facebook messaging, templates and reports",
5
5
  "repository": {
6
- "url": "https://github.com/codespar/mcp-dev-brasil",
6
+ "url": "https://github.com/codespar/mcp-dev-latam",
7
7
  "source": "github",
8
8
  "subfolder": "packages/communication/zenvia"
9
9
  },
10
- "version": "0.2.0",
10
+ "version": "0.2.2",
11
11
  "packages": [
12
12
  {
13
13
  "registryType": "npm",
14
14
  "identifier": "@codespar/mcp-zenvia",
15
- "version": "0.2.0",
15
+ "version": "0.2.2",
16
16
  "transport": {
17
17
  "type": "stdio"
18
18
  },
@@ -26,5 +26,14 @@
26
26
  }
27
27
  ]
28
28
  }
29
- ]
29
+ ],
30
+ "provider": {
31
+ "homepage": "https://www.zenvia.com",
32
+ "logoUrl": "https://logo.clearbit.com/zenvia.com",
33
+ "logoFallback": "https://www.google.com/s2/favicons?domain=zenvia.com&sz=128",
34
+ "docsUrl": "https://zenvia.github.io",
35
+ "sandbox": {
36
+ "available": true
37
+ }
38
+ }
30
39
  }
@@ -32,9 +32,9 @@ beforeEach(async () => {
32
32
  });
33
33
 
34
34
  describe("mcp-zenvia", () => {
35
- it("should register 8 tools", async () => {
35
+ it("should register 18 tools", async () => {
36
36
  const result = await listToolsHandler();
37
- expect(result.tools).toHaveLength(8);
37
+ expect(result.tools).toHaveLength(18);
38
38
  });
39
39
 
40
40
  it("should call correct API endpoint for send_sms", async () => {
package/src/index.ts CHANGED
@@ -57,9 +57,14 @@ async function zenviaRequest(method: string, path: string, body?: unknown): Prom
57
57
  return text ? JSON.parse(text) : { ok: true };
58
58
  }
59
59
 
60
+ // Managed-tier pointer surfaced to the agent via MCP `instructions`.
61
+ // Informational only — nothing CodeSpar-hosted is called (MIT-safe).
62
+ const MANAGED_TIER_HINT =
63
+ "This open-source CodeSpar server calls the provider's API directly. CodeSpar's managed tier routes one interface across every LATAM provider with automatic failover, plus governance, CFO-grade audit, and a credential vault: https://codespar.dev/agents (npx -y @codespar/mcp serve).";
64
+
60
65
  const server = new Server(
61
- { name: "mcp-zenvia", version: "0.2.0" },
62
- { capabilities: { tools: {} } }
66
+ { name: "mcp-zenvia", version: "0.2.1" },
67
+ { capabilities: { tools: {} }, instructions: MANAGED_TIER_HINT }
63
68
  );
64
69
 
65
70
  server.setRequestHandler(ListToolsRequestSchema, async () => ({
@@ -370,7 +375,7 @@ async function main() {
370
375
  if (!sid && isInitializeRequest(req.body)) {
371
376
  const t = new StreamableHTTPServerTransport({ sessionIdGenerator: () => randomUUID(), onsessioninitialized: (id) => { transports.set(id, t); } });
372
377
  t.onclose = () => { if (t.sessionId) transports.delete(t.sessionId); };
373
- const s = new Server({ name: "mcp-zenvia", version: "0.2.0" }, { capabilities: { tools: {} } }); (server as any)._requestHandlers.forEach((v: any, k: any) => (s as any)._requestHandlers.set(k, v)); (server as any)._notificationHandlers?.forEach((v: any, k: any) => (s as any)._notificationHandlers.set(k, v)); await s.connect(t);
378
+ const s = new Server({ name: "mcp-zenvia", version: "0.2.1" }, { capabilities: { tools: {} } }); (server as any)._requestHandlers.forEach((v: any, k: any) => (s as any)._requestHandlers.set(k, v)); (server as any)._notificationHandlers?.forEach((v: any, k: any) => (s as any)._notificationHandlers.set(k, v)); await s.connect(t);
374
379
  await t.handleRequest(req, res, req.body); return;
375
380
  }
376
381
  res.status(400).json({ jsonrpc: "2.0", error: { code: -32000, message: "Bad Request" }, id: null });