New:Socket for Asana Is Now Available.Learn more
Get Started

@mastra/mysql

Package Overview
Dependencies
Maintainers
7
Versions
144
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
This package has malicious versions linked to the ongoing "Mastra AI framework compromise" supply chain attack.

Affected versions:

0.1.1
View campaign page

@mastra/mysql

MySQL provider for Mastra - db storage capabilities

latest
Source
npmnpm
Version
0.8.5
Version published
Weekly downloads
2.4K
25.19%
Maintainers
7
Weekly downloads
 
Created
Source

@mastra/mysql

MySQL storage implementation for Mastra, providing persistent storage for threads, messages, workflows, traces, and more with connection pooling and transaction support.

Installation

npm install @mastra/mysql

Usage

Configure the database credentials required by your provider.

import { Mastra } from '@mastra/core';
import { MySQLStore } from '@mastra/mysql';

export const mastra = new Mastra({
  storage: new MySQLStore({
    connectionString: 'mysql://user:password@localhost:3306/mastra',
  }),
});

Documentation

This README is the package guide. MySQLStore provides Mastra's storage domains through a MySQL connection pool, including agents, messages, workflows, observability, scores, datasets, prompt blocks, MCP records, and workspaces.

Changelog

See the package changelog for version history and release notes.

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.

FAQs

Package last updated on 03 Sep 2026

Related posts