@mastra/mcp-docs-server 0.13.2-alpha.0 → 0.13.2-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.docs/organized/changelogs/%40mastra%2Fagui.md +12 -0
- package/.docs/organized/changelogs/%40mastra%2Fastra.md +25 -25
- package/.docs/organized/changelogs/%40mastra%2Fchroma.md +25 -25
- package/.docs/organized/changelogs/%40mastra%2Fclickhouse.md +26 -26
- package/.docs/organized/changelogs/%40mastra%2Fclient-js.md +32 -32
- package/.docs/organized/changelogs/%40mastra%2Fcloudflare-d1.md +25 -25
- package/.docs/organized/changelogs/%40mastra%2Fcloudflare.md +26 -26
- package/.docs/organized/changelogs/%40mastra%2Fcore.md +26 -26
- package/.docs/organized/changelogs/%40mastra%2Fcouchbase.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fdeployer-cloudflare.md +40 -40
- package/.docs/organized/changelogs/%40mastra%2Fdeployer-netlify.md +44 -44
- package/.docs/organized/changelogs/%40mastra%2Fdeployer-vercel.md +42 -42
- package/.docs/organized/changelogs/%40mastra%2Fdeployer.md +45 -45
- package/.docs/organized/changelogs/%40mastra%2Fdynamodb.md +27 -27
- package/.docs/organized/changelogs/%40mastra%2Fevals.md +13 -13
- package/.docs/organized/changelogs/%40mastra%2Ffirecrawl.md +16 -16
- package/.docs/organized/changelogs/%40mastra%2Fgithub.md +13 -13
- package/.docs/organized/changelogs/%40mastra%2Flance.md +25 -0
- package/.docs/organized/changelogs/%40mastra%2Flibsql.md +28 -28
- package/.docs/organized/changelogs/%40mastra%2Fmcp-docs-server.md +30 -30
- package/.docs/organized/changelogs/%40mastra%2Fmcp-registry-registry.md +16 -16
- package/.docs/organized/changelogs/%40mastra%2Fmcp.md +24 -24
- package/.docs/organized/changelogs/%40mastra%2Fmem0.md +13 -13
- package/.docs/organized/changelogs/%40mastra%2Fmemory.md +35 -35
- package/.docs/organized/changelogs/%40mastra%2Fmongodb.md +28 -28
- package/.docs/organized/changelogs/%40mastra%2Fopensearch.md +24 -0
- package/.docs/organized/changelogs/%40mastra%2Fpg.md +28 -28
- package/.docs/organized/changelogs/%40mastra%2Fpinecone.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fplayground-ui.md +38 -38
- package/.docs/organized/changelogs/%40mastra%2Fqdrant.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Frag.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fragie.md +13 -13
- package/.docs/organized/changelogs/%40mastra%2Fschema-compat.md +6 -0
- package/.docs/organized/changelogs/%40mastra%2Fserver.md +32 -32
- package/.docs/organized/changelogs/%40mastra%2Fturbopuffer.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fupstash.md +26 -26
- package/.docs/organized/changelogs/%40mastra%2Fvectorize.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fvoice-cloudflare.md +13 -13
- package/.docs/organized/changelogs/%40mastra%2Fvoice-deepgram.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fvoice-elevenlabs.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fvoice-gladia.md +12 -0
- package/.docs/organized/changelogs/%40mastra%2Fvoice-google.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fvoice-murf.md +13 -13
- package/.docs/organized/changelogs/%40mastra%2Fvoice-openai.md +14 -14
- package/.docs/organized/changelogs/%40mastra%2Fvoice-playai.md +13 -13
- package/.docs/organized/changelogs/%40mastra%2Fvoice-sarvam.md +13 -13
- package/.docs/organized/changelogs/%40mastra%2Fvoice-speechify.md +14 -14
- package/.docs/organized/changelogs/create-mastra.md +7 -7
- package/.docs/organized/changelogs/mastra.md +48 -48
- package/.docs/organized/code-examples/a2a.md +1 -1
- package/.docs/organized/code-examples/agent-network.md +125 -7
- package/.docs/organized/code-examples/agent.md +183 -6
- package/.docs/organized/code-examples/agui.md +4 -4
- package/.docs/organized/code-examples/ai-sdk-useChat.md +6 -6
- package/.docs/organized/code-examples/assistant-ui.md +6 -6
- package/.docs/organized/code-examples/bird-checker-with-express.md +1 -1
- package/.docs/organized/code-examples/bird-checker-with-nextjs-and-eval.md +6 -6
- package/.docs/organized/code-examples/bird-checker-with-nextjs.md +6 -6
- package/.docs/organized/code-examples/client-side-tools.md +6 -6
- package/.docs/organized/code-examples/crypto-chatbot.md +6 -6
- package/.docs/organized/code-examples/experimental-auth-weather-agent.md +1 -1
- package/.docs/organized/code-examples/fireworks-r1.md +1 -1
- package/.docs/organized/code-examples/mcp-configuration.md +2 -2
- package/.docs/organized/code-examples/mcp-registry-registry.md +1 -1
- package/.docs/organized/code-examples/memory-per-resource-example.md +236 -0
- package/.docs/organized/code-examples/memory-with-mem0.md +1 -1
- package/.docs/organized/code-examples/memory-with-processors.md +1 -1
- package/.docs/organized/code-examples/openapi-spec-writer.md +6 -6
- package/.docs/organized/code-examples/quick-start.md +1 -1
- package/.docs/organized/code-examples/stock-price-tool.md +1 -1
- package/.docs/organized/code-examples/weather-agent.md +1 -1
- package/.docs/organized/code-examples/workflow-ai-recruiter.md +1 -1
- package/.docs/organized/code-examples/workflow-with-inline-steps.md +1 -1
- package/.docs/organized/code-examples/workflow-with-memory.md +1 -1
- package/.docs/organized/code-examples/workflow-with-separate-steps.md +1 -1
- package/.docs/raw/agents/using-tools-and-mcp.mdx +3 -2
- package/.docs/raw/deployment/cloud-providers/digital-ocean.mdx +111 -0
- package/.docs/raw/deployment/cloud-providers/index.mdx +15 -0
- package/.docs/raw/frameworks/agentic-uis/copilotkit.mdx +53 -10
- package/.docs/raw/mastra-cloud/dashboard.mdx +100 -0
- package/.docs/raw/mastra-cloud/observability.mdx +24 -138
- package/.docs/raw/mastra-cloud/overview.mdx +50 -42
- package/.docs/raw/mastra-cloud/setting-up.mdx +51 -87
- package/.docs/raw/memory/overview.mdx +4 -0
- package/.docs/raw/memory/working-memory.mdx +144 -1
- package/.docs/raw/networks-vnext/complex-task-execution.mdx +137 -0
- package/.docs/raw/networks-vnext/overview.mdx +85 -0
- package/.docs/raw/networks-vnext/single-task-execution.mdx +131 -0
- package/.docs/raw/observability/nextjs-tracing.mdx +2 -2
- package/.docs/raw/reference/client-js/agents.mdx +41 -0
- package/.docs/raw/reference/deployer/netlify.mdx +22 -68
- package/.docs/raw/reference/deployer/vercel.mdx +7 -77
- package/.docs/raw/reference/storage/libsql.mdx +1 -0
- package/.docs/raw/reference/tools/mcp-client.mdx +244 -0
- package/.docs/raw/reference/tools/mcp-server.mdx +186 -0
- package/.docs/raw/reference/tools/vector-query-tool.mdx +1 -0
- package/.docs/raw/reference/workflows/create-run.mdx +1 -1
- package/.docs/raw/reference/workflows/resume.mdx +1 -1
- package/.docs/raw/reference/workflows/sleep.mdx +43 -0
- package/.docs/raw/reference/workflows/sleepUntil.mdx +43 -0
- package/.docs/raw/reference/workflows/start.mdx +1 -1
- package/.docs/raw/reference/workflows/stream.mdx +1 -1
- package/.docs/raw/reference/workflows/waitForEvent.mdx +49 -0
- package/.docs/raw/reference/workflows/watch.mdx +1 -1
- package/.docs/raw/reference/workflows/workflow.mdx +6 -2
- package/.docs/raw/storage/overview.mdx +50 -1
- package/.docs/raw/tools-mcp/mcp-overview.mdx +52 -0
- package/.docs/raw/workflows/control-flow.mdx +42 -1
- package/.docs/raw/workflows/inngest-workflow.mdx +1 -1
- package/.docs/raw/workflows/overview.mdx +73 -5
- package/.docs/raw/workflows/pausing-execution.mdx +60 -0
- package/.docs/raw/workflows/suspend-and-resume.mdx +68 -23
- package/.docs/raw/workflows/using-with-agents-and-tools.mdx +1 -1
- package/package.json +6 -6
- package/.docs/raw/mastra-cloud/deploying.mdx +0 -142
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Understanding the Mastra Cloud Dashboard
|
|
3
|
+
description: Details of each feature available in Mastra Cloud
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
import { MastraCloudCallout } from '@/components/mastra-cloud-callout'
|
|
7
|
+
|
|
8
|
+
# Navigating the Dashboard
|
|
9
|
+
|
|
10
|
+
This page explains how to navigate the Mastra Cloud dashboard, where you can configure your project, view deployment details, and interact with agents and workflows using the built-in [Playground](/docs/mastra-cloud/dashboard#playground).
|
|
11
|
+
|
|
12
|
+
<MastraCloudCallout />
|
|
13
|
+
|
|
14
|
+
## Overview
|
|
15
|
+
|
|
16
|
+
The **Overview** page provides details about your application, including its domain URL, status, latest deployment, and connected agents and workflows.
|
|
17
|
+
|
|
18
|
+

|
|
19
|
+
|
|
20
|
+
Key features:
|
|
21
|
+
|
|
22
|
+
Each project shows its current deployment status, active domains, and environment variables, so you can quickly understand how your application is running.
|
|
23
|
+
|
|
24
|
+
## Deployments
|
|
25
|
+
|
|
26
|
+
The **Deployments** page shows recent builds and gives you quick access to detailed build logs. Click any row to view more information about a specific deployment.
|
|
27
|
+
|
|
28
|
+

|
|
29
|
+
|
|
30
|
+
Key features:
|
|
31
|
+
|
|
32
|
+
Each deployment includes its current status, the Git branch it was deployed from, and a title generated from the commit hash.
|
|
33
|
+
|
|
34
|
+
## Logs
|
|
35
|
+
|
|
36
|
+
The **Logs** page is where you'll find detailed information to help debug and monitor your application's behavior in the production environment.
|
|
37
|
+
|
|
38
|
+

|
|
39
|
+
|
|
40
|
+
Key features:
|
|
41
|
+
|
|
42
|
+
Each log includes a severity level and detailed messages showing agent, workflow, and storage activity.
|
|
43
|
+
|
|
44
|
+
## Settings
|
|
45
|
+
|
|
46
|
+
On the **Settings** page you can modify the configuration of your application.
|
|
47
|
+
|
|
48
|
+

|
|
49
|
+
|
|
50
|
+
Key features:
|
|
51
|
+
|
|
52
|
+
You can manage environment variables, edit key project settings like the name and branch, configure storage with LibSQLStore, and set a stable URL for your endpoints.
|
|
53
|
+
|
|
54
|
+
> Changes to configuration require a new deployment before taking effect.
|
|
55
|
+
|
|
56
|
+
## Playground
|
|
57
|
+
|
|
58
|
+
### Agents
|
|
59
|
+
|
|
60
|
+
On the **Agents** page you'll see all agents used in your application. Click any agent to interact using the chat interface.
|
|
61
|
+
|
|
62
|
+

|
|
63
|
+
|
|
64
|
+
Key features:
|
|
65
|
+
|
|
66
|
+
Test your agents in real time using the chat interface, review traces of each interaction, and see evaluation scores for every response.
|
|
67
|
+
|
|
68
|
+
### Workflows
|
|
69
|
+
|
|
70
|
+
On the **Workflows** page you'll see all workflows used in your application. Click any workflow to interact using the runner interface.
|
|
71
|
+
|
|
72
|
+

|
|
73
|
+
|
|
74
|
+
Key features:
|
|
75
|
+
|
|
76
|
+
Visualize your workflow with a step-by-step graph, view execution traces, and run workflows directly using the built-in runner.
|
|
77
|
+
|
|
78
|
+
### Tools
|
|
79
|
+
|
|
80
|
+
On the **Tools** page you'll see all tools used by your agents. Click any tool to interact using the input interface.
|
|
81
|
+
|
|
82
|
+

|
|
83
|
+
|
|
84
|
+
Key features:
|
|
85
|
+
|
|
86
|
+
Test your tools by providing an input that matches the schema and viewing the structured output.
|
|
87
|
+
|
|
88
|
+
## MCP Servers
|
|
89
|
+
|
|
90
|
+
The **MCP Servers** page lists all MCP Servers included in your application. Click any MCP Server for more information.
|
|
91
|
+
|
|
92
|
+

|
|
93
|
+
|
|
94
|
+
Key features:
|
|
95
|
+
|
|
96
|
+
Each MCP Server includes API endpoints for HTTP and SSE, along with IDE configuration snippets for tools like Cursor and Windsurf.
|
|
97
|
+
|
|
98
|
+
## Next steps
|
|
99
|
+
|
|
100
|
+
- [Understanding Tracing and Logs](/docs/mastra-cloud/observability)
|
|
@@ -3,164 +3,50 @@ title: Observability in Mastra Cloud
|
|
|
3
3
|
description: Monitoring and debugging tools for Mastra Cloud deployments
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
import { MastraCloudCallout } from '@/components/mastra-cloud-callout'
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
> Mastra Cloud is currently in **beta**.
|
|
8
|
+
# Understanding Tracing and Logs
|
|
10
9
|
|
|
11
|
-
Mastra Cloud
|
|
10
|
+
Mastra Cloud captures execution data to help you monitor your application's behavior in the production environment.
|
|
12
11
|
|
|
13
|
-
|
|
12
|
+
<MastraCloudCallout />
|
|
14
13
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
1. **Chat**: Interactive messaging interface to test your agent
|
|
18
|
-
2. **Traces**: Detailed execution records
|
|
19
|
-
3. **Evaluation**: Agent performance assessment
|
|
20
|
-
|
|
21
|
-

|
|
22
|
-
|
|
23
|
-
### Chat Interface
|
|
24
|
-
|
|
25
|
-
The Chat tab provides:
|
|
26
|
-
|
|
27
|
-
- Interactive messaging with deployed agents
|
|
28
|
-
- System response to user queries
|
|
29
|
-
- Suggested prompt buttons (e.g., "What capabilities do you have?")
|
|
30
|
-
- Message input area
|
|
31
|
-
- Branch indicator (e.g., "main")
|
|
32
|
-
- Note about agent memory limitations
|
|
33
|
-
|
|
34
|
-
### Agent Configuration Panel
|
|
35
|
-
|
|
36
|
-
The right sidebar displays agent details:
|
|
37
|
-
|
|
38
|
-
- Agent name and deployment identifier
|
|
39
|
-
- Model information (e.g., "OpenAI")
|
|
40
|
-
- Tools available to the agent (e.g., "getWeather")
|
|
41
|
-
- Complete system prompt text
|
|
42
|
-
|
|
43
|
-
This panel provides visibility into how the agent is configured without needing to check the source code.
|
|
44
|
-
|
|
45
|
-
## Trace System
|
|
46
|
-
|
|
47
|
-
Mastra Cloud records traces for agent and workflow interactions.
|
|
48
|
-
|
|
49
|
-
### Trace Explorer Interface
|
|
50
|
-
|
|
51
|
-

|
|
52
|
-
|
|
53
|
-
The Trace Explorer interface shows:
|
|
54
|
-
|
|
55
|
-
- All agent and workflow interactions
|
|
56
|
-
- Specific trace details
|
|
57
|
-
- Input and output data
|
|
58
|
-
- Tool calls with parameters and results
|
|
59
|
-
- Workflow execution paths
|
|
60
|
-
- Filtering options by type, status, timestamp, and agent/workflow
|
|
61
|
-
|
|
62
|
-
### Trace Data Structure
|
|
63
|
-
|
|
64
|
-
Each trace contains:
|
|
65
|
-
|
|
66
|
-
1. **Request Data**: The request that initiated the agent or workflow
|
|
67
|
-
2. **Tool Call Records**: Tool calls during execution with parameters
|
|
68
|
-
3. **Tool Response Data**: The responses from tool calls
|
|
69
|
-
4. **Agent Response Data**: The generated agent response
|
|
70
|
-
5. **Execution Timestamps**: Timing information for each execution step
|
|
71
|
-
6. **Model Metadata**: Information about model usage and tokens
|
|
72
|
-
|
|
73
|
-
The trace view displays all API calls and results throughout execution. This data helps debug tool usage and agent logic flows.
|
|
74
|
-
|
|
75
|
-
### Agent Interaction Data
|
|
76
|
-
|
|
77
|
-
Agent interaction traces include:
|
|
78
|
-
|
|
79
|
-
- User input text
|
|
80
|
-
- Agent processing steps
|
|
81
|
-
- Tool calls (e.g., weather API calls)
|
|
82
|
-
- Parameters and results for each tool call
|
|
83
|
-
- Final agent response text
|
|
84
|
-
|
|
85
|
-
## Dashboard Structure
|
|
86
|
-
|
|
87
|
-
The Mastra Cloud dashboard contains:
|
|
88
|
-
|
|
89
|
-
- Project deployment history
|
|
90
|
-
- Environment variable configuration
|
|
91
|
-
- Agent configuration details (model, system prompt, tools)
|
|
92
|
-
- Workflow step visualization
|
|
93
|
-
- Deployment URLs
|
|
94
|
-
- Recent activity log
|
|
95
|
-
|
|
96
|
-
## Agent Testing
|
|
97
|
-
|
|
98
|
-
Test your agents using the Chat interface:
|
|
99
|
-
|
|
100
|
-
1. Navigate to the Agents section
|
|
101
|
-
2. Select the agent you want to test
|
|
102
|
-
3. Use the Chat tab to interact with your agent
|
|
103
|
-
4. Send messages and view responses
|
|
104
|
-
5. Use suggested prompts for common queries
|
|
105
|
-
6. Switch to the Traces tab to view execution details
|
|
106
|
-
|
|
107
|
-
Note that by default, agents do not remember conversation history across sessions. The interface indicates this with the message: "Agent will not remember previous messages. To enable memory for agent see image."
|
|
14
|
+
## Logs
|
|
108
15
|
|
|
109
|
-
|
|
16
|
+
You can view detailed logs for debugging and monitoring your application's behavior on the [Logs](/docs/mastra-cloud/dashboard#logs) page of the Dashboard.
|
|
110
17
|
|
|
111
|
-

|
|
112
19
|
|
|
113
|
-
|
|
20
|
+
Key features:
|
|
114
21
|
|
|
115
|
-
|
|
116
|
-
- Status for each workflow step
|
|
117
|
-
- Execution details for each step
|
|
118
|
-
- Execution trace records
|
|
119
|
-
- Multi-step process execution (e.g., weather lookup followed by activity planning)
|
|
22
|
+
Each log entry includes its severity level and a detailed message showing agent, workflow, or storage activity.
|
|
120
23
|
|
|
121
|
-
|
|
24
|
+
## Traces
|
|
122
25
|
|
|
123
|
-
|
|
26
|
+
More detailed traces are available for both agents and workflows by using a [logger](/docs/observability/logging) or enabling [telemetry](/docs/observability/tracing) using one of our [supported providers](/reference/observability/providers).
|
|
124
27
|
|
|
125
|
-
|
|
28
|
+
### Agents
|
|
126
29
|
|
|
127
|
-
|
|
30
|
+
With a [logger](/docs/observability/logging) enabled, you can view detailed outputs from your agents in the **Traces** section of the Agents Playground.
|
|
128
31
|
|
|
129
|
-

|
|
130
33
|
|
|
131
|
-
|
|
34
|
+
Key features:
|
|
132
35
|
|
|
133
|
-
|
|
134
|
-
- **Level**: Log level (info, debug)
|
|
135
|
-
- **Hostname**: Server identification
|
|
136
|
-
- **Message**: Detailed log information, including:
|
|
137
|
-
- API initialization
|
|
138
|
-
- Storage connections
|
|
139
|
-
- Agent and workflow activity
|
|
36
|
+
Tools passed to the agent during generation are standardized using `convertTools`. This includes retrieving client-side tools, memory tools, and tools exposed from workflows.
|
|
140
37
|
|
|
141
|
-
## Technical Features
|
|
142
38
|
|
|
143
|
-
|
|
39
|
+
### Workflows
|
|
144
40
|
|
|
145
|
-
|
|
146
|
-
- **Structured Trace Format**: JSON format for filtering and query operations
|
|
147
|
-
- **Historical Data Storage**: Retention of past execution records
|
|
148
|
-
- **Deployment Version Links**: Correlation between traces and deployment versions
|
|
41
|
+
With a [logger](/docs/observability/logging) enabled, you can view detailed outputs from your workflows in the **Traces** section of the Workflows Playground.
|
|
149
42
|
|
|
150
|
-
|
|
43
|
+

|
|
151
44
|
|
|
152
|
-
|
|
153
|
-
- Use the chat interface to test edge case inputs
|
|
154
|
-
- View system prompts to understand agent behavior
|
|
155
|
-
- Examine tool call parameters and results
|
|
156
|
-
- Verify workflow execution step sequencing
|
|
157
|
-
- Identify execution bottlenecks in trace timing data
|
|
158
|
-
- Compare trace differences between agent versions
|
|
45
|
+
Key features:
|
|
159
46
|
|
|
160
|
-
|
|
47
|
+
Workflows are created using `createWorkflow`, which sets up steps, metadata, and tools. You can run them with `runWorkflow` by passing input and options.
|
|
161
48
|
|
|
162
|
-
|
|
49
|
+
## Next steps
|
|
163
50
|
|
|
164
|
-
-
|
|
165
|
-
-
|
|
166
|
-
- Join the [Discord developer channel](https://discord.gg/mastra)
|
|
51
|
+
- [Logging](/docs/observability/logging)
|
|
52
|
+
- [Tracing](/docs/observability/tracing)
|
|
@@ -3,61 +3,69 @@ title: Mastra Cloud
|
|
|
3
3
|
description: Deployment and monitoring service for Mastra applications
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
+
import { MastraCloudCallout } from '@/components/mastra-cloud-callout'
|
|
7
|
+
import { FileTree } from "nextra/components";
|
|
8
|
+
|
|
6
9
|
# Mastra Cloud
|
|
7
10
|
|
|
8
|
-
Mastra Cloud is a
|
|
9
|
-
|
|
10
|
-
|
|
11
|
+
[Mastra Cloud](https://mastra.ai/cloud) is a platform for deploying, managing, monitoring, and debugging Mastra applications. When you [deploy](/docs/mastra-cloud/setting-up) your application, Mastra Cloud exposes your agents, tools, and workflows as REST API endpoints.
|
|
12
|
+
|
|
13
|
+
<MastraCloudCallout />
|
|
14
|
+
|
|
15
|
+
## Platform features
|
|
16
|
+
|
|
17
|
+
Deploy and manage your applications with automated builds, organized projects, and no additional configuration.
|
|
18
|
+
|
|
19
|
+

|
|
20
|
+
|
|
21
|
+
Key features:
|
|
22
|
+
|
|
23
|
+
Mastra Cloud supports zero-config deployment, continuous integration with GitHub, and atomic deployments that package agents, tools, and workflows together.
|
|
11
24
|
|
|
12
|
-
|
|
13
|
-
> Mastra Cloud is currently in **public beta**. Features, APIs, and UIs may
|
|
14
|
-
> change as development continues.
|
|
25
|
+
## Project Dashboard
|
|
15
26
|
|
|
16
|
-
|
|
27
|
+
Monitor and debug your applications with detailed output logs, deployment state, and interactive tools.
|
|
17
28
|
|
|
18
|
-
|
|
19
|
-
- **Project Organization** - Group agents and workflows into projects with assigned URLs
|
|
20
|
-
- **Environment Variables** - Store configuration securely by environment
|
|
21
|
-
- **Testing Console** - Send messages to agents through a web interface
|
|
22
|
-
- **Execution Tracing** - Record agent interactions and tool calls
|
|
23
|
-
- **Workflow Visualization** - Display workflow steps and execution paths
|
|
24
|
-
- **Logs** - Standard logging output for debugging
|
|
25
|
-
- **Platform Compatibility** - Uses the same infrastructure as Cloudflare, Vercel, and Netlify deployers
|
|
29
|
+

|
|
26
30
|
|
|
27
|
-
|
|
31
|
+
Key features:
|
|
28
32
|
|
|
29
|
-
The
|
|
33
|
+
The Project Dashboard gives you an overview of your application's status and deployments, with access to logs and a built-in playground for testing agents and workflows.
|
|
30
34
|
|
|
31
|
-
|
|
32
|
-
- **Project Details** - Deployments, environment variables, and access URLs
|
|
33
|
-
- **Deployment History** - Record of deployments with timestamps and status
|
|
34
|
-
- **Agent Inspector** - Agent configuration view showing models, tools, and system prompts
|
|
35
|
-
- **Testing Console** - Interface for sending messages to agents
|
|
36
|
-
- **Trace Explorer** - Records of tool calls, parameters, and responses
|
|
37
|
-
- **Workflow Viewer** - Diagram of workflow steps and connections
|
|
35
|
+
## Project structure
|
|
38
36
|
|
|
39
|
-
|
|
37
|
+
Use a standard Mastra project structure for proper detection and deployment.
|
|
40
38
|
|
|
41
|
-
|
|
39
|
+
<FileTree>
|
|
40
|
+
<FileTree.Folder name="src" defaultOpen>
|
|
41
|
+
<FileTree.Folder name="mastra" defaultOpen>
|
|
42
|
+
<FileTree.Folder name="agents" defaultOpen>
|
|
43
|
+
<FileTree.File name="agent-name.ts" />
|
|
44
|
+
</FileTree.Folder>
|
|
45
|
+
<FileTree.Folder name="tools" defaultOpen>
|
|
46
|
+
<FileTree.File name="tool-name.ts" />
|
|
47
|
+
</FileTree.Folder>
|
|
48
|
+
<FileTree.Folder name="workflows" defaultOpen>
|
|
49
|
+
<FileTree.File name="workflow-name.ts" />
|
|
50
|
+
</FileTree.Folder>
|
|
51
|
+
<FileTree.File name="index.ts" />
|
|
52
|
+
</FileTree.Folder>
|
|
53
|
+
</FileTree.Folder>
|
|
54
|
+
<FileTree.File name="package.json" />
|
|
55
|
+
</FileTree>
|
|
42
56
|
|
|
43
|
-
|
|
44
|
-
- **Dynamic Resource Allocation** - Adjusts compute resources based on traffic
|
|
45
|
-
- **Mastra-specific Runtime** - Runtime optimized for agent execution
|
|
46
|
-
- **Standard Deployment API** - Consistent deployment interface across environments
|
|
47
|
-
- **Tracing Infrastructure** - Records all agent and workflow execution steps
|
|
57
|
+
Mastra Cloud scans your repository for:
|
|
48
58
|
|
|
49
|
-
|
|
59
|
+
- **Agents**: Defined using: `new Agent({...})`
|
|
60
|
+
- **Tools**: Defined using: `createTool({...})`
|
|
61
|
+
- **Workflows**: Defined using: `createWorkflow({...})`
|
|
62
|
+
- **Steps**: Defined using: `createStep({...})`
|
|
63
|
+
- **Environment Variables**: API keys and configuration variables
|
|
50
64
|
|
|
51
|
-
|
|
65
|
+
## Technical implementation
|
|
52
66
|
|
|
53
|
-
-
|
|
54
|
-
- Maintaining staging and production environments
|
|
55
|
-
- Monitoring agent behavior across many requests
|
|
56
|
-
- Testing agent responses through a web interface
|
|
57
|
-
- Deploying to multiple regions
|
|
67
|
+
Mastra Cloud is purpose-built for Mastra agents, tools, and workflows. It handles long-running requests, records detailed traces for every execution, and includes built-in support for evals.
|
|
58
68
|
|
|
59
|
-
##
|
|
69
|
+
## Next steps
|
|
60
70
|
|
|
61
|
-
|
|
62
|
-
2. [Deploy code](/docs/mastra-cloud/deploying)
|
|
63
|
-
3. [View execution traces](/docs/mastra-cloud/observability)
|
|
71
|
+
- [Setting Up and Deploying](/docs/mastra-cloud/setting-up)
|
|
@@ -3,126 +3,90 @@ title: Setting Up a Project
|
|
|
3
3
|
description: Configuration steps for Mastra Cloud projects
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
import { MastraCloudCallout } from '@/components/mastra-cloud-callout'
|
|
7
|
+
import { Steps } from "nextra/components";
|
|
7
8
|
|
|
8
|
-
|
|
9
|
-
> Mastra Cloud is currently in **beta**.
|
|
9
|
+
# Setting Up and Deploying
|
|
10
10
|
|
|
11
|
-
This page
|
|
11
|
+
This page explains how to set up a project on [Mastra Cloud](https://mastra.ai/cloud) with automatic deployments using our GitHub integration.
|
|
12
12
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
- A Mastra Cloud account
|
|
16
|
-
- A GitHub account
|
|
17
|
-
- A GitHub repository containing a Mastra application
|
|
13
|
+
<MastraCloudCallout />
|
|
18
14
|
|
|
19
|
-
##
|
|
20
|
-
|
|
21
|
-
1. **Sign in to Mastra Cloud**
|
|
15
|
+
## Prerequisites
|
|
22
16
|
|
|
23
|
-
|
|
24
|
-
|
|
17
|
+
- A [Mastra Cloud](https://mastra.ai/cloud) account
|
|
18
|
+
- A GitHub account / repository containing a Mastra application
|
|
25
19
|
|
|
26
|
-
|
|
20
|
+
> See our [Getting started](/docs/getting-started/installation) guide to scaffold out a new Mastra project with sensible defaults.
|
|
27
21
|
|
|
28
|
-
|
|
29
|
-
- This opens the GitHub repository import dialog
|
|
22
|
+
## Setup and Deploy process
|
|
30
23
|
|
|
31
|
-
|
|
24
|
+
<Steps>
|
|
32
25
|
|
|
33
|
-
|
|
26
|
+
### Sign in to Mastra Cloud
|
|
34
27
|
|
|
35
|
-
|
|
36
|
-
- Click the "Import" button next to the repository you want to deploy
|
|
28
|
+
Head over to [https://cloud.mastra.ai/](https://cloud.mastra.ai) and sign in with either:
|
|
37
29
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
- **Repo Name**: The GitHub repository name (read-only)
|
|
41
|
-
- **Project Name**: Customize the project name (defaults to repo name)
|
|
42
|
-
- **Branch**: Select the branch to deploy (dropdown, defaults to `main`)
|
|
43
|
-
- **Project root**: Set the root directory of your project (defaults to `/`)
|
|
44
|
-
- **Mastra Directory**: Specify where Mastra files are located (defaults to `src/mastra`)
|
|
45
|
-
- **Build Command**: Optional command to run during build process
|
|
46
|
-
- **Store Settings**: Configure data storage options
|
|
47
|
-
- **Environment Variables**: Add key-value pairs for configuration (e.g., API keys)
|
|
30
|
+
- **GitHub**
|
|
31
|
+
- **Google**
|
|
48
32
|
|
|
49
|
-
|
|
33
|
+
### Install the Mastra GitHub app
|
|
50
34
|
|
|
51
|
-
|
|
35
|
+
When prompted, install the Mastra GitHub app.
|
|
52
36
|
|
|
53
|
-
|
|
54
|
-
- **Workflows**: Workflow step definitions (e.g., weather-workflow)
|
|
55
|
-
- **Environment Variables**: Required API keys and configuration variables
|
|
37
|
+

|
|
56
38
|
|
|
57
|
-
|
|
39
|
+
### Create a new project
|
|
58
40
|
|
|
59
|
-
|
|
41
|
+
Click the **Create new project** button to create a new project.
|
|
60
42
|
|
|
61
|
-
|
|
43
|
+

|
|
62
44
|
|
|
63
|
-
###
|
|
45
|
+
### Import a Git repository
|
|
64
46
|
|
|
65
|
-
|
|
66
|
-
- **Domains**: URLs for accessing your deployed application
|
|
67
|
-
- Format: `https://[project-name].mastra.cloud`
|
|
68
|
-
- Format: `https://[random-id].mastra.cloud`
|
|
69
|
-
- **Status**: Current deployment status (success or archived)
|
|
70
|
-
- **Branch**: The branch deployed (typically `main`)
|
|
71
|
-
- **Environment Variables**: Configured API keys and settings
|
|
72
|
-
- **Workflows**: List of detected workflows with step counts
|
|
73
|
-
- **Agents**: List of detected agents with models and tools
|
|
74
|
-
- **Database Usage**: Reads, writes, and storage statistics
|
|
47
|
+
Search for a repository, then click **Import**.
|
|
75
48
|
|
|
76
|
-
|
|
49
|
+

|
|
77
50
|
|
|
78
|
-
|
|
79
|
-
- Deployment ID (based on commit hash)
|
|
80
|
-
- Status (success/archived)
|
|
81
|
-
- Branch
|
|
82
|
-
- Commit hash
|
|
83
|
-
- Timestamp
|
|
51
|
+
### Configure the deployment
|
|
84
52
|
|
|
85
|
-
|
|
53
|
+
Mastra Cloud automatically detects the right build settings, but you can customize them using the options described below.
|
|
86
54
|
|
|
87
|
-
|
|
55
|
+

|
|
88
56
|
|
|
89
|
-
-
|
|
90
|
-
-
|
|
91
|
-
-
|
|
92
|
-
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
57
|
+
- **Importing from GitHub**: The GitHub repository name
|
|
58
|
+
- **Project name**: Customize the project name
|
|
59
|
+
- **Branch**: The branch to deploy from
|
|
60
|
+
- **Project root**: The root directory of your project
|
|
61
|
+
- **Mastra directory**: Where Mastra files are located
|
|
62
|
+
- **Environment variables**: Add environment variables used by the application
|
|
63
|
+
- **Build and Store settings**:
|
|
64
|
+
- **Install command**: Runs pre-build to install project dependencies
|
|
65
|
+
- **Project setup command**: Runs pre-build to prepare any external dependencies
|
|
66
|
+
- **Port**: The network port the server will use
|
|
67
|
+
- **Store settings**: Use Mastra Cloud's built-in [LibSQLStore](/docs/storage/overview) storage
|
|
68
|
+
- **Deploy Project**: Starts the deployment process
|
|
96
69
|
|
|
97
|
-
|
|
70
|
+
### Deploy project
|
|
98
71
|
|
|
99
|
-
|
|
72
|
+
Click **Deploy Project** to create and deploy your application using the configuration you’ve set.
|
|
100
73
|
|
|
101
|
-
|
|
102
|
-
- **Deployments**: Deployment history and details
|
|
103
|
-
- **Logs**: Application logs for debugging
|
|
104
|
-
- **Agents**: List and configuration of all agents
|
|
105
|
-
- **Workflows**: List and structure of all workflows
|
|
106
|
-
- **Settings**: Project configuration options
|
|
74
|
+
</Steps>
|
|
107
75
|
|
|
108
|
-
##
|
|
76
|
+
## Successful deployment
|
|
109
77
|
|
|
110
|
-
|
|
78
|
+
After a successful deployment you'll be shown the **Overview** screen where you can view your project's status, domains, latest deployments and connected agents and workflows.
|
|
111
79
|
|
|
112
|
-
|
|
113
|
-
2. Go to the "Environment Variables" section
|
|
114
|
-
3. Add or edit variables (such as `OPENAI_API_KEY`)
|
|
115
|
-
4. Save the configuration
|
|
80
|
+

|
|
116
81
|
|
|
117
|
-
|
|
82
|
+
## Continuous integration
|
|
118
83
|
|
|
119
|
-
|
|
84
|
+
Your project is now configured with automatic deployments which occur whenever you push to the configured branch of your GitHub repository.
|
|
120
85
|
|
|
121
|
-
|
|
86
|
+
## Testing your application
|
|
122
87
|
|
|
123
|
-
|
|
124
|
-
2. The dashboard interface for direct interaction with agents
|
|
88
|
+
After a successful deployment you can test your agents and workflows from the [Playground](/docs/mastra-cloud/dashboard#playground) in Mastra Cloud, or interact with them using our [Client SDK](/docs/client-js/overview).
|
|
125
89
|
|
|
126
|
-
## Next
|
|
90
|
+
## Next steps
|
|
127
91
|
|
|
128
|
-
|
|
92
|
+
- [Navigating the Dashboard](/docs/mastra-cloud/dashboard)
|
|
@@ -8,6 +8,8 @@ The context window is the total information visible to the language model at any
|
|
|
8
8
|
|
|
9
9
|
In Mastra, context is broken up into three parts: system instructions and information about the user ([working memory](./working-memory.mdx)), recent messages ([message history](#conversation-history)), and older messages that are relevant to the user’s query ([semantic recall](./semantic-recall.mdx)).
|
|
10
10
|
|
|
11
|
+
Working memory can persist at different scopes - either per conversation thread (default) or across all threads for the same user (resource-scoped), enabling persistent user profiles that remember context across conversations.
|
|
12
|
+
|
|
11
13
|
In addition, we provide [memory processors](./memory-processors.mdx) to trim context or remove information if the context is too long.
|
|
12
14
|
|
|
13
15
|
## Quick Start
|
|
@@ -69,6 +71,8 @@ Mastra organizes memory into threads, which are records that identify specific c
|
|
|
69
71
|
1. **`threadId`**: A specific conversation id (e.g., `support_123`).
|
|
70
72
|
2. **`resourceId`**: The user or entity id that owns each thread (e.g., `user_123`, `org_456`).
|
|
71
73
|
|
|
74
|
+
The `resourceId` is particularly important for [resource-scoped working memory](./working-memory.mdx#resource-scoped-memory), which allows memory to persist across all conversation threads for the same user.
|
|
75
|
+
|
|
72
76
|
```typescript {2,3}
|
|
73
77
|
const response = await myMemoryAgent.stream("Hello, my name is Alice.", {
|
|
74
78
|
resourceId: "user_alice",
|