MCP Mobile Automation Server

MCP Mobile Automation Server

Enables AI assistants to execute mobile automation tests using Cucumber.js, including device management, test scenarios, and APK uploads.

Category
Visit Server

README

MCP Mobile Automation Server

License: ISC TypeScript Node.js MCP

A Model Context Protocol (MCP) server that provides mobile automation testing capabilities through integration with Cucumber.js framework. This server exposes mobile testing tools to AI assistants, enabling automated testing of mobile applications.

šŸš€ Features

  • Calculator App Testing - Execute comprehensive calculator functionality tests
  • Device Management - Get information about available devices and configurations
  • Test Execution - Run specific Cucumber scenarios with custom parameters
  • APK Management - Upload APK files to BrowserStack for testing
  • Multilingual Support - Demonstrate multilingual device parsing capabilities
  • Project Status - Get current project configuration and status

šŸ“‹ Available Tools

1. run_calculator_test

Execute calculator app tests using the Cucumber.js framework.

Parameters:

  • scenario (optional): Specific scenario to run (e.g., "Basic Calculator Addition")
  • device (optional): Device to test on (e.g., "iPhone 12")
  • os_version (optional): OS version (e.g., "14")

2. get_test_scenarios

Get a list of available test scenarios from feature files.

3. get_device_info

Get information about available devices and configurations.

4. execute_cucumber_scenario

Run a specific Cucumber scenario with custom parameters.

Parameters:

  • feature: Feature file name (e.g., "calculator.feature")
  • scenario_name (optional): Specific scenario name to run
  • device (optional): Device to test on
  • platform (optional): Platform to test on (iOS/Android)

5. upload_apk

Upload APK file to BrowserStack for testing.

Parameters:

  • apk_path: Path to APK file (relative to project root)

6. get_project_status

Get current status and configuration of the mobile automation project.

7. run_multilingual_demo

Execute multilingual device parsing demonstration.

Parameters:

  • language (optional): Language to demo (english/portuguese/spanish/all)

šŸ›  Installation

  1. Clone the repository:

    git clone <repository-url>
    cd mcp-cucumber-js-mobile-automation
    
  2. Install dependencies:

    npm install
    
  3. Build the project:

    npm run build
    

šŸ”§ Configuration

Prerequisites

  • Node.js 16 or higher
  • TypeScript
  • The parent Cucumber.js project: https://github.com/lucascortazz/cucumber-js-mobile-automation

Environment Variables

You can configure the MCP server using environment variables:

Variable Description Default
CUCUMBER_PROJECT_PATH Path to the parent cucumber-js-mobile-automation project ../cucumber-js-mobile-automation

Example:

# Set custom path to parent project
export CUCUMBER_PROJECT_PATH="/path/to/cucumber-js-mobile-automation"
npm start

Project Path Configuration

The MCP server automatically looks for the parent project in these locations:

  1. Environment variable: CUCUMBER_PROJECT_PATH
  2. Default relative path: ../cucumber-js-mobile-automation

If the parent project is not found, the server will display helpful error messages with setup instructions.

  • TypeScript
  • Access to the parent Cucumber.js mobile automation project at: /Users/lucascortazzo/code/cucumber-js-mobile-automation

VS Code Integration

The server includes a VS Code MCP configuration file at .vscode/mcp.json. This allows you to debug and test the MCP server directly in VS Code.

Claude Desktop Integration

To use this server with Claude Desktop, add the following to your Claude Desktop configuration:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%\\Claude\\claude_desktop_config.json

{
  "mcpServers": {
    "mobile-automation": {
      "command": "node",
      "args": ["/ABSOLUTE/PATH/TO/mcp-cucumber-js-mobile-automation/build/index.js"]
    }
  }
}

🚦 Usage

Running the Server

# Start the server
npm start

# Or run in development mode
npm run dev

Example Commands

Once connected to an MCP client (like Claude Desktop), you can use these commands:

  • "Run calculator tests on iPhone 12"
  • "Show me available test scenarios"
  • "Execute the Basic Calculator Addition scenario"
  • "Get device information"
  • "Upload the Calculator.apk file"
  • "Show project status"
  • "Run multilingual demo in Portuguese"

šŸ”— Integration & Setup

