Skip to main content
GET
/
billing
/
usage-logs
curl "https://api.60db.ai/billing/usage-logs?limit=10&service_type=TTS" \
  -H "Authorization: Bearer your-api-key"
{
  "success": true,
  "message": "Usage logs fetched successfully",
  "data": {
    "logs": [
      {
        "hash_id": "84ffd09e-f5a4-42ea-a8fc-f50038392652",
        "service_type": "TTS",
        "amount_deducted": "0.00024000",
        "units_used": "12",
        "previous_balance": "9.50024000",
        "new_balance": "9.50000000",
        "metadata": {},
        "created_at": "2026-04-13T12:30:00.000Z",
        "user_name": "Kapil Karda",
        "user_email": "[email protected]"
      },
      {
        "hash_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
        "service_type": "LLM",
        "amount_deducted": "0.00150000",
        "units_used": "1500",
        "previous_balance": "9.50174000",
        "new_balance": "9.50024000",
        "metadata": {},
        "created_at": "2026-04-13T12:25:00.000Z",
        "user_name": "Kapil Karda",
        "user_email": "[email protected]"
      }
    ],
    "pagination": {
      "current_page": 1,
      "per_page": 10,
      "total_records": 42,
      "total_pages": 5
    },
    "summary": [
      { "service_type": "TTS", "count": 15, "total_cost": 0.0036, "total_units": 180 },
      { "service_type": "LLM", "count": 20, "total_cost": 0.03, "total_units": 30000 },
      { "service_type": "MEMORY_INGEST", "count": 7, "total_cost": 0.0007, "total_units": 7000 }
    ]
  }
}

Request

Headers

Authorization
string
required
Bearer token (JWT or API key)

Query Parameters

page
number
default:"1"
Page number for pagination
limit
number
default:"20"
Items per page (max 100)
service_type
string
Filter by service type. Options: TTS, STT, LLM, MEMORY_INGEST, MEMORY_EXTRACT, MEMORY_RECALL, MEMORY_CONTEXT

Response

data.logs
array
Array of transaction log entries
data.logs[].hash_id
string
Unique transaction ID (UUID)
data.logs[].service_type
string
Service that was charged (TTS, STT, LLM, MEMORY_INGEST, etc.)
data.logs[].amount_deducted
number
USD amount deducted (negative values indicate refunds)
data.logs[].units_used
number
Units consumed (characters for TTS, minutes for STT, tokens for LLM, bytes/queries for Memory)
data.logs[].previous_balance
number
Workspace balance before this operation
data.logs[].new_balance
number
Workspace balance after this operation
data.logs[].user_name
string
Name of the user who performed the operation
data.logs[].created_at
string
ISO 8601 timestamp
data.summary
array
Aggregated totals grouped by service type
Only the workspace owner can view usage logs. This endpoint is protected by billing:manage permission. Every API operation (TTS, STT, LLM, Memory) that costs money is logged here — this is your complete billing audit trail.
curl "https://api.60db.ai/billing/usage-logs?limit=10&service_type=TTS" \
  -H "Authorization: Bearer your-api-key"
{
  "success": true,
  "message": "Usage logs fetched successfully",
  "data": {
    "logs": [
      {
        "hash_id": "84ffd09e-f5a4-42ea-a8fc-f50038392652",
        "service_type": "TTS",
        "amount_deducted": "0.00024000",
        "units_used": "12",
        "previous_balance": "9.50024000",
        "new_balance": "9.50000000",
        "metadata": {},
        "created_at": "2026-04-13T12:30:00.000Z",
        "user_name": "Kapil Karda",
        "user_email": "[email protected]"
      },
      {
        "hash_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
        "service_type": "LLM",
        "amount_deducted": "0.00150000",
        "units_used": "1500",
        "previous_balance": "9.50174000",
        "new_balance": "9.50024000",
        "metadata": {},
        "created_at": "2026-04-13T12:25:00.000Z",
        "user_name": "Kapil Karda",
        "user_email": "[email protected]"
      }
    ],
    "pagination": {
      "current_page": 1,
      "per_page": 10,
      "total_records": 42,
      "total_pages": 5
    },
    "summary": [
      { "service_type": "TTS", "count": 15, "total_cost": 0.0036, "total_units": 180 },
      { "service_type": "LLM", "count": 20, "total_cost": 0.03, "total_units": 30000 },
      { "service_type": "MEMORY_INGEST", "count": 7, "total_cost": 0.0007, "total_units": 7000 }
    ]
  }
}