Official Python SDK for China Mobile Cloud AgentLink MCP Gateway
Project description
AgentLink SDK
Official Python SDK for China Mobile Cloud AgentLink MCP Gateway
AgentLink Python SDK provides a high-level, Pythonic API for interacting with the AgentLink MCP (Model Context Protocol) Gateway. It supports cloud sandbox lifecycle management, browser automation, Windows desktop control, and generic MCP tool invocation.
Features
- 🌐 Browser Automation — Navigate, click, type, take screenshots, evaluate JavaScript
- 🖥️ Windows Desktop Control — PowerShell commands, click, type, keyboard shortcuts, screenshots
- 🔄 Automatic Sandbox Management — Auto-creates and reuses sandbox sessions
- 🧵 Thread-Safe — Safe for use in multi-threaded applications
- 🔁 Retry Logic — Automatic retries with configurable timeout
- 📦 Context Manager — Auto-cleanup with
withstatement - 🐍 Pythonic API — Clean, intuitive interface with type hints
Installation
pip install agentlink-sdk
Or install from source:
git clone <repo-url>
cd agentlink-python-sdk
pip install -e .
Quick Start
Prerequisites
- Python 3.8 or later
- An AgentLink API key (obtain from your AgentLink platform administrator)
Basic Usage
from agentlink_sdk import AgentLink
# Initialize client
al = AgentLink(api_key="your-api-key")
# Browser automation (sandbox is auto-created and reused)
al.browser.go("https://www.baidu.com")
snapshot = al.browser.a11y_tree()
screenshot = al.browser.capture()
screenshot.save("page.png")
# Clean up
al.cleanup()
Development
# Install for development
cd agentlink-python-sdk
pip install -e ".[dev]"
# Run tests
pytest
## License
This project is licensed under the Apache License 2.0 — see the [LICENSE](LICENSE) file for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file agentlink_sdk-1.0.1.tar.gz.
File metadata
- Download URL: agentlink_sdk-1.0.1.tar.gz
- Upload date:
- Size: 47.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8f11a41d745eee7faf02d2554acb5840a5f5bfd5c8a0fb0c0fc36bb978957ce1
|
|
| MD5 |
4b6e98592f318be5e5441e36bad52b0c
|
|
| BLAKE2b-256 |
ae745dfb91abdcea7f76d2fdbf36e195668ad1e05ccf8d0c6e2ac47473e33ed0
|
File details
Details for the file agentlink_sdk-1.0.1-py3-none-any.whl.
File metadata
- Download URL: agentlink_sdk-1.0.1-py3-none-any.whl
- Upload date:
- Size: 32.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4c6f29b3b64f2970ea0ace4b7e931fbe66a38943102c43977583e3e1f4e65e37
|
|
| MD5 |
edd895e648e9fde87372080219b3587f
|
|
| BLAKE2b-256 |
96974c0af9761dd48b0bc47fb6dfbb7bddf3a7961400e3b1201f893aae683123
|