{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/kymaapi-com/json-schema/kymaapi-com-audio-billing-schema.json",
  "title": "AudioBilling",
  "description": "Per-request billing breakdown for audio endpoints (transcription per second with a 10-second minimum; audio understanding per minute).",
  "x-generated": "2026-10-30",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/kymaapi-com-openapi.json#/components/schemas/AudioBilling",
  "type": "object",
  "properties": {
    "duration_sec": {
      "type": "number",
      "description": "Audio duration in seconds."
    },
    "billable_seconds": {
      "type": "integer",
      "description": "Only present on /audio/transcriptions responses. Seconds charged: the duration rounded up to a whole second, with a 10-second minimum per request."
    },
    "billable_minutes": {
      "type": "integer",
      "description": "Minutes charged, rounded up. On /audio/transcriptions this is `billable_seconds` in whole minutes, kept for compatibility; the charge is computed from `billable_seconds`."
    },
    "cost_usd": {
      "type": "number",
      "description": "Final cost charged for this request."
    },
    "balance_usd": {
      "type": "number",
      "description": "Remaining account balance after this charge."
    },
    "duration_source": {
      "type": "string",
      "enum": [
        "upstream_usage",
        "file_bound"
      ],
      "description": "Only present on /audio/understand responses. `upstream_usage`: billed seconds are the input the model consumed (audio and question). `file_bound`: the model reported no usage, so the file's own length bound was billed."
    }
  }
}