Skip to main content

get_billing_info()

Get the current billing status for your tenant — plan, active agent count, limits, and billing period.
from meshai import MeshAI

client = MeshAI(api_key="msh_...")

billing = client.get_billing_info()
print(f"Plan: {billing['plan']}")
print(f"Agents: {billing['active_agents']}/{billing['agent_limit']}")
print(f"Cost: ${billing['monthly_cost_usd']}")
Returns:
{
  "plan": "professional",
  "active_agents": 47,
  "agent_limit": 100,
  "billing_period_start": "2026-03-01T00:00:00Z",
  "billing_period_end": "2026-03-31T23:59:59Z",
  "monthly_cost_usd": 799.00,
  "features": {
    "anomaly_detection": true,
    "governance_policies": "unlimited",
    "hitl_approvals": true,
    "risk_classification": true,
    "audit_trail_retention_days": 365,
    "eu_ai_act_compliance": "basic",
    "fria_support": false,
    "incident_reporting": false,
    "sso": false
  }
}

Checking Limits

Use get_billing_info() to check whether you’re approaching your agent limit before registering new agents:
billing = client.get_billing_info()
remaining = billing["agent_limit"] - billing["active_agents"]

if remaining <= 0:
    print("Agent limit reached — upgrade your plan to register more agents")
elif remaining <= 5:
    print(f"Warning: only {remaining} agent slots remaining")

Upgrade

To upgrade your plan, use the dashboard at app.meshai.dev/settings or call the checkout API endpoint directly. See Plans for available tiers and pricing.