JSPM

  • Created
  • Published
  • Downloads 7
  • Score
    100M100P100Q68691F
  • License MIT

MCP server for tru — auth, billing, and risk signals in one API

Package Exports

    This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (tru-mcp) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

    Readme

    tru MCP Server

    MCP server for tru — auth and billing API in one. Verify identity, charge users, issue virtual cards, and get risk signals on every user. Payments flow to your existing Stripe account.

    Quick Setup

    npx tru-mcp init

    No API key needed. This detects your MCP client (Claude Code, Claude Desktop, Cursor) and writes the config automatically. Then tell your agent:

    "Run get_started to set up tru"

    Your agent will register your app, get you an API key, connect Stripe, and discover your API — all in one conversation.

    If you already have an API key:

    npx tru-mcp init --key tru_ak_your_key_here

    Manual Config

    Add to your .mcp.json (Claude Code) or equivalent:

    {
      "mcpServers": {
        "tru": {
          "command": "npx",
          "args": ["-y", "tru-mcp"],
          "env": {
            "TRU_API_URL": "https://tru-by29.onrender.com"
          }
        }
      }
    }

    Environment Variables

    Variable Required Description
    TRU_API_KEY No Your tru API key (starts with tru_ak_). Not needed for initial setup — register_app will create one.
    TRU_API_URL No tru server URL (default: https://tru-by29.onrender.com)

    Getting Started

    The MCP tools walk you through setup step by step:

    1. get_started — Full guide: what tru is, why it matters, risk signals, setup walkthrough
    2. register_app — Create your app, get an API key
    3. connect_stripe — Link your Stripe account to receive payments

    After that, you're live. All the tools below work immediately.

    Tools

    Tool Description
    Setup
    get_started Full setup guide — what tru is, how to integrate, risk signals explained
    register_app Register a new app on tru and get an API key
    connect_stripe Link your existing Stripe account to receive payments
    discover_api Crawl your site and generate an agent skill (SKILL.md)
    Identity & Data
    check_identity Verify a user + get risk signals (level, score, card funding, country)
    request_user_data Request verified data from a user's vault (name, email, phone, address)
    check_request_status Poll the status of a credential request
    Billing
    create_charge Create a direct charge or subscription
    check_charge_status Check the status of a charge request
    request_virtual_card Issue a single-use virtual card for agent purchases
    Provisioning
    provision_user Auto-create a user account on a third-party app
    Discovery
    discover_apps Browse registered apps on the tru platform
    read_skill Read an app's agent skill guide
    initiate_oauth Start an OAuth login flow with a tru-registered app

    Why tru?

    • Risk signals from day one — every user carries a risk profile built from Stripe Radar. Use risk level, score, card funding type, country, and fingerprint reuse to set trial length, spending limits, and feature access.
    • Auth + billing in one API — stop stitching together Stripe, an identity provider, a KYC vendor, and your own spending controls.
    • Payments to your Stripe — connect via OAuth, money flows to your existing account. Same dashboard, same bank, same everything.
    • Users control spending — they set per-app rules ("auto-approve under $10"), which builds trust and increases conversion.

    Example: Developer Setup

    Developer: I want to integrate tru into my app
    
    Agent: → get_started()
           Here's how tru works...
    
    Agent: Let's register your app.
           → register_app(service_name: "my-app", display_name: "My App", owner_email: "dev@example.com")
           ✓ App created — API key: tru_ak_...
    
    Agent: Now let's connect your Stripe account.
           → connect_stripe(service_name: "my-app")
           Open this URL to authorize: https://connect.stripe.com/oauth/authorize?...
    
    Agent: You're live. Charges approved by tru users will flow to your Stripe account.

    Example: Auto-Provisioning

    User: Sign me up for clayking
    
    Agent: → check_identity(email: "user@example.com")
           ✓ Verified — risk: low
    
    Agent: → provision_user(email: "user@example.com", service_name: "clayking")
           ✓ Provisioned — got API key and account ID
    
    Agent: Now using clayking API on behalf of user...

    Example: End User Flow

    User: Sign me up for that new service
    
    Agent: → check_identity(email: "user@example.com")
           ✓ Verified — risk: low, score: 12, debit card, US
    
    Agent: → request_user_data(email: "user@example.com", fields: ["name", "email"])
           ⏳ Pending — approve on your tru dashboard
    
    Agent: → check_request_status(request_id: "req_abc123")
           ✓ Approved — got name and email
    
    Agent: → create_charge(email: "user@example.com", amount_cents: 999, description: "Monthly plan")
           ✓ Auto-approved by spending rules

    License

    MIT