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

agentql-mcp

v1.0.0

Published

Model Context Protocol (MCP) server that integrates AgentQL data extraction capabilities.

Downloads

745

Readme

AgentQL MCP Server

This is a Model Context Protocol (MCP) server that integrates AgentQL's data extraction capabilities.

Features

Tools

  • extract-web-data - extract structured data from a given 'url', using 'prompt' as a description of actual data and its fields to extract.

Installation

Install the package

npm install -g agentql-mcp

Configure Claude

  • Open Claude Desktop Settings via +, (don't confuse with Claude Account Settings)
  • Go to Developer sidebar section
  • Click Edit Config and open claude_desktop_config.json file
  • Add agentql server inside mcpServers dictionary in the config file
  • Restart the app
{
  "mcpServers": {
    "agentql": {
      "command": "npx",
      "args": ["-y", "agentql-mcp"],
      "env": {
        "AGENTQL_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

Read more about MCP configuration in Claude here.

Configure Cursor

  • Open Cursor Settings
  • Go to MCP > MCP Servers
  • Click + Add new MCP Server
  • Enter the following:
    • Name: "agentql" (or your preferred name)
    • Type: "command"
    • Command: env AGENTQL_API_KEY=YOUR_API_KEY npx -y agentql-mcp

Read more about MCP configuration in Cursor here.

Configure Windsurf

  • Open Windsurf: MCP Configuration Panel
  • Click Add custom server+
  • Alternatively you can open ~/.codeium/windsurf/mcp_config.json directly
  • Add agentql server inside mcpServers dictionary in the config file
{
  "mcpServers": {
    "agentql": {
      "command": "npx",
      "args": ["-y", "agentql-mcp"],
      "env": {
        "AGENTQL_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

Read more about MCP configuration in Windsurf here.

Validate MCP integration

Give your agent a task that will require extracting data from the web. For example:

Extract the list of videos from the page https://www.youtube.com/results?search_query=agentql, every video should have a title, an author name, a number of views and a url to the video. Make sure to exclude ads items. Format this as a markdown table.

[!TIP] In case your agent complains that it can't open urls or load content from the web instead of using AgentQL, try adding "use tools" or "use agentql tool" hint.

Development

Install dependencies:

npm install

Build the server:

npm run build

For development with auto-rebuild:

npm run watch

If you want to try out development version, you can use the following config instead of the default one:

{
  "mcpServers": {
    "agentql": {
      "command": "/path/to/agentql-mcp/dist/index.js",
      "env": {
        "AGENTQL_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

[!NOTE] Don't forget to remove the default AgentQL MCP server config to not confuse Claude with two similar servers.

Debugging

Since MCP servers communicate over stdio, debugging can be challenging. We recommend using the MCP Inspector, which is available as a package script:

npm run inspector

The Inspector will provide a URL to access debugging tools in your browser.