{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/openrush-com/json-schema/openrush-com-ad-performance-request-schema.json",
  "title": "AdPerformanceRequest",
  "description": "get_ad_performance (§13.1). The single, platform-normalized ad-performance\ntool. `platform` is optional (inferred when one ad platform is connected; a\ntyped `platform_required` recovery lists options when several are). `ad_account`\nis the selector: an OPAQUE OpenRush id (never a raw customer id) — single-account\ncallers omit it and it is inferred, multiple activated accounts return\n`account_required` with the accounts listed by name so the agent can pick one.\n`report`/`group_by`/period/compare_to are validated in the service so the\ntyped-400 error taxonomy stays uniform.",
  "x-generated": "2026-11-20",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/openrush-com-openapi.json#/components/schemas/AdPerformanceRequest",
  "properties": {
    "platform": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 40
        },
        {
          "type": "null"
        }
      ],
      "title": "Platform"
    },
    "ad_account": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 64
        },
        {
          "type": "null"
        }
      ],
      "title": "Ad Account"
    },
    "period": {
      "type": "string",
      "title": "Period",
      "default": "last_28_days"
    },
    "compare_to": {
      "type": "string",
      "title": "Compare To",
      "default": "previous_period"
    },
    "report": {
      "type": "string",
      "title": "Report",
      "default": "overview"
    },
    "group_by": {
      "items": {
        "type": "string"
      },
      "type": "array",
      "maxItems": 2,
      "title": "Group By"
    },
    "filters": {
      "items": {
        "additionalProperties": true,
        "type": "object"
      },
      "type": "array",
      "maxItems": 10,
      "title": "Filters"
    },
    "limit": {
      "type": "integer",
      "maximum": 1000.0,
      "minimum": 1.0,
      "title": "Limit",
      "default": 100
    },
    "complete_days_only": {
      "type": "boolean",
      "title": "Complete Days Only",
      "default": false
    }
  },
  "type": "object"
}