Fork of mastra-ai/mastra for local patches https://mastra.ai
  • TypeScript 99.2%
  • JavaScript 0.6%
Find a file
Tobias Eckardt f179db0452
All checks were successful
secret-scan / gitleaks (push) Successful in 13s
ci: gitleaks --platform gitea for finding links
2026-06-28 16:18:54 +00:00
.agents/skills/testing-core-processors Add testing skill for core processors (#15751) 2026-05-11 12:13:01 -07:00
.changeset Revamp agent-builder onboarding: ready entry, identity step, back navigation, add-to-library step (#17687) 2026-06-10 10:39:24 +02:00
.claude feat(playground-ui): CodeBlock as canonical code surface with CSS-driven light/dark highlighting (#17430) 2026-06-09 19:12:30 -07:00
.cursor chore: consolidate slash commands to .mastracode as single source of truth (#14693) 2026-03-25 14:26:55 -05:00
.dev chore(deps): update pgvector/pgvector docker tag to v0.8.2 (#15527) 2026-04-20 15:30:36 +02:00
.forgejo/workflows ci: gitleaks --platform gitea for finding links 2026-06-28 16:18:54 +00:00
.github fix(ci): auto-run pending release workflow (#17715) 2026-06-09 15:15:50 +02:00
.husky chore: add missing lint-staged configs (#17220) 2026-05-28 12:01:09 -07:00
.mastracode/commands fix: preserve unresolved slash command references and update pr-triage command (#17032) 2026-05-25 14:26:30 -07:00
.opencode chore: consolidate slash commands to .mastracode as single source of truth (#14693) 2026-03-25 14:26:55 -05:00
.superset add superset config (#12387) 2026-01-27 19:06:19 -08:00
agent-sdks chore(deps): update dependency @anthropic-ai/claude-agent-sdk to ^0.3.168 (#17744) 2026-06-09 22:39:41 -07:00
auth chore(deps): update formatting & linting (#17151) 2026-06-05 08:36:15 -07:00
browser chore: version packages (alpha) (#17644) 2026-06-06 09:16:55 -07:00
channels/slack chore(deps): update security updates [security] (major) (#16478) 2026-06-06 10:37:27 -07:00
client-sdks feat(playground-ui): CodeBlock as canonical code surface with CSS-driven light/dark highlighting (#17430) 2026-06-09 19:12:30 -07:00
deployers chore: version packages (alpha) (#17665) 2026-06-08 11:10:59 +02:00
docs docs: add tool hooks conceptual documentation (#17733) 2026-06-09 11:16:34 -07:00
e2e-tests feat(core): run agentic loop on the evented workflow engine (#16796) 2026-06-09 00:13:36 +01:00
ee Revise LICENSE with updated copyright and terms (#16744) 2026-05-18 17:32:11 -04:00
embedders/voyageai feat(voyageai): add VoyageAI embeddings and reranker integration (#14296) 2026-06-09 08:01:38 -07:00
examples Revamp agent-builder onboarding: ready entry, identity step, back navigation, add-to-library step (#17687) 2026-06-10 10:39:24 +02:00
explorations Revamp agent-builder onboarding: ready entry, identity step, back navigation, add-to-library step (#17687) 2026-06-10 10:39:24 +02:00
integrations chore(deps): update ai provider sdks to ^0.7.5 (#17743) 2026-06-09 22:39:28 -07:00
mastracode Fix analytics distinct ID collisions (#17695) 2026-06-09 08:08:42 -07:00
observability feat(langfuse): forward custom metadata to top-level trace metadata (#17689) 2026-06-09 10:24:01 -04:00
packages Revamp agent-builder onboarding: ready entry, identity step, back navigation, add-to-library step (#17687) 2026-06-10 10:39:24 +02:00
patches chore: remove orphaned @changesets/get-dependents-graph@2.1.3 patch (#17451) 2026-06-01 23:36:55 -05:00
pubsub chore(deps): update formatting & linting (#17151) 2026-06-05 08:36:15 -07:00
scripts chore: fix tsx dependency and add workspace configs for internal scripts (#17616) 2026-06-05 15:17:49 +02:00
server-adapters feat(react): add agent voice helpers and make agent text-to-speech audible (#17663) 2026-06-09 10:35:48 +02:00
signals/github chore: version packages (alpha) (#17644) 2026-06-06 09:16:55 -07:00
stores feat(harness): add libsql storage adapter (#17712) 2026-06-09 08:01:05 -07:00
templates chore(repo): Use tsx catalog dep (#17605) 2026-06-05 13:44:28 +02:00
voice chore(deps): update ai provider sdks (#17144) 2026-06-09 16:34:52 +02:00
workflows feat(core): run agentic loop on the evented workflow engine (#16796) 2026-06-09 00:13:36 +01:00
workspaces fix(gcs): populate mimeType on stat() so read_file surfaces media (#16911) 2026-06-09 11:33:22 -07:00
.coderabbit.yaml chore: allow CodeRabbit reviews on Devin PRs (#15933) 2026-04-29 12:11:35 -07:00
.gitignore use exact hash matching (#16873) 2026-05-21 15:22:11 +02:00
.gitleaksignore ci: baseline upstream gitleaks false positives 2026-06-28 16:15:24 +00:00
.prettierignore feat(playground): add Agent Builder create page (#17056) 2026-05-26 11:27:45 +02:00
.prettierrc chore: eslint fix core (#2522) 2025-02-25 11:43:11 +01:00
.stylelintrc.json feat(playground): migrate to Tailwind CSS v4 (#14772) 2026-03-30 10:49:00 +02:00
AGENTS.md feat(playground): add Agent Builder create page (#17056) 2026-05-26 11:27:45 +02:00
CLAUDE.md chore(repo): Cleanup files (#15434) 2026-04-16 11:30:13 +02:00
CODE_OF_CONDUCT.md chore: Add docs styleguides (#13263) 2026-02-19 13:45:33 +01:00
CONTRIBUTING.md chore(repo): Note requirement of linked issue (#16397) 2026-05-10 21:20:54 -04:00
DEVELOPMENT.md chore(repo): Note requirement of linked issue (#16397) 2026-05-10 21:20:54 -04:00
LICENSE.md feat: auth core, server RBAC, and adapter permission enforcement (#13163) 2026-03-03 22:49:10 +01:00
package.json chore(deps): update dependency pnpm to v11.5.1 (#17043) 2026-06-06 00:52:48 +02:00
pnpm-lock.yaml chore(deps): update dependency @anthropic-ai/claude-agent-sdk to ^0.3.168 (#17744) 2026-06-09 22:39:41 -07:00
pnpm-workspace.yaml feat(voyageai): add VoyageAI embeddings and reranker integration (#14296) 2026-06-09 08:01:38 -07:00
README.md fix(docs): unify CLI command and fix grammar across docs (#15854) 2026-04-28 08:35:15 -07:00
renovate.json Improve Renovate update grouping (#17107) 2026-05-27 09:07:30 +02:00
tsconfig.build.json fix type generation (#6588) 2025-08-05 10:47:22 -07:00
tsconfig.json chore: upgrade TypeScript from 5.9.3 to 6.0.3 (#15884) 2026-04-29 10:18:03 -07:00
tsconfig.node.json chore: upgrade TypeScript from 5.9.3 to 6.0.3 (#15884) 2026-04-29 10:18:03 -07:00
turbo.json Turbo changes (#17557) 2026-06-04 09:37:26 +02:00
vitest.config.observability.ts Add new OtelBridge package (#10482) 2025-11-26 14:39:15 +01:00
vitest.config.ts feat(core): add SignalProvider abstraction + @mastra/github-signals package (#17577) 2026-06-04 14:40:56 -05:00

Mastra

npm version CodeQl GitHub Repo stars Discord Twitter Follow NPM Downloads Static Badge

Mastra is a framework for building AI-powered applications and agents with a modern TypeScript stack.

It includes everything you need to go from early prototypes to production-ready applications. Mastra integrates with frontend and backend frameworks like React, Next.js, and Node, or you can deploy it anywhere as a standalone server. It's the easiest way to build, tune, and scale reliable AI products.

Why Mastra?

Purpose-built for TypeScript and designed around established AI patterns, Mastra gives you everything you need to build great AI applications out-of-the-box.

Some highlights include:

  • Model routing - Connect to 40+ providers through one standard interface. Use models from OpenAI, Anthropic, Gemini, and more.

  • Agents - Build autonomous agents that use LLMs and tools to solve open-ended tasks. Agents reason about goals, decide which tools to use, and iterate internally until the model emits a final answer or an optional stopping condition is met.

  • Workflows - When you need explicit control over execution, use Mastra's graph-based workflow engine to orchestrate complex multi-step processes. Mastra workflows use an intuitive syntax for control flow (.then(), .branch(), .parallel()).

  • Human-in-the-loop - Suspend an agent or workflow and await user input or approval before resuming. Mastra uses storage to remember execution state, so you can pause indefinitely and resume where you left off.

  • Context management - Give your agents the right context at the right time. Provide conversation history, retrieve data from your sources (APIs, databases, files), and add human-like working and semantic memory so your agents behave coherently.

  • Integrations - Bundle agents and workflows into existing React, Next.js, or Node.js apps, or ship them as standalone endpoints. When building UIs, integrate with agentic libraries like Vercel's AI SDK UI and CopilotKit to bring your AI assistant to life on the web.

  • MCP servers - Author Model Context Protocol servers, exposing agents, tools, and other structured resources via the MCP interface. These can then be accessed by any system or agent that supports the protocol.

  • Production essentials - Shipping reliable agents takes ongoing insight, evaluation, and iteration. With built-in evals and observability, Mastra gives you the tools to observe, measure, and refine continuously.

Get started

The recommended way to get started with Mastra is by running the command below:

npm create mastra@latest

Follow the Installation guide for step-by-step setup with the CLI or a manual install.

If you're new to AI agents, check out our templates, course, and YouTube videos to start building with Mastra today.

Documentation

Visit our official documentation.

Build with AI

Learn how to make your agent a Mastra expert by following the Build with AI guide.

Contributing

Looking to contribute? All types of help are appreciated, from coding to testing and feature specification. Read CONTRIBUTING.md for more details on how to get involved.

If you are a developer and would like to contribute with code, please open an issue to discuss before opening a Pull Request.

Information about the project setup can be found in the development documentation

Support

We have an open community Discord. Come and say hello and let us know if you have any questions or need any help getting things running.

It's also super helpful if you leave the project a star here, at the top of the page

Licensing

This repository uses a dual-license model:

  • Apache License 2.0 — The core framework and the vast majority of this codebase is open source under Apache-2.0.
  • Mastra Enterprise License — Code in any directory named ee/ (e.g., packages/core/src/auth/ee/) is source-available under the Mastra Enterprise License. These features require a valid enterprise license for production use but can be freely used for development and testing.

See LICENSE.md for the full license mapping and ee/LICENSE for the enterprise license terms.

Security

We are committed to maintaining the security of this repo and of Mastra as a whole. If you discover a security finding we ask you to please responsibly disclose this to us at security@mastra.ai and we will get back to you.