{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/eloqua/json-schema/eloqua-query-result-campaign-schema.json",
  "title": "QueryResultCampaign",
  "x-generated": "2026-11-25",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/eloqua-campaigns-api-openapi.yml#/components/schemas/QueryResultCampaign",
  "type": "object",
  "properties": {
    "elements": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Campaign"
      }
    },
    "page": {
      "type": "integer"
    },
    "pageSize": {
      "type": "integer"
    },
    "total": {
      "type": "integer"
    }
  },
  "$defs": {
    "Campaign": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "Unique identifier for the campaign",
          "readOnly": true
        },
        "name": {
          "type": "string",
          "description": "Campaign name"
        },
        "description": {
          "type": "string",
          "description": "Campaign description"
        },
        "currentStatus": {
          "type": "string",
          "enum": [
            "Active",
            "Draft",
            "Scheduled",
            "Completed"
          ],
          "description": "Current campaign status",
          "readOnly": true
        },
        "campaignCategory": {
          "type": "string",
          "enum": [
            "emailMarketing",
            "contact"
          ],
          "description": "Campaign type - emailMarketing for simple campaigns, contact for multi-step campaigns"
        },
        "startAt": {
          "type": "string",
          "description": "Campaign start date (Unix time)"
        },
        "endAt": {
          "type": "string",
          "description": "Campaign end date (Unix time)"
        },
        "memberCount": {
          "type": "integer",
          "description": "Number of members entered in the last 90 days",
          "readOnly": true
        },
        "folderId": {
          "type": "string",
          "description": "Containing folder identifier",
          "readOnly": true
        },
        "createdAt": {
          "type": "string",
          "description": "Creation timestamp (Unix time)",
          "readOnly": true
        },
        "updatedAt": {
          "type": "string",
          "description": "Last update timestamp (Unix time)",
          "readOnly": true
        },
        "createdBy": {
          "type": "string",
          "description": "User who created the campaign",
          "readOnly": true
        },
        "updatedBy": {
          "type": "string",
          "description": "User who last updated the campaign",
          "readOnly": true
        },
        "depth": {
          "type": "string",
          "description": "Level of detail returned",
          "readOnly": true
        },
        "type": {
          "type": "string",
          "description": "Asset type in Eloqua",
          "readOnly": true
        }
      }
    }
  }
}