Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

2Chat plugin for Hermes Agent

Connect Hermes Agent to 2Chat, the business messaging platform for WhatsApp, WhatsApp Business API (WABA), SMS and phone calls. Read, summarize and reply to customer conversations, manage WABA templates and contacts, review phone calls, and manage virtual phone numbers, all through the hosted 2Chat MCP server.

Install in Hermes Agent

You need Hermes Agent 0.21.6 or newer and Node.js 20.18.1 or newer with npx on your PATH.

From the Hermes plugin catalog:

hermes plugins install 2chat
hermes plugins enable 2chat

Or straight from GitHub:

hermes plugins install 2ChatCo/2chat-hermes-plugin --no-enable
hermes plugins enable 2chat

Start a new session. The first time the server starts, your browser opens the 2Chat sign-in page. Sign in with the 2Chat account you want Hermes to work with and approve. The token is kept and refreshed, so you sign in once. If the tools don't show up after you sign in, run /reload-mcp.

Requires a 2Chat account at https://2chat.co. No API key is needed and nothing should be pasted into chat.

What you get

  • MCP server 2chat, the hosted 2Chat MCP server at https://mcp.2chat.io/mcp (Streamable HTTP, OAuth 2.1), reached through the pinned mcp-remote bridge.
  • Skill 2chat: how to use the 2Chat tools well (discover channels before acting, E.164 phone numbers, the WABA 24-hour window, confirm every send and every destructive action).

Tools

Area Tools
Account get_who_am_i, get_billing_info, list_account_users
WhatsApp get_whatsapp_numbers, get_whatsapp_number, connect_whatsapp_number, disconnect_whatsapp_number, check_if_number_is_on_whatsapp, list_whatsapp_conversations, get_whatsapp_messages, send_whatsapp_message, list_whatsapp_groups, list_whatsapp_group_participants, get_whatsapp_group_messages, set_whatsapp_text_status, set_whatsapp_image_status, set_whatsapp_video_status, list_whatsapp_catalog_products
WhatsApp Business API get_waba_numbers, get_waba_number, get_waba_templates, get_waba_template, create_waba_template, delete_waba_template, sync_waba_templates, calculate_waba_template_cost, get_waba_conversation_window, send_waba_message, get_waba_messages, get_waba_message, get_waba_received_messages, list_waba_conversations, subscribe_to_waba_webhook
SMS list_sms_channels, get_sms_channel, list_sms_conversations, get_sms_messages, get_sms_message, send_sms
Contacts list_contacts, search_contacts, get_contact, create_contact, update_contact, delete_contact
Phone numbers get_number_regions, get_number_cities, get_did_types, get_number_requirements, search_number_groups, get_available_numbers, reserve_number, list_number_reservations, cancel_number_reservation, purchase_number
Voice list_virtual_numbers, delete_virtual_number, get_call_history, get_call_details, get_call_price

Every tool carries MCP annotations (readOnlyHint, destructiveHint, idempotentHint, openWorldHint). Forty-one of the sixty tools are read-only. In Hermes the tools appear as mcp__2chat__<tool>.

Example prompts

  • "Which 2Chat account am I connected to?"
  • "Summarize my most recent WhatsApp conversations."
  • "Show the WhatsApp Business templates approved on my number."
  • "Reply to the last message from +14155550123 and tell them the order has shipped."
  • "Show the phone calls I received yesterday on my virtual numbers."

Before you install

The Hermes package is plugin.json, mcp.json and the skill in skills/2chat/. It ships no code of its own. Know that:

  • mcp.json runs the pinned mcp-remote@0.15.2 through npx, which downloads it from npm on first use. It opens a local callback port for the sign-in and stores the OAuth tokens in the plugin's Hermes data directory (MCP_REMOTE_CONFIG_DIR is set to ${PLUGIN_DATA}/mcp-auth), so they follow the active Hermes profile and go away with the plugin.
  • Every tool call goes to mcp.2chat.io and acts on your 2Chat account with your own role there. The server decides the tool set at runtime, so the pinned commit doesn't cover it.
  • plugin.json marks the server untrusted. Hermes asks before every tool the server doesn't mark read-only (sending messages, posting statuses, creating or deleting templates and contacts, connecting or disconnecting numbers, reserving and buying numbers, webhooks), and refuses those tools in cron and other unattended runs.
  • Messaging tools deliver real WhatsApp and SMS messages to real phone numbers and can incur carrier or Meta charges. reserve_number and purchase_number spend your 2Chat balance. The bundled skill tells Hermes to confirm every send, status post, deletion, disconnection and purchase with you first, and never to send bulk or unsolicited messages.
  • The package sends no telemetry.

Without Node.js

Hermes has a native OAuth client for remote MCP servers. If you would rather not run npx, skip the plugin and add the server to ~/.hermes/config.yaml:

mcp_servers:
  2chat:
    url: "https://mcp.2chat.io/mcp"
    auth: oauth
    trust: untrusted

Then run hermes mcp login 2chat. You lose the bundled skill, but the tools are the same.

Authentication and network

The plugin connects only to https://mcp.2chat.io (and to npm, to fetch mcp-remote). Authentication is OAuth 2.1 authorization code with PKCE (S256) and dynamic client registration, performed by mcp-remote.

Network endpoints:

  • https://mcp.2chat.io/mcp: hosted MCP (Streamable HTTP)
  • https://mcp.2chat.io/authorize, /token, /register, /revoke: OAuth 2.1 + DCR
  • https://mcp.2chat.io/.well-known/oauth-authorization-server, /.well-known/oauth-protected-resource: discovery metadata
  • https://auth.2chat.io: human sign-in and consent screen during authorization
  • https://registry.npmjs.org: npx downloads the pinned mcp-remote on first use

Credentials: a 2Chat account. The MCP server exchanges the grant for a token scoped to that account and sends it as Authorization: Bearer on /mcp. The plugin stores no API key and requests no filesystem or shell access beyond running npx. Tools act only on channels and data the signed-in user can already see in 2Chat.

Alternative: plain MCP

For Claude, Cursor, ChatGPT or any other MCP client with OAuth support, point it at the server directly:

{
  "mcpServers": {
    "2chat": {
      "type": "http",
      "url": "https://mcp.2chat.io/mcp"
    }
  }
}

MCP setup docs

License

MIT for the files in this plugin. Use of the hosted MCP server is governed by the 2Chat terms of service and privacy policy.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors