@codespar/mcp-evolution-api 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
@@ -51,10 +51,10 @@ Add to `.cursor/mcp.json` or `.vscode/mcp.json`:
51
51
  }
52
52
  ```
53
53
 
54
- ## Tools
54
+ ## Tools (25)
55
55
 
56
- | Tool | Description |
57
- |------|-------------|
56
+ | Tool | Purpose |
57
+ |---|---|
58
58
  | `send_text` | Send a text message via WhatsApp |
59
59
  | `send_image` | Send an image message via WhatsApp |
60
60
  | `send_document` | Send a document via WhatsApp |
@@ -65,6 +65,21 @@ Add to `.cursor/mcp.json` or `.vscode/mcp.json`:
65
65
  | `send_poll` | Send a poll message via WhatsApp |
66
66
  | `get_messages` | Get messages from a chat |
67
67
  | `check_number` | Check if a phone number is registered on WhatsApp |
68
+ | `create_group` | Create a WhatsApp group |
69
+ | `get_group_info` | Get group metadata, participants, and settings |
70
+ | `update_profile` | Update instance profile (name, status text, or picture) |
71
+ | `set_presence` | Set online/offline presence for an instance |
72
+ | `get_chat_history` | Get full chat history with pagination support |
73
+ | `logout_instance` | Logout an instance (disconnects the WhatsApp session without deleting the instance) |
74
+ | `restart_instance` | Restart an instance |
75
+ | `delete_instance` | Delete an instance permanently |
76
+ | `connection_state` | Get the connection state of an instance (open, connecting, close) |
77
+ | `leave_group` | Leave a WhatsApp group |
78
+ | `update_group_participants` | Add, remove, promote, or demote participants in a WhatsApp group |
79
+ | `fetch_group_invite_code` | Fetch the invite code/link for a WhatsApp group |
80
+ | `mark_message_as_read` | Mark one or more messages in a chat as read |
81
+ | `archive_chat` | Archive or unarchive a chat |
82
+ | `delete_message` | Delete a message for me or for everyone in a chat |
68
83
 
69
84
  ## Authentication
70
85
 
@@ -102,13 +117,13 @@ Evolution API is self-hosted. Deploy your own instance using Docker for testing.
102
117
  - `template_messages` — Send WhatsApp Business template messages
103
118
  - `label_management` — Create, update, and assign labels to chats
104
119
 
105
- 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).
120
+ 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).
106
121
 
107
122
  ## Links
108
123
 
109
124
  - [Evolution API Documentation](https://doc.evolution-api.com)
110
125
  - [Evolution API GitHub](https://github.com/EvolutionAPI/evolution-api)
111
- - [MCP Dev Brasil](https://github.com/codespar/mcp-dev-brasil)
126
+ - [MCP Dev LATAM](https://github.com/codespar/mcp-dev-latam)
112
127
  - [Landing Page](https://codespar.dev/mcp)
113
128
 
114
129
  ## Enterprise
package/dist/index.js CHANGED
@@ -55,7 +55,10 @@ async function evolutionRequest(method, path, body) {
55
55
  }
56
56
  return res.json();
57
57
  }
58
- const server = new Server({ name: "mcp-evolution-api", version: "0.2.0" }, { capabilities: { tools: {} } });
58
+ // Managed-tier pointer surfaced to the agent via MCP `instructions`.
59
+ // Informational only — nothing CodeSpar-hosted is called (MIT-safe).
60
+ 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).";
61
+ const server = new Server({ name: "mcp-evolution-api", version: "0.2.1" }, { capabilities: { tools: {} }, instructions: MANAGED_TIER_HINT });
59
62
  server.setRequestHandler(ListToolsRequestSchema, async () => ({
60
63
  tools: [
61
64
  {
@@ -520,7 +523,7 @@ async function main() {
520
523
  const t = new StreamableHTTPServerTransport({ sessionIdGenerator: () => randomUUID(), onsessioninitialized: (id) => { transports.set(id, t); } });
521
524
  t.onclose = () => { if (t.sessionId)
522
525
  transports.delete(t.sessionId); };
523
- const s = new Server({ name: "mcp-evolution-api", version: "0.2.0" }, { capabilities: { tools: {} } });
526
+ const s = new Server({ name: "mcp-evolution-api", version: "0.2.1" }, { capabilities: { tools: {} } });
524
527
  server._requestHandlers.forEach((v, k) => s._requestHandlers.set(k, v));
525
528
  server._notificationHandlers?.forEach((v, k) => s._notificationHandlers.set(k, v));
526
529
  await s.connect(t);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codespar/mcp-evolution-api",
3
- "version": "0.2.0",
3
+ "version": "0.2.2",
4
4
  "description": "MCP server for Evolution API — WhatsApp messaging, instances, contacts",
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-evolution-api",
4
4
  "description": "MCP server for Evolution API — WhatsApp messaging, instances, contacts",
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/evolution-api"
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-evolution-api",
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.evolution-api.com",
32
+ "logoUrl": "https://logo.clearbit.com/evolution-api.com",
33
+ "logoFallback": "https://www.google.com/s2/favicons?domain=evolution-api.com&sz=128",
34
+ "docsUrl": "https://doc.evolution-api.com",
35
+ "sandbox": {
36
+ "available": false
37
+ }
38
+ }
30
39
  }
@@ -33,9 +33,9 @@ beforeEach(async () => {
33
33
  });
34
34
 
35
35
  describe("mcp-evolution-api", () => {
36
- it("should register 15 tools", async () => {
36
+ it("should register 25 tools", async () => {
37
37
  const result = await listToolsHandler();
38
- expect(result.tools).toHaveLength(15);
38
+ expect(result.tools).toHaveLength(25);
39
39
  });
40
40
 
41
41
  it("should call correct API endpoint for send_text", async () => {
package/src/index.ts CHANGED
@@ -63,9 +63,14 @@ async function evolutionRequest(method: string, path: string, body?: unknown): P
63
63
  return res.json();
64
64
  }
65
65
 
66
+ // Managed-tier pointer surfaced to the agent via MCP `instructions`.
67
+ // Informational only — nothing CodeSpar-hosted is called (MIT-safe).
68
+ const MANAGED_TIER_HINT =
69
+ "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).";
70
+
66
71
  const server = new Server(
67
- { name: "mcp-evolution-api", version: "0.2.0" },
68
- { capabilities: { tools: {} } }
72
+ { name: "mcp-evolution-api", version: "0.2.1" },
73
+ { capabilities: { tools: {} }, instructions: MANAGED_TIER_HINT }
69
74
  );
70
75
 
71
76
  server.setRequestHandler(ListToolsRequestSchema, async () => ({
@@ -521,7 +526,7 @@ async function main() {
521
526
  if (!sid && isInitializeRequest(req.body)) {
522
527
  const t = new StreamableHTTPServerTransport({ sessionIdGenerator: () => randomUUID(), onsessioninitialized: (id) => { transports.set(id, t); } });
523
528
  t.onclose = () => { if (t.sessionId) transports.delete(t.sessionId); };
524
- const s = new Server({ name: "mcp-evolution-api", 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);
529
+ const s = new Server({ name: "mcp-evolution-api", 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);
525
530
  await t.handleRequest(req, res, req.body); return;
526
531
  }
527
532
  res.status(400).json({ jsonrpc: "2.0", error: { code: -32000, message: "Bad Request" }, id: null });