The Cloud Sandbox Built for AI Agents
Browser Β·
Desktop Β·
Mobile Β·
Code
Deploy OpenClaw on an AgentBay cloud desktop in minutes with a turnkey web management UI.
| Implementation | Stack | Get Started |
|---|---|---|
| Python | FastAPI + React | pip install -r requirements.txt && python main.py |
| Java | Spring Boot + React | mvn clean compile && mvn spring-boot:run |
Both include Context persistence, external HTTPS access via getLink, and custom model configuration. Visit http://localhost:8080 after launch.
| Language | Install Command | Documentation |
|---|---|---|
| Python | pip install wuying-agentbay-sdk |
Python Docs |
| TypeScript | npm install wuying-agentbay-sdk |
TypeScript Docs |
| Golang | go get github.com/aliyun/wuying-agentbay-sdk/golang/pkg/agentbay |
Golang Docs |
| Java | Maven/Gradle (see docs) | Java Docs |
Before using the SDK, you need to:
- Register an Alibaba Cloud account: https://aliyun.com
- Get APIKEY credentials: AgentBay Console
- Set environment variable:
- For Linux/MacOS:
export AGENTBAY_API_KEY=your_api_key_here - For Windows:
setx AGENTBAY_API_KEY your_api_key_here
- For Linux/MacOS:
from agentbay import AgentBay, CreateSessionParams
# Create session and execute code
agent_bay = AgentBay()
session = agent_bay.create(CreateSessionParams(image_id="code_latest")).session
result = session.code.run_code("print('Hello AgentBay')", "python")
if result.success:
print(result.result) # Hello AgentBay
# Clean up
agent_bay.delete(session)import { AgentBay } from 'wuying-agentbay-sdk';
// Create session and execute code
const agentBay = new AgentBay();
const session = (await agentBay.create({ imageId: "code_latest" })).session;
const result = await session.code.runCode("print('Hello AgentBay')", "python");
if (result.success) {
console.log(result.result); // Hello AgentBay
}
// Clean up
await agentBay.delete(session);import "github.com/aliyun/wuying-agentbay-sdk/golang/pkg/agentbay"
// Create session and execute code
client, _ := agentbay.NewAgentBay("", nil)
result, _ := client.Create(agentbay.NewCreateSessionParams().WithImageId("code_latest"))
session := result.Session
res, _ := session.Code.RunCode("print('Hello AgentBay')", "python")
fmt.Println(res.Output) // Hello AgentBay
// Clean up
client.Delete(session, false)import com.aliyun.agentbay.*;
// Create session and execute code
AgentBay agentBay = new AgentBay();
CreateSessionParams params = new CreateSessionParams().setImageId("code_latest");
Session session = agentBay.create(params).getSession();
CodeExecutionResult result = session.getCode().runCode("print('Hello AgentBay')", "python");
if (result.isSuccess()) {
System.out.println(result.getResult()); // Hello AgentBay
}
// Clean up
agentBay.delete(session, false);Complete Documentation - Full guides, tutorials, and API references
π New Users - If you're new to AgentBay or cloud development:
- Quick Start Tutorial - Get started in 5 minutes
- Core Concepts - Understand cloud environments and sessions
π Experienced Users - Already familiar with browser automation, computer use, mobile testing, or cloud development environments:
- Choose your environment:
- π Browser Automation - Web scraping, testing, form filling with stealth capabilities
- π₯οΈ Computer/Windows Automation - Desktop UI automation and window management
- π± Mobile Automation - Android UI testing and gesture automation
- π» CodeSpace - Cloud-based code execution environments
- Feature Guides - Complete feature introduction
- API Reference - Comprehensive API documentation with examples
- Python API Reference - Auto-generated from source code
- TypeScript API Reference - Auto-generated from source code
- Golang API Reference - Auto-generated from source code
- π All API docs include complete runnable examples and actual output
- Cookbook - Real-world examples and recipes
- Session Creation & Lifecycle - Create, manage, and delete cloud environments
- Environment Configuration - Configure SDK settings, regions, and endpoints
- Session Monitoring - Monitor session status and health validation
- Command Execution - Execute Shell commands in cloud environments
- File Operations - Upload, download, and manage cloud files
- Data Persistence - Save and retrieve data across sessions
- Context Management - Synchronize data and maintain state
- Computer Use - General automation and desktop operations
- Browser Use - Web automation, scraping, and browser control
- CodeSpace - Code execution and development environment
- Mobile Use - Mobile device simulation and control
If you're using AI coding assistants (Claude, Cursor, GitHub Copilot, etc.) to develop with AgentBay SDK, you can use llms.txt and llms-full.txt as context for better code suggestions:
- llms.txt - Concise overview with READMEs and config (~14k tokens, ~55 KB)
- llms-full.txt - Core SDK source, API docs, examples and guides (~211k tokens, ~827 KB)
These files are generated by python scripts/build_llms_txt.py using a tiered knowledge construction approach. They cover 96 carefully selected files across all languages (Python, TypeScript, Golang) with method signature indexing for truncated source files.
Welcome to visit our product website and join our community!
- π AgentBay International Website: https://www.alibabacloud.com/product/agentbay
- π¨π³ AgentBay China Website (Chinese): https://www.aliyun.com/product/agentbay
- π¬ Discord Community: Join on Discord
- πΌ DingTalk Group: Click to join
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.



