{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/azure-ai-search/json-schema/azure-ai-search-search-indexer-status-schema.json",
  "title": "SearchIndexerStatus",
  "description": "Represents the current status and execution history of an indexer.",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/azure-ai-search-indexers-indexername-api-openapi.yml#/components/schemas/SearchIndexerStatus",
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "The name of the indexer.",
      "readOnly": true
    },
    "status": {
      "$ref": "#/$defs/IndexerStatus",
      "description": "Overall indexer status.",
      "readOnly": true
    },
    "runtime": {
      "$ref": "#/$defs/IndexerRuntime",
      "description": "Snapshot of the indexer's cumulative runtime consumption for the service over the current UTC period.",
      "readOnly": true
    },
    "lastResult": {
      "$ref": "#/$defs/IndexerExecutionResult",
      "description": "The result of the most recent or an in-progress indexer execution.",
      "readOnly": true
    },
    "executionHistory": {
      "type": "array",
      "description": "History of the recent indexer executions, sorted in reverse chronological order.",
      "items": {
        "$ref": "#/$defs/IndexerExecutionResult"
      },
      "readOnly": true
    },
    "limits": {
      "$ref": "#/$defs/SearchIndexerLimits",
      "description": "The execution limits for the indexer.",
      "readOnly": true
    }
  },
  "required": [
    "name",
    "status",
    "executionHistory",
    "limits"
  ],
  "$defs": {
    "IndexerExecutionResult": {
      "type": "object",
      "description": "Represents the result of an individual indexer execution.",
      "properties": {
        "status": {
          "$ref": "#/$defs/IndexerExecutionStatus",
          "description": "The outcome of this indexer execution.",
          "readOnly": true
        },
        "errorMessage": {
          "type": "string",
          "description": "The error message indicating the top-level error, if any.",
          "readOnly": true
        },
        "startTime": {
          "type": "string",
          "format": "date-time",
          "description": "The start time of this indexer execution.",
          "readOnly": true
        },
        "endTime": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time",
          "description": "The end time of this indexer execution, if the execution has already completed.",
          "readOnly": true
        },
        "errors": {
          "type": "array",
          "description": "The item-level indexing errors.",
          "items": {
            "$ref": "#/$defs/SearchIndexerError"
          },
          "readOnly": true
        },
        "warnings": {
          "type": "array",
          "description": "The item-level indexing warnings.",
          "items": {
            "$ref": "#/$defs/SearchIndexerWarning"
          },
          "readOnly": true
        },
        "itemsProcessed": {
          "type": "integer",
          "format": "int32",
          "description": "The number of items that were processed during this indexer execution. This includes both successfully processed items and items where indexing was attempted but failed.",
          "readOnly": true
        },
        "itemsFailed": {
          "type": "integer",
          "format": "int32",
          "description": "The number of items that failed to be indexed during this indexer execution.",
          "readOnly": true
        },
        "initialTrackingState": {
          "type": "string",
          "description": "Change tracking state with which an indexer execution started.",
          "readOnly": true
        },
        "finalTrackingState": {
          "type": "string",
          "description": "Change tracking state with which an indexer execution finished.",
          "readOnly": true
        }
      },
      "required": [
        "status",
        "errors",
        "warnings",
        "itemsProcessed",
        "itemsFailed"
      ]
    },
    "IndexerExecutionStatus": {
      "type": "string",
      "description": "Represents the status of an individual indexer execution.",
      "enum": [
        "transientFailure",
        "success",
        "inProgress",
        "reset"
      ],
      "x-ms-enum": {
        "name": "IndexerExecutionStatus",
        "modelAsString": false,
        "values": [
          {
            "name": "TransientFailure",
            "value": "transientFailure",
            "description": "An indexer invocation has failed, but the failure may be transient. Indexer invocations will continue per schedule."
          },
          {
            "name": "Success",
            "value": "success",
            "description": "Indexer execution completed successfully."
          },
          {
            "name": "InProgress",
            "value": "inProgress",
            "description": "Indexer execution is in progress."
          },
          {
            "name": "Reset",
            "value": "reset",
            "description": "Indexer has been reset."
          }
        ]
      }
    },
    "IndexerRuntime": {
      "type": "object",
      "description": "Represents the indexer's cumulative runtime consumption in the service.",
      "properties": {
        "usedSeconds": {
          "type": "integer",
          "format": "int64",
          "description": "Cumulative runtime of the indexer from the beginningTime to endingTime, in seconds."
        },
        "remainingSeconds": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64",
          "description": "Cumulative runtime remaining for all indexers in the service from the beginningTime to endingTime, in seconds."
        },
        "beginningTime": {
          "type": "string",
          "format": "date-time",
          "description": "Beginning UTC time of the 24-hour period considered for indexer runtime usage (inclusive)."
        },
        "endingTime": {
          "type": "string",
          "format": "date-time",
          "description": "End UTC time of the 24-hour period considered for indexer runtime usage (inclusive)."
        }
      },
      "required": [
        "usedSeconds",
        "beginningTime",
        "endingTime"
      ]
    },
    "IndexerStatus": {
      "type": "string",
      "description": "Represents the overall indexer status.",
      "enum": [
        "unknown",
        "error",
        "running"
      ],
      "x-ms-enum": {
        "name": "IndexerStatus",
        "modelAsString": false,
        "values": [
          {
            "name": "Unknown",
            "value": "unknown",
            "description": "Indicates that the indexer is in an unknown state."
          },
          {
            "name": "Error",
            "value": "error",
            "description": "Indicates that the indexer experienced an error that cannot be corrected without human intervention."
          },
          {
            "name": "Running",
            "value": "running",
            "description": "Indicates that the indexer is running normally."
          }
        ]
      }
    },
    "SearchIndexerError": {
      "type": "object",
      "description": "Represents an item- or document-level indexing error.",
      "properties": {
        "key": {
          "type": "string",
          "description": "The key of the item for which indexing failed.",
          "readOnly": true
        },
        "errorMessage": {
          "type": "string",
          "description": "The message describing the error that occurred while processing the item.",
          "readOnly": true
        },
        "statusCode": {
          "type": "integer",
          "format": "int32",
          "description": "The status code indicating why the indexing operation failed. Possible values include: 400 for a malformed input document, 404 for document not found, 409 for a version conflict, 422 when the index is temporarily unavailable, or 503 for when the service is too busy.",
          "readOnly": true
        },
        "name": {
          "type": "string",
          "description": "The name of the source at which the error originated. For example, this could refer to a particular skill in the attached skillset. This may not be always available.",
          "readOnly": true
        },
        "details": {
          "type": "string",
          "description": "Additional, verbose details about the error to assist in debugging the indexer. This may not be always available.",
          "readOnly": true
        },
        "documentationLink": {
          "type": "string",
          "description": "A link to a troubleshooting guide for these classes of errors. This may not be always available.",
          "readOnly": true
        }
      },
      "required": [
        "errorMessage",
        "statusCode"
      ]
    },
    "SearchIndexerLimits": {
      "type": "object",
      "description": "Represents the limits that can be applied to an indexer.",
      "properties": {
        "maxRunTime": {
          "type": "string",
          "format": "duration",
          "description": "The maximum duration that the indexer is permitted to run for one execution.",
          "readOnly": true
        },
        "maxDocumentExtractionSize": {
          "type": "integer",
          "format": "int64",
          "description": "The maximum size of a document, in bytes, which will be considered valid for indexing.",
          "readOnly": true
        },
        "maxDocumentContentCharactersToExtract": {
          "type": "integer",
          "format": "int64",
          "description": "The maximum number of characters that will be extracted from a document picked up for indexing.",
          "readOnly": true
        }
      }
    },
    "SearchIndexerWarning": {
      "type": "object",
      "description": "Represents an item-level warning.",
      "properties": {
        "key": {
          "type": "string",
          "description": "The key of the item which generated a warning.",
          "readOnly": true
        },
        "message": {
          "type": "string",
          "description": "The message describing the warning that occurred while processing the item.",
          "readOnly": true
        },
        "name": {
          "type": "string",
          "description": "The name of the source at which the warning originated. For example, this could refer to a particular skill in the attached skillset. This may not be always available.",
          "readOnly": true
        },
        "details": {
          "type": "string",
          "description": "Additional, verbose details about the warning to assist in debugging the indexer. This may not be always available.",
          "readOnly": true
        },
        "documentationLink": {
          "type": "string",
          "description": "A link to a troubleshooting guide for these classes of warnings. This may not be always available.",
          "readOnly": true
        }
      },
      "required": [
        "message"
      ]
    }
  }
}