{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/past-dev/json-schema/past-dev-recall-request-schema.json",
  "title": "RecallRequest",
  "x-generated": "2026-10-31",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/past-dev-openapi.json#/components/schemas/RecallRequest",
  "type": "object",
  "required": [
    "query",
    "identity"
  ],
  "additionalProperties": false,
  "properties": {
    "query": {
      "type": "string",
      "description": "Natural-language query."
    },
    "limit": {
      "type": "integer",
      "minimum": 1,
      "maximum": 200,
      "default": 100,
      "description": "Maximum number of documents in the page."
    },
    "level": {
      "type": "string",
      "enum": [
        "low",
        "medium",
        "high",
        "extra-high"
      ],
      "default": "low",
      "description": "The evidence budget in words: low 8,000 tokens, medium 16,000, high 24,000, extra-high 32,000. A level above the plan's ceiling is lowered to it: 8,000 on Pay as you go and Flex, 32,000 on Enterprise. Send level or maxTokens, never both."
    },
    "maxTokens": {
      "type": "integer",
      "minimum": 1,
      "description": "An explicit evidence budget in tokens, for a caller who needs a figure the levels do not offer. Estimated from document content and excerpt text only, excluding JSON structure and metadata; lowered to the plan's ceiling in the same way; whole documents are kept or omitted."
    },
    "queryTimestamp": {
      "type": "string",
      "format": "date-time",
      "description": "The perspective of the read. Evidence at or before this instant is eligible. Defaults to now."
    },
    "occurredFrom": {
      "type": "string",
      "format": "date-time",
      "description": "Inclusive start of the occurrence window."
    },
    "occurredTo": {
      "type": "string",
      "format": "date-time",
      "description": "Inclusive end of the occurrence window. A start after the end returns 400 recall-range-invalid."
    },
    "sort": {
      "type": "string",
      "enum": [
        "relevance",
        "chronological"
      ],
      "default": "relevance",
      "description": "chronological orders the selected documents oldest first and keeps each relevance rank."
    },
    "identity": {
      "type": "string",
      "maxLength": 200
    }
  }
}