{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/audiopod-ai/json-schema/audiopod-ai-cost-estimate-response-schema.json",
  "title": "CostEstimateResponse",
  "description": "Response with cost estimate",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/audiopod-ai-api-wallet-api-openapi.yml#/components/schemas/CostEstimateResponse",
  "properties": {
    "service_type": {
      "type": "string",
      "title": "Service Type"
    },
    "unit": {
      "type": "string",
      "title": "Unit",
      "description": "What the service is metered in: 'minute' or '1k_characters'."
    },
    "duration_seconds": {
      "type": "integer",
      "title": "Duration Seconds"
    },
    "duration_minutes": {
      "type": "number",
      "title": "Duration Minutes"
    },
    "rate_per_minute": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Rate Per Minute",
      "description": "Per-minute rate; null for per-character services."
    },
    "cost_cents": {
      "type": "integer",
      "title": "Cost Cents"
    },
    "cost_usd": {
      "type": "string",
      "title": "Cost Usd"
    },
    "description": {
      "type": "string",
      "title": "Description"
    },
    "billed_per_character": {
      "type": "boolean",
      "title": "Billed Per Character",
      "default": false
    },
    "text_length": {
      "type": "integer",
      "title": "Text Length",
      "default": 0
    },
    "estimated_characters": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Estimated Characters",
      "description": "Characters the quote was priced on (per-character services)."
    },
    "estimate_basis": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Estimate Basis",
      "description": "'characters' when priced from text_length; 'duration' when a per-character service was approximated from duration_seconds (about 900 characters per minute), or for a per-minute service."
    },
    "cents_per_1k_characters": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Cents Per 1K Characters",
      "description": "Cents per 1,000 characters; null for per-minute services."
    },
    "rate_per_1k_characters": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Rate Per 1K Characters",
      "description": "Display rate, e.g. '$0.09 / 1K chars'; null for per-minute services."
    }
  },
  "type": "object",
  "required": [
    "service_type",
    "unit",
    "duration_seconds",
    "duration_minutes",
    "cost_cents",
    "cost_usd",
    "description"
  ]
}