Skip to main content
Glama
@margint-ai/mcp

@margint-ai/mcp

Official
by margint-ai

@margint-ai/mcp

Query your Margint per-customer AI margin from Claude Desktop, Cursor, or any MCP client.

Ask the LLM "which customers are losing me money this month?" and have it pull the answer from your Margint workspace. Read-only, scoped to a single API key.

Install

Add to your MCP client config (Claude Desktop example, ~/Library/Application Support/Claude/claude_desktop_config.json):

{
    "mcpServers": {
        "margint": {
            "command": "npx",
            "args": ["-y", "@margint-ai/mcp"],
            "env": {
                "MARGINT_API_KEY": "m_live_..."
            }
        }
    }
}

For Cursor: same JSON, in Settings → Features → MCP.

Get a key at app.margint.dev → Settings → API Keys.

Related MCP server: agent-budget

Tools exposed

Tool

What it does

margint_list_customers

List tracked customers with margin, revenue, cost

margint_get_customer

Drill into one customer's costs by feature/model

margint_cost_overview

Workspace-wide totals + breakdowns by provider/model/feature

margint_check_budget

Check whether a customer is at/over their monthly budget

All tools accept a range parameter (7d, 30d, 90d — default 30d).

Configuration

Env var

Default

Notes

MARGINT_API_KEY

required

Your workspace API key

MARGINT_BASE_URL

https://app.margint.dev

Override for self-hosted Margint

Privacy

The MCP server only forwards your prompts to Margint's read API — it never reads your LLM call payloads. The API key scopes access to a single workspace.


MIT licensed. © Margint. Questions: hi@margint.dev.

Available Tools

4 tools
margint_check_budgetA

Check whether a customer is still within their configured monthly budgets. Agents can call this before making an LLM call to self-gate. Returns { allowed: true | false } with any warnings or breaches. Cached 60s server-side.

Inputs: customer (required), feature.

margint_cost_overviewA

Aggregate cost, revenue, and margin across the whole workspace over a rolling window. Returns totals, per-day sparks, and the count of unprofitable customers. Use this for "how are we doing this week?" questions.

Inputs: range.

margint_get_customerA

Get detailed cost, revenue, margin, and recent events for a single customer by your external ID (the one you pass to the SDK as customerId). Includes per-feature cost breakdown and up to 50 recent cost events.

Inputs: externalId (required), range.

margint_list_customersA

List tracked customers with AI cost, MRR, and margin over a rolling window. Returns at most 100 rows, sorted worst-margin first. Use this to answer questions like "which customers are losing me money?" Optional feature filter narrows the cost calculation to specific features.

Inputs: range, features.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.4/5.0

    Scored across 4 tools

    Disambiguation5/5

    Each tool serves a distinct purpose: budget check for self-gating, cost overview for aggregate metrics, get customer for detailed per-customer data, and list customers for overview of all customers. No overlap in functionality.

    Naming Consistency5/5

    All tools follow a consistent pattern: 'margint_' prefix followed by a verb_noun in snake_case (e.g., check_budget, cost_overview). The naming is uniform and predictable.

    Tool Count5/5

    With 4 tools, the set is well-scoped for a cost monitoring server. It covers essential operations without unnecessary complexity.

    Completeness5/5

    The tools provide comprehensive read-only coverage for budget and cost monitoring: budget check, aggregate overview, per-customer details, and customer listing. No gaps for the intended use case.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    • Read-only AI/LLM cost tools with current MCP discovery and attributable Registry transport.

    • Veqen brings together work and coding agent costs per person and team, product inference costs per customer, agent spending, protection incidents, invoice checks, chargeback and the month-end close. Ask your assistant to investigate recorded spending, compare model prices, review provider keys and incidents, record bills and credits, or manage budgets, alerts, teams and spending policies. Your account role and plan govern access. Provider-key shut-off and agent-card controls require the appropriate role and provider permissions. Destructive actions require confirmation, and organizations can require a second person to approve a shut-off. SDK budget blocking is not a guaranteed spending cap. Work and coding agents are free for up to 3 people; product inference is free up to $1,000 in monthly AI spend. Connect your Veqen account for private organization data. The separate public model-price server needs no account. Estimates remain separate from provider invoices. Setup and permissions: https://veqen-app.com/docs/mcp

      https://veqen-app.com/mcp
    • Veqen brings together work and coding agent costs per person and team, product inference costs per customer, agent spending, protection incidents, invoice checks, chargeback and the month-end close. Ask your assistant to investigate recorded spending, compare model prices, review provider keys and incidents, record bills and credits, or manage budgets, alerts, teams and spending policies. Your account role and plan govern access. Provider-key shut-off and agent-card controls require the appropriate role and provider permissions. Destructive actions require confirmation, and organizations can require a second person to approve a shut-off. SDK budget blocking is not a guaranteed spending cap. Work and coding agents are free for up to 3 people; product inference is free up to $1,000 in monthly AI spend. Connect your Veqen account for private organization data. The separate public model-price server needs no account. Estimates remain separate from provider invoices. Setup and permissions: https://veqen-app.com/docs/mcp

      https://veqen-app.com/mcp
    • FinOps assistant: query AWS, GCP and Azure cost, commitments, budgets and reports.

      https://mcp.nops.io

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      Budget management and cost tracking MCP server for autonomous agents, enabling budget creation, cost recording, spending projections, and alert rules.
      MIT
    • F
      license
      Not graded
      quality
      A
      maintenance
      Enables users to analyze AWS cloud costs, audit for wasted resources like stopped EC2 instances and unattached EBS volumes, and check budget status through natural language in any MCP-compatible AI assistant. Supports multi-profile and multi-region querying while keeping AWS credentials local to the user's machine.
      -
    • F
      license
      Not graded
      quality
      A
      maintenance
      Enables users to query AWS cloud costs, run waste and savings audits, and check budget status in natural language across multiple accounts, profiles, and regions. Runs locally using existing AWS CLI credentials, keeping them on the user's machine while connecting to MCP-compatible AI clients.
      -