{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/prowlarr/json-schema/prowlarr-history-resource-paging-resource-schema.json",
  "title": "HistoryResourcePagingResource",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/prowlarr-history-api-openapi.yml#/components/schemas/HistoryResourcePagingResource",
  "type": "object",
  "properties": {
    "page": {
      "type": "integer",
      "format": "int32"
    },
    "pageSize": {
      "type": "integer",
      "format": "int32"
    },
    "sortKey": {
      "type": [
        "string",
        "null"
      ]
    },
    "sortDirection": {
      "$ref": "#/$defs/SortDirection"
    },
    "totalRecords": {
      "type": "integer",
      "format": "int32"
    },
    "records": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/HistoryResource"
      }
    }
  },
  "additionalProperties": false,
  "$defs": {
    "HistoryEventType": {
      "enum": [
        "unknown",
        "releaseGrabbed",
        "indexerQuery",
        "indexerRss",
        "indexerAuth",
        "indexerInfo"
      ],
      "type": "string"
    },
    "HistoryResource": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer",
          "format": "int32"
        },
        "indexerId": {
          "type": "integer",
          "format": "int32"
        },
        "date": {
          "type": "string",
          "format": "date-time"
        },
        "downloadId": {
          "type": [
            "string",
            "null"
          ]
        },
        "successful": {
          "type": "boolean"
        },
        "eventType": {
          "$ref": "#/$defs/HistoryEventType"
        },
        "data": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "type": [
              "string",
              "null"
            ]
          }
        }
      },
      "additionalProperties": false
    },
    "SortDirection": {
      "enum": [
        "default",
        "ascending",
        "descending"
      ],
      "type": "string"
    }
  }
}