Skip to main content
Glama
README_1756255685740.mdโ€ข7.33 kB
# MoluAbi MCP Client > **Standalone Command-Line Interface for MoluAbi AI Agent Management** This is a **Model Context Protocol (MCP) client** that provides programmatic access to MoluAbi's AI agent management platform. It connects to the MoluAbi MCP server to create, manage, and interact with AI assistants through a beautiful command-line interface. ## ๐ŸŽฏ What This Does This client allows you to **manage MoluAbi AI agents without using the web interface**: - **Create agents** with custom instructions and capabilities - **Chat with agents** in real-time through the terminal - **Manage team access** by adding/removing users via email - **Monitor usage** and costs for all your agents - **List and organize** all accessible agents - **Delete agents** safely with confirmation prompts All operations sync perfectly with the MoluAbi web platform - agents created here appear in the web UI and vice versa. ## ๐Ÿš€ Quick Start ### Prerequisites - Node.js 18+ installed - Access to a running MoluAbi MCP server - Database connection (same as MoluAbi platform) ### Installation ```bash # Clone or copy this directory anywhere cd mcp-client # Install dependencies npm install # Set up environment (copy from MoluAbi platform) cp .env.example .env # Edit .env with your database URL ``` ### Basic Usage ```bash # Interactive mode (recommended for first-time users) npm run cli interactive # Or use specific commands directly npm run cli create # Create a new agent npm run cli list # List your agents npm run cli chat # Chat with an agent npm run cli tools # View available operations ``` ## ๐Ÿ“‹ Available Commands | Command | Description | Example | |---------|-------------|---------| | `interactive` | Full guided experience | `npm run cli interactive` | | `create` | Create new agent | `npm run cli create` | | `list` | Show all your agents | `npm run cli list` | | `chat` | Chat with an agent | `npm run cli chat` | | `users` | Manage agent access | `npm run cli users` | | `delete` | Remove an agent | `npm run cli delete` | | `tools` | Show available MCP tools | `npm run cli tools` | ## ๐ŸŽฎ Example Workflow ### 1. Create Your First Agent ```bash npm run cli create ``` Follow the prompts to: - Name your agent (e.g., "Customer Support Bot") - Add description and instructions - Choose agent type (file-based, team, hybrid) - Set visibility (public/private) ### 2. Chat With Your Agent ```bash npm run cli chat ``` - Enter the agent ID from step 1 - Start chatting! Type 'exit' to quit ### 3. Manage Team Access ```bash npm run cli users ``` - Add teammates by email - Grant or revoke access to specific agents ## ๐Ÿ”ง How It Works ### MCP Connection The client uses the **Model Context Protocol** to communicate with the MoluAbi server: ```typescript // Connects to MoluAbi MCP server automatically const client = new MoluAbiMCPClient(); await client.connect(); // Uses 10 available MCP tools: // create_agent, list_agents, prompt_agent, etc. ``` ### Tool Integration The client exposes **10 MCP tools** for complete agent management: 1. **create_agent** - Build new AI assistants 2. **list_agents** - Query accessible agents 3. **get_agent** - Retrieve agent details 4. **update_agent** - Modify agent settings 5. **delete_agent** - Remove agents safely 6. **prompt_agent** - Send messages and get responses 7. **add_user_to_agent** - Grant team access 8. **remove_user_from_agent** - Revoke access 9. **get_usage_report** - Monitor costs and usage 10. **get_pricing** - View current pricing ## ๐ŸŽจ Features ### Beautiful CLI Interface - **Interactive prompts** with validation - **Colorful output** with status indicators - **Table formatting** for agent lists - **Progress spinners** during operations - **Error handling** with helpful messages ### Real-Time Chat ``` You: How do I reset my password? ๐Ÿค– Agent is thinking... Customer Support Bot: I can help you reset your password! Here are the steps: 1. Go to the login page 2. Click "Forgot Password" 3. Enter your email address... [Tokens: 156] ``` ### Team Management - Add users by email address - Automatic validation and error handling - Sync with web platform permissions ## ๐Ÿ” Security & Configuration ### Environment Setup ```bash # Required: Database connection to MoluAbi platform DATABASE_URL=postgresql://user:pass@host:5432/moluabi ``` ### MCP Server Connection The client automatically connects to the MoluAbi MCP server using: - **Command**: `npx tsx ../mcp-server/src/server.ts` - **Transport**: Standard I/O (stdio) - **Authentication**: Database-based user validation ## ๐Ÿ“ Project Structure ``` mcp-client/ โ”œโ”€โ”€ src/ โ”‚ โ”œโ”€โ”€ lib/ โ”‚ โ”‚ โ””โ”€โ”€ mcp-client.ts # Core MCP client logic โ”‚ โ”œโ”€โ”€ commands/ โ”‚ โ”‚ โ””โ”€โ”€ agent-commands.ts # CLI command implementations โ”‚ โ”œโ”€โ”€ cli.ts # Command-line interface โ”‚ โ””โ”€โ”€ index.ts # Demo/testing entry point โ”œโ”€โ”€ package.json # Dependencies and scripts โ”œโ”€โ”€ tsconfig.json # TypeScript configuration โ””โ”€โ”€ README.md # This file ``` ## ๐Ÿ”„ Standalone Usage This client is **completely independent** and can be: - **Moved anywhere** - Copy this entire directory to any location - **Used separately** - No need for the main MoluAbi web platform code - **Distributed** - Share with team members as a standalone tool - **Customized** - Modify for your specific workflow needs The only requirement is access to a running MoluAbi MCP server. ## ๐ŸŽฏ Use Cases ### For Developers - **Automate** agent creation in CI/CD pipelines - **Script** bulk operations and management - **Integrate** with existing terminal workflows - **Test** agents quickly without opening browser ### For Teams - **Onboard** new members via command line - **Manage** permissions programmatically - **Monitor** usage across all team agents - **Share** agents efficiently ### For Power Users - **Quick prototyping** of AI assistants - **Bulk operations** on multiple agents - **Terminal-native** workflow integration - **Offline-first** agent management ## ๐Ÿ’ก Tips & Tricks ### Interactive Mode Start with `npm run cli interactive` for a guided experience that walks you through all available operations. ### Quick Commands ```bash # Create and immediately chat with new agent npm run cli create && npm run cli chat # Check all tools available npm run cli tools # List agents in table format npm run cli list ``` ### Error Handling The client provides helpful error messages and automatically handles: - Connection failures to MCP server - Invalid user IDs or agent IDs - Permission errors - Network timeouts ## ๐Ÿ”— Integration This MCP client demonstrates the power of the **Model Context Protocol** for AI agent management. It can be: - **Extended** with additional MCP tools - **Integrated** into other applications - **Used as reference** for building custom MCP clients - **Deployed** as part of larger automation systems The MCP architecture ensures that this client stays in perfect sync with the main MoluAbi platform while providing a completely different user experience. --- **Built with โค๏ธ for the AI agent ecosystem** *Experience the power of programmatic AI agent management*

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/oregpt/moluabi-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server