- Explore MCP Servers
- mcp-appium
Mcp Appium
What is Mcp Appium
mcp-appium is an MCP (Model Context Protocol) server that integrates with Appium for mobile app testing and automation, allowing control and interaction with mobile applications on Android and iOS devices.
Use cases
Use cases for mcp-appium include automated functional testing of mobile applications, UI testing, performance testing, and regression testing across different devices and platforms.
How to use
To use mcp-appium, clone the repository, install the dependencies using ‘pip install -e .’, and ensure you have the necessary prerequisites such as Python 3.8+, Appium server, and mobile development tools. You can then start the Appium server and create driver sessions for testing.
Key features
Key features of mcp-appium include starting and managing the Appium server, creating and controlling Appium driver sessions, interacting with UI elements, performing gestures (tap, swipe, scroll, pinch, zoom), navigating through apps, taking screenshots, retrieving device information, switching between native and webview contexts, and executing comprehensive mobile app testing.
Where to use
mcp-appium is used in mobile application development and testing environments, particularly for teams that require automated testing solutions for Android and iOS applications.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Overview
What is Mcp Appium
mcp-appium is an MCP (Model Context Protocol) server that integrates with Appium for mobile app testing and automation, allowing control and interaction with mobile applications on Android and iOS devices.
Use cases
Use cases for mcp-appium include automated functional testing of mobile applications, UI testing, performance testing, and regression testing across different devices and platforms.
How to use
To use mcp-appium, clone the repository, install the dependencies using ‘pip install -e .’, and ensure you have the necessary prerequisites such as Python 3.8+, Appium server, and mobile development tools. You can then start the Appium server and create driver sessions for testing.
Key features
Key features of mcp-appium include starting and managing the Appium server, creating and controlling Appium driver sessions, interacting with UI elements, performing gestures (tap, swipe, scroll, pinch, zoom), navigating through apps, taking screenshots, retrieving device information, switching between native and webview contexts, and executing comprehensive mobile app testing.
Where to use
mcp-appium is used in mobile application development and testing environments, particularly for teams that require automated testing solutions for Android and iOS applications.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Content
Appium MCP (Model Context Protocol) Server
Documentation
When using the Appium MCP, please refer to the following documentation for comprehensive guidelines and best practices:
These documents provide essential information about using the Appium tools effectively and understanding their capabilities.
Overview
This MCP server provides integration with Appium for mobile app testing and automation. It allows you to control and interact with mobile applications on Android and iOS devices through the Model Context Protocol.
Features
- Start and manage Appium server
- Create and control Appium driver sessions for Android and iOS
- Find and interact with UI elements
- Perform gestures like tap, swipe, scroll, pinch, and zoom
- Navigate through the app
- Take screenshots
- Get device information
- Switch between native and webview contexts
- Execute comprehensive mobile app testing
Prerequisites
- Python 3.8 or higher
- Appium server installed (
npm install -g appium) - Android SDK or iOS development tools depending on your testing needs
- Mobile device or emulator/simulator
Installation
- Clone this repository
- Install dependencies:
pip install -e .
Testing
This project includes a comprehensive test suite to ensure the functionality of the Appium MCP server. The tests are located in the tests directory.
To run the tests:
-
Install the package with development dependencies:
pip install -e ".[dev]" -
Run the tests using the provided script:
./run_tests.shThe script supports several options:
--cov: Generate a coverage report--help: Show help message
You can also run specific test files or tests:
./run_tests.sh tests/test_main.py ./run_tests.sh tests/test_main.py::TestAppiumMCP::test_find_element_success -
Alternatively, you can run the tests directly with pytest:
pytest pytest --cov=main # With coverage report
For more information about the tests, see the tests/README.md file.
Usage
The Appium MCP server exposes a set of tools that can be used to interact with mobile applications. Here’s a typical workflow:
- Start the Appium server
- Create an Appium driver for Android or iOS
- Find and interact with elements
- Perform actions like tapping, swiping, or entering text
- Close the driver when done
Available Tools
Server Management
start_appium_server: Start the Appium server on the host machine
Driver Creation
create_android_driver: Create an Appium driver instance for Androidcreate_ios_driver: Create an Appium driver instance for iOS
Element Finding
find_element: Find the first element that matches the given criteriafind_elements: Find all elements that match the given criteriawait_for_element: Wait for an element to be presentwait_for_element_to_be_clickable: Wait for an element to be clickable
Element Interaction
tap_element: Tap on an elementlong_press_element: Long press on an elementget_text: Get text from an elementset_text: Set text on an elementget_attribute: Get an attribute from an element
Navigation and App Control
go_back: Press the back buttongo_home: Press the home buttonlaunch_app: Launch the app under testclose_app: Close the app under testreset_app: Reset the app under testget_page_source: Get the XML representation of the current page
Gesture Tools
swipe: Perform a swipe gesturescroll_to_element: Scroll until an element is foundpinch: Perform a pinch gesture on an element or the screenzoom: Perform a zoom gesture on an element or the screen
Utility Tools
take_screenshot: Take a screenshot of the device screenget_device_time: Get the device timeget_device_orientation: Get the device orientationset_device_orientation: Set the device orientationget_current_context: Get the current context (NATIVE_APP or WEBVIEW)get_contexts: Get all available contextsswitch_to_context: Switch to a different contextstop_appium_driver: Stop the Appium driver and clean up resourcesset_test_name: Set the name of the current test for reporting purposes
Quick Links
Dev Tools Supporting MCP
The following are the main code editors that support the Model Context Protocol. Click the link to visit the official website for more information.










