# ast-grep MCP Server

> Use this tool when you need to search and refactor code across multiple programming languages, and want to identify and transform specific code patterns. It solves problems such as finding and replacing outdated code, detecting security vulnerabilities, and enforcing coding standards. The tool takes ast-grep patterns as input and outputs matched code snippets, with options for dry-run mode and filtering.

Canonical page: https://skillsregistry.net/skills/thrawn01-mcp-ast-grep  
JSON: https://api.skillsregistry.net/v1/skills/thrawn01-mcp-ast-grep

## Description

Enables structural code search and refactoring across 20+ programming languages using ast-grep patterns, with safe dry-run mode and flexible filtering.

## Trust

- **Trust score (0–1):** 0.70
- **Verification tier:** verified
- **Last scanned:** 2026-08-31

## Facts

- **Version:** 1.0.0
- **Skill type:** atomic
- **Execution layer:** mcp-remote
- **Runtime environment:** api
- **Category:** search
- **Updated:** 2026-08-31

## Source

- **Source listing:** [Glama](https://glama.ai/mcp/servers/gvg5wyunjk)
- **Repository:** <https://github.com/thrawn01/mcp-ast-grep>

## Use it

Resolve this record through the SkillsRegistry MCP server (no auth, read-only):

```
claude mcp add --transport http --scope user skillsregistry https://api.skillsregistry.net/mcp
```

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "get_skill",
    "arguments": {
      "slug": "thrawn01-mcp-ast-grep"
    }
  }
}
```

REST: `GET https://api.skillsregistry.net/v1/skills/thrawn01-mcp-ast-grep` · pull for local use: `GET https://api.skillsregistry.net/v1/skills/thrawn01-mcp-ast-grep/pull`

---
SkillsRegistry indexes agent skills from public registries and GitHub. Skills we have analysed are scanned with Circle-IR and scored on six dimensions; each listing states its scan coverage. More: https://skillsregistry.net/llms.txt
