{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/immix/json-schema/immix-algos-list-versions-algos-response-schema.json",
  "title": "ListVersionsAlgosResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/immix-algos-api-openapi.yml#/components/schemas/algos_ListVersionsAlgosResponse",
  "type": "object",
  "properties": {
    "nextCursor": {
      "type": [
        "string",
        "null"
      ],
      "description": "Pass as `cursor` for the next page. Null on the last page."
    },
    "prevCursor": {
      "type": [
        "string",
        "null"
      ],
      "description": "Pass as `cursor` for the previous page. Null on the first page."
    },
    "total": {
      "type": [
        "integer",
        "null"
      ],
      "description": "Exact count matching the filter. Null unless `include=total`."
    },
    "globalSequence": {
      "$ref": "#/$defs/GlobalSequenceValue"
    },
    "asOfSeqTsNs": {
      "type": [
        "string",
        "null"
      ],
      "pattern": "^[0-9]+$",
      "description": "The sequencer timestamp (epoch-ns) the data is complete through; also sent as X-Immix-As-Of-Seq-Ts. Null when unknown."
    },
    "items": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/AlgoVersionLoaded"
      }
    }
  },
  "required": [
    "nextCursor",
    "prevCursor",
    "total",
    "globalSequence",
    "asOfSeqTsNs",
    "items"
  ],
  "$defs": {
    "AlgoVersionLoaded": {
      "type": "object",
      "properties": {
        "algoVersionId": {
          "type": "integer",
          "description": "The catalog row's id — the value an instance pins; 0 in the empty report, which names no row."
        },
        "reportSeq": {
          "type": "integer",
          "description": "The report this entry belongs to, per pool, from 1 (ReportAlgoVersions carries the floor): 0 is the algo-versions fold's no-report sentinel, and an entry numbered 0 folds nothing."
        },
        "entryIndex": {
          "type": "integer",
          "description": "This entry's position in the report, from 0."
        },
        "entryCount": {
          "type": "integer",
          "description": "How many entries the report has; 0 is the empty report, whose one entry (index 0) replaces the pool's set with nothing."
        },
        "apiVersionMajor": {
          "type": "integer",
          "description": "The algo api major version the pool runs."
        },
        "apiVersionMinor": {
          "type": "integer",
          "description": "The algo api minor version the pool runs."
        },
        "stateSchemaVersion": {
          "type": "integer",
          "description": "The artifact's declared state schema version."
        },
        "loadedAtNs": {
          "type": "string",
          "pattern": "^-?[0-9]+$",
          "description": "When this entry was recorded, epoch nanoseconds. int64 as a decimal JSON string"
        },
        "digest": {
          "type": "string",
          "pattern": "^[0-9a-f]{64}$",
          "minLength": 64,
          "maxLength": 64,
          "description": "SHA-256 over the artifact's jar bytes, 32 bytes. 32 bytes as 64 lowercase hex characters"
        },
        "pool": {
          "type": "string",
          "description": "The pool that loaded it, by name."
        },
        "algoName": {
          "type": "string",
          "description": "The artifact's name."
        },
        "artifactVersion": {
          "type": "string",
          "description": "The artifact's semantic version."
        },
        "paramsSchema": {
          "type": "string",
          "description": "The artifact's params schema, verbatim JSON."
        }
      },
      "required": [
        "algoVersionId",
        "reportSeq",
        "entryIndex",
        "entryCount",
        "apiVersionMajor",
        "apiVersionMinor",
        "stateSchemaVersion",
        "loadedAtNs",
        "digest",
        "pool",
        "algoName",
        "artifactVersion",
        "paramsSchema"
      ],
      "title": "AlgoVersionLoaded"
    },
    "GlobalSequenceValue": {
      "type": "string",
      "pattern": "^[0-9]+$",
      "description": "The position as a decimal string — the last change this member had applied, orders, balance readings and algo instances included.",
      "title": "GlobalSequenceValue"
    }
  }
}