Skip to content

Installation

Two lines, and it is measuring

The package runs inside your own server. It is not a proxy — your URL does not change, your OAuth does not break, and if MCPulse is down your server keeps serving.

Your server's language

TypeScript today. The rest are on the way, in the order the MCP project ships its own SDKs — and none of them is a wall: ingest is a plain HTTP POST, so any language can report today.

  1. 01

    Add the package

    No runtime dependencies at all, so it will not drag anything into your tree.

    $ npm install @mcpulse/sdk
    $ pnpm add @mcpulse/sdk
    $ yarn add @mcpulse/sdk
    $ bun add @mcpulse/sdk
  2. 02

    Put the key in your environment

    An ingest key is a secret — anyone holding it can write data into this MCP. Keep it out of the repository and out of your client bundle. You are shown the full key once, at creation, because only a hash of it is stored.

    MCPULSE_KEY=mp_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
  3. 03

    Wrap your server

    One import, one call, after your tools are registered. watch returns the same server, so nothing downstream changes.

    import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
    import { watch } from "@mcpulse/sdk";
    
    const server = new McpServer({ name: "my-server", version: "1.0.0" });
    
    // … your registerTool calls …
    
    watch(server, { key: process.env.MCPULSE_KEY });

    Serving over HTTP instead? Those servers build a new McpServer per request, so there is no long-lived instance to wrap — put it inside the factory, beside the tool registration. Calling watch once per request is expected and cheap: the session and its buffer are shared for the life of the process, which is what keeps your calls grouped into one session rather than one per request.

    function createServer() {
      const server = new McpServer({ name: "my-server", version: "1.0.0" });
    
      // … your registerTool calls …
    
      return watch(server, { key: process.env.MCPULSE_KEY });
    }
  4. 04

    Restart and check back

    On start the SDK sends one payload listing your tools and their schema sizes — that is what fills the tools table, so a server that has booted but never been called still shows what it costs per session. Tool calls follow as they happen, batched every 30 calls or 5 seconds.

    Nothing arriving? Set debug: true to log every batch to stderr, and confirm the key has not been revoked.

Options

Two, and there will not be more than there need to be. Every option is another way for something to go wrong inside a process we do not control.

Option Type Default What it does
key string Required. Without one the SDK does nothing.
debug boolean false Log every batch to stderr — never stdout, which is the transport.

Requires Node 20.12 or newer and @modelcontextprotocol/sdk as a peer — whatever version your server already uses. The package is on npm.

Coming soon

An MCPulse package for Python

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/python-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.

Coming soon

An MCPulse package for C#

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/csharp-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.

Coming soon

An MCPulse package for Go

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/go-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.

Coming soon

An MCPulse package for Rust

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/rust-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.

Coming soon

An MCPulse package for Java

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/java-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.

Coming soon

An MCPulse package for Ruby

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/ruby-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.

Coming soon

An MCPulse package for Swift

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/swift-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.

Coming soon

An MCPulse package for PHP

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/php-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.

Coming soon

An MCPulse package for Kotlin

It will wrap the official SDK, so if this is the one you are building on, the install will be the same two lines TypeScript gets.

modelcontextprotocol/kotlin-sdk

You do not have to wait to send data

Ingest is one authenticated POST with a bearer key and two payload shapes — one when your server boots, one per tool call. Any language that can make an HTTP request can report today; the package only exists to save you writing it.