{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cockroach-labs/json-schema/cockroach-labs-update-physical-replication-stream-spec-schema.json",
  "title": "UpdatePhysicalReplicationStreamSpec",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cockroach-labs-physical-cluster-replication-api-openapi.yml#/components/schemas/UpdatePhysicalReplicationStreamSpec",
  "type": "object",
  "properties": {
    "failover_at": {
      "description": "failover_at is the crdb system time at which failover occurs. If the user\nsets the status to 'FAILING_OVER' but omits failover_at, the failover time\nwill default to the latest consistent replicated time. Otherwise, the user\ncan pick a time up to one hour in the future to schedule a failover, or a\ntime in the past to restore the cluster to a recent state. If the\ntime is in the past, the API will make a best-effort attempt to\nvalidate that the time is not earlier than the retained time. In\nthis case, if the retained time is updated in between validation\nand failover execution and the failover time becomes invalid, the\nstream will failover to the retained time. failover_at is not required\nwhen updating the status to 'CANCELED'.",
      "type": "string",
      "format": "date-time"
    },
    "status": {
      "$ref": "#/$defs/ReplicationStreamStatus.Type"
    }
  },
  "$defs": {
    "ReplicationStreamStatus.Type": {
      "description": "status describes the desired status of the replication stream.\n\n - STARTING: signifies that a stream is starting\n - REPLICATING: during an update request, status 'REPLICATING' is allowed to transition to 'FAILING_OVER' or 'CANCELED'.\nOther status transitions are not supported.\n - FAILING_OVER: used to trigger a failover, or to signify that a failover is occurring.\n - COMPLETED: signifies that a failover is complete.\n - CANCELED: signifies that a stream is canceled.",
      "type": "string",
      "enum": [
        "STARTING",
        "REPLICATING",
        "FAILING_OVER",
        "COMPLETED",
        "CANCELED"
      ]
    }
  }
}