Purpose
viber-mcp is the first MCP server for Viber, used to connect AI assistants with the Viber Bot REST API. With it, MCP-compatible clients (such as Claude Desktop, Claude Code, Cursor, Windsurf, etc.) can control Viber bots using natural language to perform operations such as sending messages, transferring media and files, group broadcasting, Webhook management, and user data queries. Viber has more than 1 billion registered users and is especially popular in Ukraine, Eastern Europe, Greece, and Southeast Asia.
Main Capabilities
This server provides 13 tools, covering the complete interface surface of the Viber Bot API, including:
- Account and user-related operations
- Sending text, media, files, locations, and contacts
- Broadcasting messages to groups
- Managing Webhooks
- Querying user data
All tools use Zod schema for input validation before calling the Viber API. When an error occurs, the tool returns a human-readable error message and sets isError: true, so that the AI can determine how to continue processing.
Usage
The project supports instant trial (no installation required), and also supports global installation. After installation, you need to add configuration in the MCP client configuration file: macOS path: ~/Library/Application Support/Claude/claude_desktop_config.json Windows path: %APPDATA%\Claude\claude_desktop_config.json Windows note: replace "command": "npx" with "command": "cmd", and replace "args" with ["/c", "npx", "-y", "@serhii.zghama/viber-mcp"]. After configuration is complete, restart Claude Desktop, and the Viber tools will appear in the tools menu.
For Cursor, you can click + Add in Settings > MCP Servers and paste the configuration. For VS Code (Copilot), you can add the configuration in the workspace's .vscode/mcp.json.
Environment variables are read once at startup. Steps to obtain a Viber bot token:
- Open the Viber Admin Panel
- Create a new bot account (or select an existing account)
- Copy the token from the bot settings page
- Set it as VIBER_AUTH_TOKEN in the MCP client configuration
Note: Since February 2024, new Viber bot accounts may require commercial onboarding through a Viber partner. Existing bot tokens continue to be valid.
Applicable Scenarios
Suitable for developers or operators who need to manage Viber bots through an AI assistant using natural language, for example sending notifications, broadcasting messages, managing Webhooks, or querying user information.
Limitations and Architecture Notes
- Zero console.log: stdout is the MCP protocol channel; only console.error is used to output diagnostic information.
- Native fetch: axios/node-fetch is not used, and runtime dependencies are minimal.
- No retries: Viber REST calls are driven by the user through MCP, and silent retries would hide real problems from the AI.
- Zod validation: every tool input is validated before reaching the Viber API.
- Tools never throw exceptions: errors are caught and return { isError: true }, so that the AI can handle them gracefully.
Future plans (contributions welcome): rich media/carousels (send_rich_media tool, supporting carousel layouts), keyboards (interactive button keyboards on messages), Webhook receiver (a sibling package for receiving incoming events over HTTP), stickers (send_sticker tool), HTTP transport (Streamable HTTP for remote MCP deployment).
The project is licensed under MIT, and the author is Serhii Zghama.