mastra 1.27.3-alpha.0 → 1.27.3-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/dist/docs/SKILL.md +5 -5
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/docs/references/reference-cli-mastra.md +4 -4
- package/dist/docs/references/reference-migrations-mastra-cloud.md +9 -9
- package/dist/factory/assets/{engine-javascript-C3-9bBUN.js → engine-javascript--ixMstp8.js} +1 -1
- package/dist/factory/assets/index-CQZmdzfQ.css +1 -0
- package/dist/factory/assets/index-Z8BEHJ8i.js +1261 -0
- package/dist/factory/index.html +2 -2
- package/dist/index.js +2 -2
- package/dist/studio/assets/{core-Cfz3znEY.js → core-CvurbC5G.js} +1 -1
- package/dist/studio/assets/{index-C_JOQ9Ll.js → index-YkpBcJ7K.js} +2 -2
- package/dist/studio/assets/{main-oX8K-xsm.js → main-CvsyGOuE.js} +220 -220
- package/dist/studio/assets/style-DF9FhraD.css +1 -0
- package/dist/studio/index.html +2 -2
- package/package.json +6 -7
- package/CHANGELOG.md +0 -13979
- package/dist/factory/assets/index-CqKBh7xf.css +0 -1
- package/dist/factory/assets/index-DbguJ_5R.js +0 -1240
- package/dist/studio/assets/style-Ck_52J2M.css +0 -1
package/dist/docs/SKILL.md
CHANGED
|
@@ -3,7 +3,7 @@ name: mastra
|
|
|
3
3
|
description: Documentation for mastra. Use when working with mastra APIs, configuration, or implementation.
|
|
4
4
|
metadata:
|
|
5
5
|
package: "mastra"
|
|
6
|
-
version: "1.27.3-alpha.
|
|
6
|
+
version: "1.27.3-alpha.2"
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
## When to use
|
|
@@ -16,13 +16,13 @@ Read the individual reference documents for detailed explanations and code examp
|
|
|
16
16
|
|
|
17
17
|
### Docs
|
|
18
18
|
|
|
19
|
-
- [API Reference: Mastra platform](references/docs-mastra-platform-api.md) -
|
|
19
|
+
- [API Reference: Mastra platform](references/docs-mastra-platform-api.md) - Use the Mastra platform REST API to manage members, tokens, Studio and Server deployments, gateways, observability feedback, and project-scoped resources.
|
|
20
20
|
|
|
21
21
|
### Reference
|
|
22
22
|
|
|
23
|
-
- [Reference: CLI commands](references/reference-cli-mastra.md) -
|
|
24
|
-
- [Migrate from Mastra Cloud](references/reference-migrations-mastra-cloud.md) -
|
|
25
|
-
- [CLI](references/reference-migrations-upgrade-to-v1-cli.md) -
|
|
23
|
+
- [Reference: CLI commands](references/reference-cli-mastra.md) - You can use the Command-Line Interface (CLI) provided by Mastra to develop, build, and start your Mastra project.
|
|
24
|
+
- [Migrate from Mastra Cloud](references/reference-migrations-mastra-cloud.md) - The Mastra platform replaces Mastra Cloud with separate Studio and Server products, CLI-driven deploys, and a new observability system.
|
|
25
|
+
- [CLI](references/reference-migrations-upgrade-to-v1-cli.md) - The CLI has been simplified by removing deployment commands, configuration flags, and starter files. A new migration command has been added to help with database schema upgrades.
|
|
26
26
|
|
|
27
27
|
|
|
28
28
|
Read [assets/SOURCE_MAP.json](assets/SOURCE_MAP.json) for source code references.
|
|
@@ -353,7 +353,7 @@ The command runs `mastra build` and zips the output before uploading it to the s
|
|
|
353
353
|
|
|
354
354
|
Organization, project, and environment are resolved in order from: environment variable (`MASTRA_ORG_ID`, `MASTRA_PROJECT_ID`), CLI flag (`--org`, `--project`, `--env`), `.mastra-project.json` config file, current org from credentials, and lastly interactive prompt. On first deploy, the CLI saves the resolved org and project IDs to `.mastra-project.json` so subsequent deploys skip the prompts.
|
|
355
355
|
|
|
356
|
-
|
|
356
|
+
After confirmation, the CLI creates a missing project from the `package.json` `name` field and creates a missing target environment, defaulting to `type: staging` for anything other than `production`. Combined with `--yes`, this creates and deploys everything in one non-interactive command:
|
|
357
357
|
|
|
358
358
|
```bash
|
|
359
359
|
mastra deploy --env staging --yes
|
|
@@ -717,7 +717,7 @@ Shows diagnosis results and suggested fixes for a failed Studio deploy.
|
|
|
717
717
|
mastra studio deploy suggestions [deploy-id]
|
|
718
718
|
```
|
|
719
719
|
|
|
720
|
-
|
|
720
|
+
When you omit `deploy-id`, the command uses the latest deploy for the linked project and starts a diagnosis if needed, polling until the results are ready. Suggestions appear only when the diagnosis finds a problem.
|
|
721
721
|
|
|
722
722
|
### `mastra studio projects`
|
|
723
723
|
|
|
@@ -725,7 +725,7 @@ Lists all projects in the current organization.
|
|
|
725
725
|
|
|
726
726
|
### `mastra studio projects create`
|
|
727
727
|
|
|
728
|
-
Creates a new project through an interactive prompt
|
|
728
|
+
Creates a new project through an interactive prompt, but doesn't accept a `--name` flag. For non-interactive project creation, use [`mastra studio deploy --project <name> --yes`](#mastra-studio-deploy) instead. That command creates the project and deploys to it in one step.
|
|
729
729
|
|
|
730
730
|
## `mastra server deploy`
|
|
731
731
|
|
|
@@ -747,7 +747,7 @@ Shows diagnosis results and suggested fixes for a failed Server deploy.
|
|
|
747
747
|
mastra server deploy suggestions [deploy-id]
|
|
748
748
|
```
|
|
749
749
|
|
|
750
|
-
|
|
750
|
+
When you omit `deploy-id`, the command uses the latest deploy for the linked project and starts a diagnosis if needed, polling until the results are ready. Suggestions appear only when the diagnosis finds a problem.
|
|
751
751
|
|
|
752
752
|
## `mastra server pause`
|
|
753
753
|
|
|
@@ -60,7 +60,7 @@ The Mastra platform replaces Mastra Cloud with separate Studio and Server produc
|
|
|
60
60
|
|
|
61
61
|
## Replace Mastra Cloud Store with a hosted database
|
|
62
62
|
|
|
63
|
-
Mastra Cloud provided a managed libSQL database
|
|
63
|
+
Unlike Mastra Cloud, which provided a managed libSQL database backed by [Turso](https://turso.tech), the Mastra platform doesn't host a database for you. Point your storage at an externally hosted instance.
|
|
64
64
|
|
|
65
65
|
If you were already using a hosted database ("bring your own"), keep the existing database configuration. Ensure the connection string is set as an environment variable in the dashboard rather than hardcoded.
|
|
66
66
|
|
|
@@ -80,7 +80,7 @@ Once the download completes, convert the dump into a SQLite database file:
|
|
|
80
80
|
sqlite3 mydb.db < ~/Downloads/mastra-cloud-dump.sql
|
|
81
81
|
```
|
|
82
82
|
|
|
83
|
-
You now have a portable `mydb.db` file you can inspect locally
|
|
83
|
+
You now have a portable `mydb.db` file that you can inspect locally or back up before using it as the source for the new database in the following steps.
|
|
84
84
|
|
|
85
85
|
#### Option B: Export via the Turso CLI
|
|
86
86
|
|
|
@@ -88,16 +88,16 @@ If you prefer to work from the command line, or need to script the export, you c
|
|
|
88
88
|
|
|
89
89
|
1. Retrieve your Cloud Store credentials from the dashboard.
|
|
90
90
|
|
|
91
|
-
Open your project in the [Mastra dashboard](https://projects.mastra.ai) and navigate to **Runtime → Settings → Env Variables**. For Cloud Store
|
|
91
|
+
Open your project in the [Mastra dashboard](https://projects.mastra.ai) and navigate to **Runtime → Settings → Env Variables**. For projects backed by Cloud Store, two variables are injected alongside your own:
|
|
92
92
|
|
|
93
93
|
- `MASTRA_STORAGE_URL`: A libSQL connection string (e.g. `libsql://<db-name>-<org>.turso.io`).
|
|
94
94
|
- `MASTRA_STORAGE_AUTH_TOKEN`: A read-capable auth token scoped to that database.
|
|
95
95
|
|
|
96
|
-
Each row supports the standard environment variable actions
|
|
96
|
+
Each row supports the standard environment variable actions: show or hide via the eye toggle, Edit, Delete, and Copy Value. Use **Copy Value** to grab both values for the dump command below.
|
|
97
97
|
|
|
98
98
|
> **Note:** These variables only appear for projects that were provisioned with Cloud Store. If you brought your own database to Mastra Cloud, you already have these credentials and can skip ahead to [Point your Mastra app at the new database](#point-your-mastra-app-at-the-new-database).
|
|
99
99
|
|
|
100
|
-
> **Note:** If the variables are missing, the values
|
|
100
|
+
> **Note:** If the variables are missing, the values don't decrypt, or the Turso CLI rejects the token, email <support@mastra.ai> from the address associated with your Mastra Cloud account and ask for the libSQL URL and auth token for the project you want to export. Include the project name/ID. Support can also run the dump on your behalf if CLI access is blocked on your network.
|
|
101
101
|
|
|
102
102
|
2. Install the Turso CLI.
|
|
103
103
|
|
|
@@ -113,7 +113,7 @@ If you prefer to work from the command line, or need to script the export, you c
|
|
|
113
113
|
|
|
114
114
|
3. Export the database to a SQL dump.
|
|
115
115
|
|
|
116
|
-
Set the credentials provided by support (or use the dashboard values if you already copied them earlier) as environment variables, then dump the database to a local file. If you copied the URL from the dashboard, swap the `libsql://` scheme for `https://`
|
|
116
|
+
Set the credentials provided by support (or use the dashboard values if you already copied them earlier) as environment variables, then dump the database to a local file. If you copied the URL from the dashboard, swap the `libsql://` scheme for `https://` because the Turso CLI expects the HTTPS form when passing the URL with an auth token.
|
|
117
117
|
|
|
118
118
|
```bash
|
|
119
119
|
export MASTRA_STORAGE_URL="https://<db-name>-<org>.turso.io"
|
|
@@ -122,7 +122,7 @@ If you prefer to work from the command line, or need to script the export, you c
|
|
|
122
122
|
turso db shell "$MASTRA_STORAGE_URL?authToken=$MASTRA_STORAGE_AUTH_TOKEN" ".dump" > mastra-cloud-dump.sql
|
|
123
123
|
```
|
|
124
124
|
|
|
125
|
-
> **Warning:** Embedding the auth token in the connection string is less secure than Turso's recommended pattern
|
|
125
|
+
> **Warning:** Embedding the auth token in the connection string is less secure than Turso's recommended pattern because the full URL, including the token, can appear in command history and in process or terminal output. Turso recommends running `turso auth login` and dumping by database name only: `turso db shell <database-name> ".dump" > mastra-cloud-dump.sql`. That flow requires the database to belong to a Turso account you own, which isn't true for Cloud Store, so the environment-variable example above provides an alternative for this one-time export. To avoid token interpolation entirely, ask support to run the dump and send you the resulting SQL file.
|
|
126
126
|
|
|
127
127
|
The resulting `mastra-cloud-dump.sql` contains the full schema and data: thread and message history, workflow snapshots, traces, and eval scores. Store it somewhere safe before continuing.
|
|
128
128
|
|
|
@@ -136,7 +136,7 @@ The dump is a standard SQL file and can be loaded into any libSQL-compatible dat
|
|
|
136
136
|
turso auth login
|
|
137
137
|
```
|
|
138
138
|
|
|
139
|
-
If you
|
|
139
|
+
If you don't have a Turso account, the CLI will prompt you to create one. See [Turso pricing](https://turso.tech/pricing) for plan details.
|
|
140
140
|
|
|
141
141
|
2. Create a new database and load the dump in one step.
|
|
142
142
|
|
|
@@ -144,7 +144,7 @@ The dump is a standard SQL file and can be loaded into any libSQL-compatible dat
|
|
|
144
144
|
turso db create mastra-migrated --from-dump ./mastra-cloud-dump.sql
|
|
145
145
|
```
|
|
146
146
|
|
|
147
|
-
`--from-dump` restores a local SQLite/libSQL dump at create time, which is faster and safer than piping statements through `turso db shell` after the fact. Pick a region close to where your Mastra Server runs to minimize latency
|
|
147
|
+
`--from-dump` restores a local SQLite/libSQL dump at create time, which is faster and safer than piping statements through `turso db shell` after the fact. Pick a region close to where your Mastra Server runs to minimize latency. List available regions with `turso db locations` and pass `--group <group-name>` if you manage multiple groups.
|
|
148
148
|
|
|
149
149
|
For multi-gigabyte dumps, add `--wait` so the CLI blocks until the database is fully available.
|
|
150
150
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{J as t}from"./index-
|
|
1
|
+
import{J as t}from"./index-Z8BEHJ8i.js";import{c as p,d as i}from"./index-Z8BEHJ8i.js";function n(){const e={cache:new Map,regexConstructor:()=>{throw new Error("JavaScriptRawEngine: only support precompiled grammar")}};return{createScanner(r){return new t(r,e)},createString(r){return{content:r}}}}export{t as JavaScriptScanner,n as createJavaScriptRawEngine,p as createJavaScriptRegexEngine,i as defaultJavaScriptRegexConstructor};
|