For the complete documentation index, see llms.txt. This page is also available as Markdown.

Billing

Subscription, tiers, and credits. Requires master key.

Show billing info

get

Returns current subscription and billing details. Requires a master key.

Authorizations
AuthorizationstringRequired

API key sent as Bearer token. Two types:

  • Master key (g_master_...): full access to all agents and endpoints.
  • Agent key (g_agent_...): scoped to a single agent with specific permissions.
Responses
200

Billing details

application/json
successbooleanOptional
get/billing
GET /api/v1/billing HTTP/1.1
Host: api.guayaba.run
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "success": true,
  "data": {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "user_id": "123e4567-e89b-12d3-a456-426614174000",
    "tier_slug": "pro",
    "status": "active",
    "stripe_subscription_id": "text",
    "stripe_customer_id": "text",
    "started_at": "2026-01-01T00:00:00.000Z",
    "monthly_credits": 1,
    "current_period_start": "2026-01-01T00:00:00.000Z",
    "current_period_end": "2026-01-01T00:00:00.000Z",
    "trial_start": "2026-01-01T00:00:00.000Z",
    "trial_end": "2026-01-01T00:00:00.000Z",
    "cancel_at_period_end": true,
    "cancel_at": "2026-01-01T00:00:00.000Z",
    "created_at": "2026-01-01T00:00:00.000Z",
    "updated_at": "2026-01-01T00:00:00.000Z",
    "tier": {
      "id": "123e4567-e89b-12d3-a456-426614174000",
      "slug": "pro",
      "name": "Pro",
      "monthly_credits": 1,
      "price": 1,
      "features": [
        "text"
      ],
      "max_running_agents": 1,
      "allowed_channels": [
        "text"
      ],
      "can_buy_credit_packages": true,
      "trial_days": 1,
      "is_active": true,
      "sort_order": 1
    }
  }
}

List subscription tiers

get

Returns available subscription tiers and pricing. Requires a master key.

Authorizations
AuthorizationstringRequired

API key sent as Bearer token. Two types:

  • Master key (g_master_...): full access to all agents and endpoints.
  • Agent key (g_agent_...): scoped to a single agent with specific permissions.
Responses
200

Subscription tiers

application/json
successbooleanOptional
get/billing/tiers
GET /api/v1/billing/tiers HTTP/1.1
Host: api.guayaba.run
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "success": true,
  "data": [
    {
      "id": "123e4567-e89b-12d3-a456-426614174000",
      "slug": "pro",
      "name": "Pro",
      "monthly_credits": 1,
      "price": 1,
      "features": [
        "text"
      ],
      "max_running_agents": 1,
      "allowed_channels": [
        "text"
      ],
      "can_buy_credit_packages": true,
      "trial_days": 1,
      "is_active": true,
      "sort_order": 1
    }
  ]
}

Get credits breakdown

get

Returns detailed credits breakdown (subscription vs purchased). Requires a master key.

Authorizations
AuthorizationstringRequired

API key sent as Bearer token. Two types:

  • Master key (g_master_...): full access to all agents and endpoints.
  • Agent key (g_agent_...): scoped to a single agent with specific permissions.
Responses
200

Credits breakdown

application/json
successbooleanOptional
get/billing/credits
GET /api/v1/billing/credits HTTP/1.1
Host: api.guayaba.run
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "success": true,
  "data": {
    "total_credits": 1,
    "subscription_credits": 1,
    "purchased_credits": 1
  }
}

Last updated