This MCP server integrates with the Cucumber.js mobile automation framework available at: https://github.com/lucascortazz/cucumber-js-mobile-automation

šŸ“‹ Complete Setup Guide

Follow these steps to set up both the parent project and this MCP server:

Step 1: Set Up the Parent Mobile Automation Project

  1. Clone the parent project:

    git clone https://github.com/lucascortazz/cucumber-js-mobile-automation.git
    cd cucumber-js-mobile-automation
    
  2. Install dependencies:

    npm install
    
  3. Configure environment variables:

    # Copy the example environment file
    cp .env.example .env
    
    # Edit .env with your BrowserStack credentials
    # BROWSERSTACK_USERNAME=your_username
    # BROWSERSTACK_ACCESS_KEY=your_access_key
    
  4. Test the setup:

    npm test
    

Step 2: Set Up the MCP Server

  1. Clone this MCP server project:

    git clone https://github.com/lucascortazz/mcp-cucumber-js-mobile-automation.git
    cd mcp-cucumber-js-mobile-automation
    
  2. Install dependencies:

    npm install
    
  3. Update the parent project path:

    Edit src/index.ts and update the CUCUMBER_PROJECT_PATH constant:

    // Update this path to match your parent project location
    const CUCUMBER_PROJECT_PATH = "/your/path/to/cucumber-js-mobile-automation";
    
  4. Build the MCP server:

    npm run build
    

Step 3: Configure Claude Desktop

  1. Install Claude Desktop from https://claude.ai/download

  2. Configure MCP integration:

    macOS: Edit ~/Library/Application Support/Claude/claude_desktop_config.json Windows: Edit %APPDATA%\Claude\claude_desktop_config.json

    {
      "mcpServers": {
        "mobile-automation": {
          "command": "node",
          "args": ["/absolute/path/to/mcp-cucumber-js-mobile-automation/build/index.js"]
        }
      }
    }
    
  3. Restart Claude Desktop completely

Step 4: Test the Integration

  1. Start Claude Desktop and look for the MCP tools indicator
  2. Try these commands:
    • "Show me available test scenarios"
    • "Run calculator tests on iPhone 12"
    • "Get device information"
    • "What's the current project status?"

šŸ”§ Project Structure Requirements

Your directory structure should look like this:

your-projects/
ā”œā”€ā”€ cucumber-js-mobile-automation/          # Parent project
│   ā”œā”€ā”€ features/
│   │   ā”œā”€ā”€ calculator.feature
│   │   └── openReminders.feature
│   ā”œā”€ā”€ app/
│   │   └── Calculator.apk
│   ā”œā”€ā”€ utils/
│   └── package.json
└── mcp-cucumber-js-mobile-automation/      # This MCP server
    ā”œā”€ā”€ src/
    │   └── index.ts
    ā”œā”€ā”€ build/
    └── package.json

šŸš€ Bridge Capabilities

The MCP server provides a bridge between MCP clients and the mobile automation testing capabilities, allowing AI assistants to:

  • Execute mobile tests from the parent project
  • Manage test scenarios dynamically
  • Handle device configurations
  • Process test results and provide insights
  • Upload APK files to BrowserStack
  • Run multilingual demos and parsing tests

šŸ“ Development

Project Structure

mcp-cucumber-js-mobile-automation/
ā”œā”€ā”€ src/
│   └── index.ts          # Main MCP server implementation
ā”œā”€ā”€ build/                # Compiled JavaScript output
ā”œā”€ā”€ .vscode/
│   └── mcp.json         # VS Code MCP configuration
ā”œā”€ā”€ .github/
│   └── copilot-instructions.md
ā”œā”€ā”€ package.json
ā”œā”€ā”€ tsconfig.json
└── README.md

Scripts

  • npm run build - Compile TypeScript to JavaScript
  • npm start - Start the MCP server
  • npm run dev - Build and start in development mode

Debugging

You can debug this MCP server using VS Code with the included MCP configuration. The server logs to stderr, so you can monitor its activity during development.

šŸ¤ Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Build and test the server
  5. Submit a pull request

šŸ“„ License

This project is licensed under the ISC License.


Built with ā¤ļø using the Model Context Protocol SDK and TypeScript.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured