Command Palette

Search for a command to run...

UnylyUnyly
Browse all

Agentcat Typescript Sdk

FreeNot checked

AgentCat is an analytics platform for MCP server owners 🐱.

GitHubEmbed

About

AgentCat is an analytics platform for MCP server owners 🐱.

README

AgentCat β€” see exactly how agents experience your product

Getting Started Β· Features Β· Docs Β· Website Β· Open Source Β· Schedule a Demo

npm version npm downloads License: MIT TypeScript GitHub issues CI

[!IMPORTANT] > MCPcat is now AgentCat 🐱 β€” same team, same product, new name. This package was previously published as mcpcat, which keeps working forever, but new features land here. Upgrading takes a few minutes β€” see the migration guide.

[!NOTE] Looking for the Python SDK? Check it out here agentcat-python.

AgentCat is an analytics platform for MCP server owners 🐱. It captures user intentions and behavior patterns to help you understand what AI users actually need from your tools β€” eliminating guesswork and accelerating product development all with one-line of code.

This SDK also provides a free and simple way to forward telemetry like logs, traces, and errors to any Open Telemetry collector or popular tools like Datadog, Sentry, and PostHog.

npm install -S agentcat

To learn more about us, check us out here. For detailed guides visit our documentation.

Why use AgentCat? πŸ€”

AgentCat helps developers and product owners build, improve, and monitor their MCP servers by capturing user analytics and tracing tool calls.

Use AgentCat for:

  • User session replay 🎬. Follow alongside your users to understand why they're using your MCP servers, what functionality you're missing, and what clients they're coming from.
  • Trace debugging πŸ”. See where your users are getting stuck, track and find when LLMs get confused by your API, and debug sessions across all deployments of your MCP server.
  • Existing platform support πŸ“Š. Get logging and tracing out of the box for your existing observability platforms (OpenTelemetry, Datadog, Sentry) β€” eliminating the tedious work of implementing telemetry yourself.
AgentCat architecture β€” the AgentCat SDK inside your MCP server sends analytics to your observability vendors and session replay to the AgentCat dashboard

Getting Started

To get started with AgentCat, first create an account and obtain your project ID by signing up at agentcat.com. For detailed setup instructions visit our documentation.

Once you have your project ID, integrate AgentCat into your MCP server:

import * as agentcat from "agentcat";

const mcpServer = new Server({ name: "echo-mcp", version: "0.1.0" });

// Track the server with AgentCat
agentcat.track(mcpServer, "proj_0000000");

// Register your tools

Identifying users

You can identify your user sessions with a simple callback AgentCat exposes, called identify.

agentcat.track(mcpServer, "proj_0000000", {
  identify: async (request, extra) => {
    const user = await myapi.getUser(request.params.arguments.token);
    return {
      userId: user.id,
      userName: user.name,
      userData: { favoriteColor: user.favoriteColor },
    };
  },
});

Redacting sensitive data

AgentCat redacts all data sent to its servers and encrypts at rest, but for additional security, it offers a hook to do your own redaction on all text data returned back to our servers.

agentcat.track(mcpServer, "proj_0000000", {
  redactSensitiveInformation: async (text) => await redact(text),
  // or
  redactSensitiveInformation: (text) => redact(text),
});

For redaction decisions that need more context than a single string β€” such as which tool was called or what type of event is being published β€” use the event-level redactEvent hook. It receives the full event object and returns a modified event, or null to drop the event entirely. It may be sync or async, and can be combined with redactSensitiveInformation.

agentcat.track(mcpServer, "proj_0000000", {
  redactEvent: (event) => {
    // Drop events from tools that handle secrets entirely
    if (event.resourceName === "get_credentials") {
      return null;
    }
    // Strip response payloads from a specific tool
    if (event.resourceName === "export_report") {
      return { ...event, response: undefined };
    }
    return event;
  },
});

When both hooks are configured, redactEvent runs first and sees the raw, unredacted values; redactSensitiveInformation then runs on its output as a final string-level scrub. The system-managed fields id, sessionId, projectId, eventType, and timestamp cannot be changed by the hook, and if the hook throws, the event is dropped. The hook also applies to publishCustomEvent when called with a tracked server.

Existing Platform Support

AgentCat seamlessly integrates with your existing observability stack, providing automatic logging and tracing without the tedious setup typically required. Export telemetry data to multiple platforms simultaneously:

agentcat.track(server, "proj_0000", {
  // Project ID can optionally be "null" if you just want to forward telemetry
  exporters: {
    otlp: {
      type: "otlp",
      endpoint: "http://localhost:4318/v1/traces",
    },
    datadog: {
      type: "datadog",
      apiKey: process.env.DD_API_KEY,
      site: "datadoghq.com",
      service: "my-mcp-server",
    },
    sentry: {
      type: "sentry",
      dsn: process.env.SENTRY_DSN,
      environment: "production",
    },
    posthog: {
      type: "posthog",
      apiKey: process.env.POSTHOG_API_KEY,
      host: "https://us.i.posthog.com", // Optional: defaults to US region
    },
  },
});

Learn more about our free and open source telemetry integrations.

Internal diagnostics

To help us catch and fix broken installs, the SDK sends AgentCat a small, anonymized signal when setup or runtime errors occur β€” never your tool calls, your responses, or anything about your users. Records carry only operational metadata, such as your project ID (or an anonymous install ID when none is set). Your local ~/agentcat.log is unchanged.

Diagnostics are on by default and can be turned off completely with either:

  • track(server, projectId, { disableDiagnostics: true }), or
  • the DISABLE_DIAGNOSTICS environment variable.

Free for open source

AgentCat is free for qualified open source projects. We believe in supporting the ecosystem that makes MCP possible. If you maintain an open source MCP server, you can access our full analytics platform at no cost.

How to apply: Email [email protected] with your repository link

Already using AgentCat? We'll upgrade your account immediately.

Community Cats 🐱

Meet the cats behind AgentCat! Add your cat to our community by submitting a PR with your cat's photo in the docs/cats/ directory.

bibi zelda void

Want to add your cat? Create a PR adding your cat's photo to docs/cats/ and update this section!

from github.com/agentcathq/agentcat-typescript-sdk

Installing Agentcat Typescript Sdk

This server has no published package β€” it is built from source. Open the repository and follow its README.

β–Έ github.com/agentcathq/agentcat-typescript-sdk

FAQ

Is Agentcat Typescript Sdk MCP free?

Yes, Agentcat Typescript Sdk MCP is free β€” one-click install via Unyly at no cost.

Does Agentcat Typescript Sdk need an API key?

No, Agentcat Typescript Sdk runs without API keys or environment variables.

Is Agentcat Typescript Sdk hosted or self-hosted?

Self-hosted: the server runs locally on your machine via the install command above.

How do I install Agentcat Typescript Sdk in Claude Desktop, Claude Code or Cursor?

Open Agentcat Typescript Sdk on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install β€” the config is generated automatically, no JSON editing.

Related MCPs

Compare Agentcat Typescript Sdk with

Not sure what to pick?

Find your stack in 60 seconds

Author?

Embed badge for your README

Browse similar

All ai MCPs