{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/audiostack/json-schema/audiostack-analytics-usage-response-schema.json",
  "title": "AnalyticsUsageResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/audiostack-analytics-api-openapi.yml#/components/schemas/AnalyticsUsageResponse",
  "type": "object",
  "properties": {
    "metadata": {
      "type": "object",
      "properties": {
        "request_id": {
          "type": "string",
          "description": "Unique identifier for the request"
        },
        "version": {
          "type": "string",
          "description": "API version"
        },
        "credit_used": {
          "type": "number",
          "description": "Credits used for this request"
        },
        "credits_remaining": {
          "type": "number",
          "description": "Credits remaining"
        }
      }
    },
    "warnings": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "default": []
    },
    "message": {
      "type": "string",
      "description": "Success message"
    },
    "data": {
      "type": "object",
      "properties": {
        "totalUsage": {
          "type": "object",
          "properties": {
            "productionSecondsCreated": {
              "type": "number",
              "description": "Total seconds of production audio created in the date range"
            },
            "audioformsCreated": {
              "type": "integer",
              "description": "Total number of audioforms created in the date range"
            }
          }
        }
      }
    }
  },
  "required": [
    "metadata",
    "warnings",
    "message",
    "data"
  ]
}