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 🙏

© 2026 – Pkg Stats / Ryan Hefner

@yansirplus/mcp-wp

v1.0.4

Published

A simple MCP server for WordPress

Readme

MCP Currency Converter

A Model Context Protocol (MCP) server that

Installation

# Using npm
npm install @yansirplus/mcp-wp

# Using yarn
yarn add @yansirplus/mcp-wp

# Using bun
bun install @yansirplus/mcp-wp

Using as a CLI Tool

After installation, you can run the MCP server directly from the command line:

# If installed globally
mcp-wp

# If installed locally
npx @yansirplus/mcp-wp

This will start the MCP server in stdio mode, allowing you to connect to it with MCP clients.

Using as a dependency

// Import the server
import { server } from "@yansirplus/mcp-wp";

// Connect to your own transport
import { YourTransport } from "./your-transport.js";
const transport = new YourTransport();
await server.connect(transport);

// Or use programmatically
const toolResponse = await server.callTool("usd-to-cny", { amount: 100 });
console.log(toolResponse);

// Just use the conversion function
import { convertUsdToCny } from "@yansirplus/mcp-wp";
console.log(convertUsdToCny(100)); // 730

Building

bun run build

Running

Stdio Mode (Command Line)

bun start

HTTP Server Mode

This mode exposes the MCP server over HTTP with Server-Sent Events (SSE):

bun run start:http

The server will run on port 3000 by default. You can set a different port using the PORT environment variable:

PORT=8080 bun run start:http

Endpoints:

  • SSE Connection: GET /sse
  • Message Endpoint: POST /messages?sessionId=<your-session-id>

Usage

This MCP server provides a single tool:

usd-to-cny

Converts a USD amount to CNY using a fixed exchange rate of 7.3.

Parameters:

  • amount: A positive number representing the USD amount to convert

Example Response:

100 USD = 730.00 CNY (rate: 7.3)

Testing with MCP Inspector

You can test this server using the MCP Inspector. Run the server and then connect the inspector to it.

Testing Stdio Mode

  1. Start the server: bun start
  2. Open the MCP Inspector
  3. Select the server type (localhost stdio)
  4. Connect to the server
  5. Use the "Call Tool" tab to test the usd-to-cny tool

Testing HTTP Mode

  1. Start the HTTP server: bun run start:http
  2. Open the MCP Inspector
  3. Select the server type (HTTP with SSE)
  4. Set the SSE URL to http://localhost:3000/sse
  5. Set the Message URL to http://localhost:3000/messages
  6. Connect to the server
  7. Use the "Call Tool" tab to test the usd-to-cny tool

License

MIT