Skip to main content
Glama

AgentBill

Биллинг использования для AI-агентов. Предварительная проверка. Лимит на каждый запрос. Без Stripe.


Stripe показывает, сколько вы потратили. Слишком поздно. AgentBill блокирует запуск до его начала, если бюджет исчерпан.

"В тот момент, когда вы используете Stripe в качестве своей системы безопасности, вы уже проиграли запуск." — scarlett1908, r/LangChain


Установка

pip install agentbill-sdk

Related MCP server: agent-budget

Быстрый старт

from agentbill import AgentBillClient

client = AgentBillClient(api_key="agb_your_key")

check = client.preflight(agent_id="researcher", budget=5.00) if not check.approved: raise Exception("Бюджет превышен")

client.record(agent_id="researcher", cost=check.estimated_cost)

Получите свой API-ключ: https://agentbill.fly.dev/register


Что он делает

Предварительная проверка (Preflight). Перед запуском агента AgentBill проверяет: достаточно ли у клиента бюджета? Если нет, блокирует запуск до того, как будут потреблены вычислительные ресурсы.

Лимит на каждый запрос. Ежемесячные лимиты не защищают от неудачного одиночного запуска. Один 3-часовой цикл исследования может исчерпать ваш бюджет до того, как сработает лимит. AgentBill обеспечивает соблюдение лимита на уровне вызова.

Тарификация на основе результатов. Вы сами определяете, что считается оплачиваемым событием. Не байты, не секунды. А бизнес-действие, которое выполнил агент.


Бесплатный тариф

1 000 вызовов preflight в месяц. Кредитная карта не требуется.


Чего он НЕ делает

  • Многошаговые рабочие процессы с конечными автоматами или логикой отмены (вне области применения)

  • Замена вашего платежного процессора (AgentBill находится перед ним)

  • No-code дашборд для не-разработчиков


Node.js

npm install agentbill


Почему не Stripe

Stripe

AgentBill

Блокировка перед запуском: Нет

Да

Лимит на запрос: Нет

Да

Блокировка до вычислений: Нет

Да

Создан для агентов: Нет

Да


MCP-сервер

AgentBill поставляется с MCP-сервером для нативной интеграции с Claude Code, Cursor, Windsurf и любым хостом агентов, совместимым с MCP.

Установите через agentbill-mcp на PyPI:

uvx agentbill-mcp

MCP-сервер предоставляет два инструмента:

  • preflight(agent_id, customer_id, estimated_units, ceiling) — проверка бюджета перед запуском. Блокирует, если средства исчерпаны.

  • record_event(agent_id, units, customer_id, metadata) — биллинг после завершения работы.

Настройте в ~/.claude/settings.json:

{
  "mcpServers": {
    "agentbill": {
      "command": "uvx",
      "args": ["agentbill-mcp"],
      "env": { "AGENTBILL_API_KEY": "sk_live_..." }
    }
  }
}

Исходный код: mcp/ | PyPI: agentbill-mcp | Реестр MCP: io.github.marketinglior-pixel/agentbill-mcp


Поставьте звезду этому репозиторию

Если вам нужны были лимиты на каждый запрос, поставьте звезду. Это поможет другим разработчикам найти проект.

Tool Schema Changelog

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

Loading tool schema changelog…

    Related MCP Connectors

    • MCP server for your apps' tools and custom tools, plus hosted AI agents and approval-gated workflows

      https://mcp.flowra.dev/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
    • 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
    • Hosted MCP server for LLM cost estimation, model comparison, and budget-aware routing.

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      MCP server for AgentPay — the payment gateway for autonomous AI agents. Fund a wallet once, give your agent the key, and it discovers, provisions, and pays for tool APIs on its own. One key, every tool.
      112 npm
      1
      MIT
    • 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
    • A
      license
      A
      quality
      C
      maintenance
      MCP server that enables AI agents to request human approval before spending money, check approval status, verify signed tokens, and manage API keys.
      9
      11 npm
      MIT