npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

@dooi/mastra101

v1.0.0-beta.14

Published

MCP server for accessing Mastra.ai documentation, changelogs, and news.

Readme

@mastra/mcp-docs-server

A Model Context Protocol (MCP) server that provides AI assistants with direct access to Mastra.ai's complete knowledge base. This includes comprehensive documentation with MDX support, a collection of production-ready code examples, technical blog posts, and detailed package changelogs. The server integrates with popular AI development environments like Cursor and Windsurf, as well as Mastra agents, making it easy to build documentation-aware AI assistants that can provide accurate, up-to-date information about Mastra.ai's ecosystem.

Installation

In Cursor

Create or update .cursor/mcp.json in your project root:

MacOS/Linux

{
  "mcpServers": {
    "mastra": {
      "command": "npx",
      "args": ["-y", "@mastra/mcp-docs-server"]
    }
  }
}

Windows

{
  "mcpServers": {
    "mastra": {
      "command": "cmd",
      "args": ["/c", "npx", "-y", "@mastra/mcp-docs-server"]
    }
  }
}

This will make all Mastra documentation tools available in your Cursor workspace. Note that the MCP server wont be enabled by default. You'll need to go to Cursor settings -> MCP settings and click "enable" on the Mastra MCP server.

In Windsurf

Create or update ~/.codeium/windsurf/mcp_config.json:

MacOS/Linux

{
  "mcpServers": {
    "mastra": {
      "command": "npx",
      "args": ["-y", "@mastra/mcp-docs-server"]
    }
  }
}

Windows

{
  "mcpServers": {
    "mastra": {
      "command": "cmd",
      "args": ["/c", "npx", "-y", "@mastra/mcp-docs-server"]
    }
  }
}

This will make all Mastra documentation tools available in your Windsurf workspace. Note that Windsurf MCP tool calling doesn't work very well. You will need to fully quit and re-open Windsurf after adding this. If a tool call fails you will need to go into Windsurf MCP settings and re-start the MCP server.

In Claude Code

After installing Claude Code run:

claude mcp add mastra-docs -- npx -y @mastra/mcp-docs-server

In a Mastra Agent

import { MCPClient } from '@mastra/mcp';
import { Agent } from '@mastra/core/agent';
import { openai } from '@ai-sdk/openai';

// Configure MCP with the docs server
const mcp = new MCPClient({
  servers: {
    mastra: {
      command: 'npx',
      args: ['-y', '@mastra/mcp-docs-server'],
    },
  },
});

// Create an agent with access to all documentation tools
const agent = new Agent({
  id: 'doc-assistant',
  name: 'Documentation Assistant',
  instructions: 'You help users find and understand Mastra.ai documentation.',
  model: openai('gpt-4'),
  tools: await mcp.listTools(),
});

// Or use toolsets dynamically in generate/stream
const response = await agent.stream('Show me the quick start example', {
  toolsets: await mcp.listToolsets(),
});

Tools

Documentation Tool (mastraDocs)

  • Get Mastra.ai documentation by requesting specific paths
  • Explore both general guides and API reference documentation
  • Automatically lists available paths when a requested path isn't found

Examples Tool (mastraExamples)

  • Access code examples showing Mastra.ai implementation patterns
  • List all available examples
  • Get detailed source code for specific examples

Blog Tool (mastraBlog)

  • Access technical blog posts and articles
  • Posts are properly formatted with code block handling
  • Supports various date formats in blog metadata

Changes Tool (mastraChanges)

  • Access package changelogs
  • List all available package changelogs
  • Get detailed changelog content for specific packages

Migration Tool (mastraMigration)

  • Get migration guidance for Mastra version upgrades and breaking changes
  • Explore all available migration guides (e.g., upgrade-to-v1/, agentnetwork)
  • List section headers to see what breaking changes are covered
  • Fetch specific sections or entire migration guides
  • Search across all migration guides by keywords