---
title: "Open-source billing for products agents can use"
canonical: https://tansohq.com/product/agent-monetization
description: "Make your product work for customers' AI agents across web, onboarding, and monetization. Try the demo, request an evaluation, or explore tanso-oss."
---

# Open-source billing for products agents can use

tanso-oss supports the monetization part of making products work for customers' agents. Connect plans, usage, credits, and access in a self-hosted system.

Available now as open-source software. Your team operates the instance and pays its hosting and connected-provider costs. Evaluations for your own product are by request.

## Capabilities

- Features, plans, subscriptions, and flat, usage-based, or graduated pricing.
- Usage metering and prepaid credit balances, grants, deductions, and transaction history.
- Entitlement checks and scoped interfaces for authorized operations.
- Optional Stripe integration. Review documented billing modes and payment setup before connecting an existing system.
- Optional MCP server for supported operations, with explicit confirmation for actions that spend money.

## Integration boundary

Your application owns its customer workflow, authorization policy, and connection to the underlying service. A billing integration does not automatically make every flow agent-compatible.

Billing API and MCP endpoints run on a self-hosted instance, not on tansohq.com. This website does not issue billing credentials, host a billing MCP server, create paid subscriptions, or process agent payments.

Your team manages instance credentials, deployment, backups, and updates. Do not send private source code or API keys through the evaluation request form.

## Quickstart (Docker is the only prerequisite)

    git clone https://github.com/tansohq/tanso-oss.git
    cd tanso-oss/deploy
    cp .env.example .env     # set JWT_SECRET
    docker compose up -d --build
    ./setup.sh               # seeds a test account, prints credentials

- [Full walkthrough](https://tanso.mintlify.app/quickstart): step-by-step self-host guide

## Core model

Feature -> Plan -> Rule (pricing: flat, usage, graduated; optional credit backing) -> Customer (keyed by your IDs) -> Subscription -> Events (idempotent, cost-stamped) -> Entitlements (fail-closed) -> Invoices (Stripe-synced or settled via mark-paid).

Credit pricing has two server-side controls, both versioned and effective-dated. A weight tariff sets how many credits one usage unit burns, per feature and model. A price book sets what one credit costs the buyer, per denomination. Entitlement checks return a credit quote with estimated credits and, when priced, estimated cost.

## Integration loop

1. Check an entitlement before serving a request.
2. Serve the request.
3. Report a usage event after.

- [Billing lifecycle walkthrough](https://tanso.mintlify.app/billing-lifecycle): the loop in detail

## For agents integrating a self-hosted instance

A self-hosted instance can expose an MCP server at /mcp (off by default, enabled by the operator in config). It uses the same API-key auth and account scoping as the REST API, with no separate, weaker path for agents. Tools that spend money require an explicit confirmAction argument.

- [MCP setup and tool catalog](https://tanso.mintlify.app/mcp.md)
- [Agent integration guide](https://tansohq.com/AGENTS.md): REST loop + MCP config
- [Agent auth guide](https://tansohq.com/docs/agent-auth.md): API keys, idempotency
- [MCP tool reference](https://tansohq.com/api/llms.txt)
- [Integration skill](https://tansohq.com/skill.md)

## For your customers' agents

A tanso-oss-powered product can serve its end customers' buying agents, opt-in per account:

- Machine-readable pricing at /public/v1/catalog/{slug}/pricing.json. One GET, no auth, no key.
- Programmatic signup: POST /public/v1/catalog/{slug}/signup returns a customer, a free-plan subscription, and a customer-scoped API key in one call. No CAPTCHA, no email loop.
- Customer-scoped keys (ck_...) pinned to one customer with read/purchase scopes; deny-by-default everywhere else.
- Payments without a browser: SetupIntent pre-authorization, off-session subscribe and credit top-ups; HTTP 402 + pollable checkout session when no card is on file; per-account agent spend caps.
- Burndown API: per-feature projections and credit depletion dates; stable error codes; Idempotency-Key replay on mutating requests.

## Start with the documentation

- [Repository and setup](https://github.com/tansohq/tanso-oss)
- [Quickstart](https://tanso.mintlify.app/quickstart)
- [MCP documentation](https://tanso.mintlify.app/mcp)
- [Agent integration guide](https://tansohq.com/docs/agent-auth.md)
- [Tanso overview](https://tansohq.com/index.md)
- [Interactive demo](https://tansohq.com/#demo)
- [Request an evaluation](https://tansohq.com/#request-access)
