Skip to content

Commit 414673d

Browse files
committed
advanced SDK docs, reference docs
1 parent 305dbda commit 414673d

File tree

17 files changed

+1660
-5510
lines changed

17 files changed

+1660
-5510
lines changed

docs/docs.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,6 @@
125125
{
126126
"group": "Test and Evaluate",
127127
"pages": [
128-
"test-evaluate/overview",
129128
"test-evaluate/mcp-eval",
130129
"test-evaluate/agent-evaluation",
131130
"test-evaluate/server-evaluation"
@@ -134,6 +133,7 @@
134133
{
135134
"group": "Reference",
136135
"pages": [
136+
"reference/configuration",
137137
"reference/cli",
138138
"reference/decorators"
139139
]
Lines changed: 66 additions & 143 deletions
Original file line numberDiff line numberDiff line change
@@ -1,154 +1,116 @@
11
---
22
title: Deploy to Cloud
33
sidebarTitle: "Deploy to Cloud"
4-
description: "Deploy your agent to mcp-agent cloud in minutes"
4+
description: "Publish your agent to mcp-agent Cloud with the CLI."
55
icon: cloud
66
---
77

88
<Info>
9-
mcp-agent cloud is currently in open beta. For feedback, issues and feature requests, visit our [github issues](https://github.com/lastmile-ai/mcp-agent/issues) or join [our Discord](https://lmai.link/discord/mcp-agent).
9+
mcp-agent Cloud is in open beta. Share feedback via [GitHub issues](https://github.com/lastmile-ai/mcp-agent/issues) or [Discord](https://lmai.link/discord/mcp-agent).
1010
</Info>
1111

12-
## Quick Deploy
12+
## TL;DR – three commands
1313

14-
Deploy your agent to the cloud with a single command:
14+
```bash
15+
uvx mcp-agent login
16+
uvx mcp-agent deploy my-agent
17+
uvx mcp-agent cloud servers list
18+
uvx mcp-agent cloud servers describe my-agent
19+
```
1520

16-
<Steps>
17-
<Step title="Install mcp-agent CLI">
18-
```bash
19-
# Using uv (recommended)
20-
uv tool install mcp-agent
21+
1. `login` stores your API token locally.
22+
2. `deploy` packages the current directory and uploads it.
23+
3. `cloud servers list` shows every deployment you have access to.
24+
4. `cloud servers describe` confirms the deployment URL and secret policy.
2125

22-
# Or using pip
23-
pip install mcp-agent
24-
```
25-
</Step>
26+
## 1. Authenticate
2627

27-
<Step title="Log in to mcp-agent cloud">
28-
```bash
29-
mcp-agent login
30-
```
28+
```bash
29+
uvx mcp-agent login
30+
```
3131

32-
This will direct you to the API keys page for obtaining credentials.
33-
</Step>
32+
The CLI opens the Cloud dashboard so you can generate an API token. Credentials are stored under `~/.mcp-agent/`.
3433

35-
<Step title="Deploy your agent">
36-
```bash
37-
mcp-agent deploy my-agent
38-
```
34+
## 2. Deploy
3935

40-
Your agent will be deployed and accessible as an MCP server at:
41-
```
42-
https://deployments.mcp-agent.com/servers/my-agent
43-
```
44-
</Step>
45-
</Steps>
36+
From the directory containing your `mcp_agent.config.yaml` (or pass `--config-dir`):
4637

47-
## What Gets Deployed?
38+
```bash
39+
uvx mcp-agent deploy my-agent
40+
```
4841

49-
When you deploy an agent, mcp-agent cloud:
42+
During deployment you'll classify secrets as **deployment** (stored securely) or **user** (provided later via `mcp-agent cloud configure`). Use `--dry-run` to validate without uploading or `--non-interactive` for CI.
5043

51-
<CardGroup cols={2}>
52-
<Card title="Hosts Your Agent" icon="server">
53-
Your agent runs on managed infrastructure with automatic scaling
54-
</Card>
55-
<Card title="Exposes MCP Server" icon="plug">
56-
Your agent becomes an MCP server that any client can connect to
57-
</Card>
58-
<Card title="Manages Secrets" icon="key">
59-
API keys and secrets are securely stored and injected
60-
</Card>
61-
<Card title="Runs Workflows" icon="diagram-project">
62-
Long-running workflows are powered by Temporal for durability
63-
</Card>
64-
</CardGroup>
44+
<CodeGroup>
45+
```bash basic
46+
directory/
47+
├── main.py
48+
├── mcp_agent.config.yaml
49+
└── mcp_agent.secrets.yaml
50+
```
51+
```bash deploy
52+
uvx mcp-agent deploy my-agent --dry-run
53+
```
54+
</CodeGroup>
6555

66-
## Using Your Deployed Agent
56+
After a successful deploy you'll receive an endpoint like:
6757

68-
Once deployed, your agent can be used by any MCP client:
58+
```
59+
https://deployments.mcp-agent.com/servers/my-agent
60+
```
61+
62+
## 3. Connect from clients
63+
64+
Your cloud deployment is a standard MCP server. Use any MCP client:
6965

7066
<Tabs>
7167
<Tab title="Claude Desktop">
72-
Configure the agent first:
7368
```bash
74-
mcp-agent cloud configure --id https://deployments.mcp-agent.com/servers/my-agent
69+
uvx mcp-agent cloud configure --id https://deployments.mcp-agent.com/servers/my-agent
7570
```
7671

77-
Then add to `~/.claude-desktop/config.json`:
78-
```json
79-
{
80-
"servers": {
81-
"my-agent": {
82-
"command": "npx",
83-
"args": [
84-
"-y",
85-
"mcp-remote",
86-
"https://deployments.mcp-agent.com/servers/my-agent/sse",
87-
"--header",
88-
"Authorization: Bearer YOUR_API_KEY"
89-
]
90-
}
91-
}
92-
}
93-
```
72+
This command writes a ready-to-paste entry for `~/.claude-desktop/config.json` including the SSE URL and headers.
9473
</Tab>
9574

96-
<Tab title="Python Client">
75+
<Tab title="Python">
9776
```python
9877
from mcp_agent.mcp.gen_client import gen_client
9978

10079
async def use_agent():
10180
async with gen_client(
10281
"https://deployments.mcp-agent.com/servers/my-agent"
10382
) as client:
104-
result = await client.call_tool(
105-
"my_tool",
106-
arguments={"param": "value"}
107-
)
83+
result = await client.call_tool("my_tool", {"param": "value"})
10884
print(result)
10985
```
11086
</Tab>
11187
</Tabs>
11288

113-
## Monitor Your Deployment
89+
## Monitor & manage
11490

11591
<Tabs>
116-
<Tab title="View Logs">
92+
<Tab title="Logs">
11793
```bash
118-
# Tail logs in real-time
119-
mcp-agent cloud logger tail my-agent --follow
120-
121-
# Filter for errors
122-
mcp-agent cloud logger tail my-agent --grep "ERROR" --since 5m
94+
uvx mcp-agent cloud logger tail my-agent --follow
95+
uvx mcp-agent cloud logger tail my-agent --grep "ERROR" --since 5m
12396
```
12497
</Tab>
125-
126-
<Tab title="List Servers">
98+
<Tab title="Servers">
12799
```bash
128-
# List all deployed servers
129-
mcp-agent cloud servers list
130-
131-
# Get details for a specific server
132-
mcp-agent cloud servers describe my-agent
100+
uvx mcp-agent cloud servers list
101+
uvx mcp-agent cloud servers describe my-agent
133102
```
134103
</Tab>
135-
136-
<Tab title="Manage Workflows">
104+
<Tab title="Workflows">
137105
```bash
138-
# List workflow runs
139-
mcp-agent cloud servers workflows my-agent
140-
141-
# Get workflow status
142-
mcp-agent cloud workflows describe my-agent run_123
106+
uvx mcp-agent cloud workflows list
107+
uvx mcp-agent cloud workflows describe my-agent run_123
143108
```
144109
</Tab>
145110
</Tabs>
146111

147-
## Example: Deploy a Web Summarizer
148-
149-
Here's a complete example of creating and deploying an agent:
112+
## Example: web summarizer workflow
150113

151-
<CodeGroup>
152114
```python main.py
153115
import asyncio
154116
from mcp_agent.app import MCPApp
@@ -160,14 +122,12 @@ app = MCPApp(name="web_summarizer")
160122

161123
@app.workflow
162124
class WebSummarizerWorkflow(Workflow[str]):
163-
"""Fetches and summarizes web content."""
164-
165125
@app.workflow_run
166126
async def run(self, url: str) -> WorkflowResult[str]:
167127
agent = Agent(
168128
name="summarizer",
169129
instruction="Fetch and summarize web content concisely.",
170-
server_names=["fetch"]
130+
server_names=["fetch"],
171131
)
172132

173133
async with agent:
@@ -199,51 +159,14 @@ openai:
199159
default_model: gpt-4o
200160
```
201161
202-
```yaml mcp_agent.secrets.yaml
203-
openai:
204-
api_key: "sk-..."
205-
```
206-
</CodeGroup>
207-
208-
Deploy it:
162+
Deploy with:
209163
210164
```bash
211-
mcp-agent deploy web-summarizer
165+
uvx mcp-agent deploy web-summarizer
212166
```
213167

214-
<Check>
215-
Your agent is now live and can be accessed by any MCP client!
216-
</Check>
217-
218-
## Next Steps
219-
220-
<CardGroup cols={2}>
221-
<Card
222-
title="Deployment Guide"
223-
icon="book"
224-
href="/deployment/deployment-quickstart"
225-
>
226-
Complete deployment documentation
227-
</Card>
228-
<Card
229-
title="mcp-agent Cloud"
230-
icon="cloud"
231-
href="/deployment/mcp-agent-cloud/overview"
232-
>
233-
Learn about the cloud architecture
234-
</Card>
235-
<Card
236-
title="Durable Agents"
237-
icon="clock"
238-
href="/mcp-agent-sdk/advanced/durable-agents"
239-
>
240-
Build long-running workflows
241-
</Card>
242-
<Card
243-
title="CLI Reference"
244-
icon="terminal"
245-
href="/reference/cli"
246-
>
247-
Complete command reference
248-
</Card>
249-
</CardGroup>
168+
## Learn more
169+
170+
- [CLI reference](/reference/cli) – all commands and flags.
171+
- [Secrets configuration](/mcp-agent-sdk/core-components/configuring-your-application#secrets) – how secrets are merged for Cloud.
172+
- [Cloud agent server guide](/cloud/agent-server) – architecture, auth, and best practices.

0 commit comments

Comments
 (0)