ACI Model Context Protocol (MCP) Servers

repository·main·Indexed 42 days ago

https://github.com/aipotheosis-labs/aci-mcp

MCP servers that bridge AI clients to tools and functions managed by ACI.dev. Version 1.0.0b13 provides three server modes: aci-mcp-apps for specific user-defined apps, aci-mcp-unified for broad discovery and execution of all ACI.dev platform functions via ACI_SEARCH_FUNCTIONS and ACI_EXECUTE_FUNCTION, and a vibeops-server for project state management and VibeOps controller functions.

Tokens
2.9K
Snippets
12
Records
15
Agent score
53%

What's inside ACI MCP

  1. Overview of ACI MCP Servers

    main

    This package provides Model Context Protocol (MCP) servers that allow AI clients to access functions (tools) managed by ACI.dev. There are two primary server modes available:

    1. aci-mcp-apps (apps-server): Provides direct access to functions (tools) from specific, user-defined apps.
    2. aci-mcp-unified (unified-server): Provides meta-functions (ACI_SEARCH_FUNCTIONS and ACI_EXECUTE_FUNCTION) to discover and execute all functions available on the ACI.dev platform.
  2. Run ACI MCP Servers using Docker

    main

    You can run the MCP servers in isolated Docker containers. Both server modes require the ACI_API_KEY environment variable and a --linked-account-owner-id flag.

    Unified Server

    Run the unified server to access all available ACI functions.

    Apps Server

    Run the apps server by specifying a comma-separated list of apps using the --apps flag.

    Note: Ensure you replace <ACI_API_KEY> and <LINKED_ACCOUNT_OWNER_ID> with your actual credentials.

    # Build the image
    docker build -t aci-mcp .
    
    # Run the unified server
    docker run --rm -i -e ACI_API_KEY=<ACI_API_KEY> aci-mcp unified-server --linked-account-owner-id <LINKED_ACCOUNT_OWNER_ID>
    
    # Run the apps server
    docker run --rm -i -e ACI_API_KEY=<ACI_API_KEY> aci-mcp apps-server --apps <APP1,APP2,...> --linked-account-owner-id <LINKED_ACCOUNT_OWNER_ID>
  3. Run ACI MCP Servers locally with uvx

    main

    The package is published to PyPI and can be executed directly using uvx. Use the aci-mcp command with the appropriate subcommand to start the desired server.

    Commands

    • apps-server: Starts the apps-specific MCP server.
    • unified-server: Starts the unified MCP server with unlimited tool access.
    # Install uv if you don't have it already
    curl -sSf https://install.pypa.io/get-pip.py | python3 -
    pip install uv
    
    # Run help to see available commands
    uvx aci-mcp --help
  4. Override the linked account owner ID in tool calls

    main

    The aci-mcp-apps server uses a default linked_account_owner_id (set via the server's startup flags). However, to support multi-user use cases within the limitations of the MCP protocol, you can override this default for a specific tool call.

    When calling a tool, include the aci_override_linked_account_owner_id parameter in your arguments object. The server will use this value for the execution and then strip it from the arguments before passing them to the underlying ACI function.

    {
      "name": "name_of_the_tool",
      "arguments": {
        "aci_override_linked_account_owner_id": "user_specific_id",
        "actual_tool_arg": "value"
      }
    }
  5. Execute VibeOps functions via MCP tools

    main

    The VibeOps MCP server dynamically loads and exposes functions from the VibeOps controller as MCP tools.

    When a tool name matches a function available on the VibeOps backend, the server executes that function by sending a POST request to /v1/functions/{name}/execute.

    Note on Search Parameters: Due to compatibility issues with certain MCP clients (like Cursor's auto mode), the limit and offset parameters have been removed from the search function's input schema.

  6. Debug ACI MCP Servers with MCP Inspector

    main

    To debug the server behavior, use the @modelcontextprotocol/inspector via npx. This allows you to test the tool definitions and execution in a controlled environment.

    Debugging the Unified Server

    npx @modelcontextprotocol/inspector uvx aci-mcp unified-server --linked-account-owner-id <LINKED_ACCOUNT_OWNER_ID>

    Debugging the Apps Server

    Specify the apps you wish to test using the --apps flag (e.g., "BRAVE_SEARCH,GMAIL").

    npx @modelcontextprotocol/inspector uvx aci-mcp apps-server --apps "BRAVE_SEARCH,GMAIL" --linked-account-owner-id <LINKED_ACCOUNT_OWNER_ID>

    Viewing Logs

    If using Claude Desktop, you can view server logs by running: tail -n 20 -f ~/Library/Logs/Claude/mcp*.log

    # For unified server
    npx @modelcontextprotocol/inspector uvx aci-mcp unified-server --linked-account-owner-id <LINKED_ACCOUNT_OWNER_ID>
    
    # For apps server
    npx @modelcontextprotocol/inspector uvx aci-mcp apps-server --apps "BRAVE_SEARCH,GMAIL" --linked-account-owner-id <LINKED_ACCOUNT_OWNER_ID>
  7. Configure VibeOps MCP Server environment variables

    main

    To run the VibeOps MCP server, you must provide the following environment variables:

    • VIBEOPS_API_KEY: Your API key for the VibeOps controller. This is required and must be set.
    • VIBEOPS_BASE_URL: The base URL for the VibeOps controller. Defaults to https://controller.aci.dev.

    If VIBEOPS_API_KEY is not provided, the server will raise a ValueError and fail to start.

    export VIBEOPS_API_KEY="your_api_key_here"
    export VIBEOPS_BASE_URL="https://controller.aci.dev"
  8. Configure the Unified MCP Server environment variables

    main

    The aci-mcp-unified server requires specific environment variables to connect to the ACI backend and perform documentation searches.

    • ACI_API_KEY: Required. Your ACI API key. The server will fail to start if this is not set.
    • ACI_SERVER_URL: The base URL for the ACI API. Defaults to https://api.aci.dev/v1.
    export ACI_API_KEY="your_api_key_here"
    export ACI_SERVER_URL="https://api.aci.dev/v1"
  9. Override linked account owner ID in ACI Execute Function

    main

    When executing an ACI function, the server uses a default linked_account_owner_id (provided at server startup). However, you can pass aci_override_linked_account_owner_id in the tool arguments to execute the function on behalf of a different user.

    {
      "name": "[ACI_EXECUTE_FUNCTION_NAME]",
      "arguments": {
        "function_name": "my_function",
        "function_arguments": { ... },
        "aci_override_linked_account_owner_id": "user_123"
      }
    }
  10. Available tools in the Unified MCP Server

    main

    The Unified MCP Server exposes three primary tools to MCP clients (like Claude Desktop or Cursor):

    1. ACI Search Functions: Used to discover available ACI functions. Note that limit and offset parameters are handled internally (defaulting to limit: 15 and offset: 0) to improve compatibility with certain AI agents.
    2. ACI Execute Function: Used to execute a specific ACI function.
    3. ACI_SEARCH_DOCS: A specialized tool for searching ACI.dev documentation, SDKs (Python & TypeScript), and usage examples.

    Multi-user Account Overrides

    To support multi-user scenarios via the MCP protocol, you can override the default linked_account_owner_id when calling the ACI Execute Function tool by providing the aci_override_linked_account_owner_id argument.

  11. Use the GET_PROJECT_STATE tool

    main

    The GET_PROJECT_STATE tool is a specialized tool provided by the VibeOps MCP server.

    When to use it:

    • Always call this tool first to understand the current state of your project (GitLab, Vercel, and Supabase deployments).
    • Call it periodically to get the latest state.
    • Call it after executing any function that might alter the project state.

    What it returns: A detailed text prompt containing:

    • GitLab project details and a specific Git remote URL including a project access token for pushing code.
    • Vercel deployment status.
    • Supabase project configuration.
    • A set of expert best practices and coding conventions (TypeScript, Next.js, Tailwind, etc.) to guide the LLM's code generation.
    {
      "name": "GET_PROJECT_STATE",
      "description": "Get the current state of your project, including the GitLab, Vercel, and Supabase deployments...",
      "inputSchema": {
        "type": "object",
        "properties": {}
      }
    }