Overview
Qoder Cloud Agents CN is a fully managed AI agent runtime platform. You do not need to build your own agent loop, manage a tool execution sandbox, or handle long-lived connections. Simply define an agent and start a session through the API to run complex tasks and receive real-time results in the cloud.
Key concepts
|
Concept |
Description |
Analogy |
|
agent |
A reusable configuration template that defines the model, system prompt, and toolset. |
An employee's job description |
|
environment |
The container environment where a session runs, including network and dependency configurations. |
A desk and a toolbox |
|
session |
A specific instance of a conversation or task execution. |
A specific work session |
|
event |
A real-time stream of events generated within a session. |
A real-time broadcast of work progress |
Workflow
-
Define an agent — Specify the model, system prompt, and available tools.
-
Configure an environment — Select the container type, network policy, and pre-installed dependencies. New accounts must first use
POST /environmentsto create an environment, as none is provided by default. -
Start a session — Bind an agent to an environment to create a runtime instance.
-
Send messages and receive events — Send a
user.messageto the session, and then receive a real-time stream of events—such as agent thoughts, messages, and status changes—through Server-Sent Events (SSE) or polling.
Verify connectivity
# Verify PAT and list agents
curl -s https://api.qoder.com.cn/api/v1/cloud/agents \
-H "Authorization: Bearer $QODER_PAT"
A successful response looks like this:
{
"data": [ ],
"first_id": null,
"last_id": null,
"has_more": false
}
Use cases
-
Long-running asynchronous tasks — Code reviews, large-scale refactoring, and automated test generation.
-
API integration — Embed agent capabilities into your backend services without maintaining a runtime.
-
Batch processing — Start multiple sessions in parallel to process batch requests.
-
Scheduled tasks — Integrate with a scheduling system to periodically run agents for inspections or reporting.
Authentication
All API requests must include the following header:
|
Header |
Value |
Description |
|
|
|
Personal access token |
You can create a personal access token (PAT) in the Qoder console by navigating to Settings > Personal Access Tokens. Store your PAT securely and do not commit it to a code repository.
Pagination
List APIs use cursor-based pagination. The response structure is as follows:
{
"data": [...],
"first_id": "agent_019e451902fe7a2ca42c2dfc62d9320e",
"last_id": "agent_019e45369b3379e18bfaf59b3aad2fc9",
"has_more": true
}
Use the after_id and before_id query parameters to paginate.
FAQ
Q: Can I use Qoder Cloud Agents CN and the Qoder CLI at the same time?
A: Yes. The Qoder CLI is ideal for local, interactive development, while Qoder Cloud Agents CN is designed for automation and integration. The two are complementary.
Q: How many sessions can a single agent run concurrently?
A: There is no hard limit. An agent configuration can be associated with multiple active sessions simultaneously.
Q: How is data security ensured?
A: Each session runs in an isolated container sandbox, preventing access between sessions. All data is cleared when the environment is destroyed.
Next steps
-
Quickstart: Run your first cloud agent in five steps.
-
Define an agent: Learn more about agent configuration.
-
Cloud environments: Configure a runtime environment.
-
Start a session: Manage the session lifecycle.