{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/microsoft-azure-sql-database/json-schema/microsoft-azure-sql-database-instance-failover-group-list-result-schema.json",
  "title": "InstanceFailoverGroupListResult",
  "description": "The response of a InstanceFailoverGroup list operation.",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/microsoft-azure-sql-database-instancefailovergroups-api-openapi.yml#/components/schemas/InstanceFailoverGroupListResult",
  "type": "object",
  "properties": {
    "value": {
      "type": "array",
      "description": "The InstanceFailoverGroup items on this page",
      "items": {
        "$ref": "#/$defs/InstanceFailoverGroup"
      }
    },
    "nextLink": {
      "type": "string",
      "format": "uri",
      "description": "The link to the next page of items"
    }
  },
  "required": [
    "value"
  ],
  "$defs": {
    "InstanceFailoverGroup": {
      "type": "object",
      "description": "An instance failover group.",
      "properties": {
        "properties": {
          "$ref": "#/$defs/InstanceFailoverGroupProperties",
          "description": "Resource properties.",
          "x-ms-client-flatten": true
        }
      },
      "allOf": [
        {
          "$ref": "#/$defs/ProxyResource"
        }
      ]
    },
    "InstanceFailoverGroupProperties": {
      "type": "object",
      "description": "Properties of a instance failover group.",
      "properties": {
        "secondaryType": {
          "$ref": "#/$defs/SecondaryInstanceType",
          "description": "Type of the geo-secondary instance. Set 'Standby' if the instance is used as a DR option only."
        },
        "readWriteEndpoint": {
          "$ref": "#/$defs/InstanceFailoverGroupReadWriteEndpoint",
          "description": "Read-write endpoint of the failover group instance."
        },
        "readOnlyEndpoint": {
          "$ref": "#/$defs/InstanceFailoverGroupReadOnlyEndpoint",
          "description": "Read-only endpoint of the failover group instance."
        },
        "replicationRole": {
          "$ref": "#/$defs/InstanceFailoverGroupReplicationRole",
          "description": "Local replication role of the failover group instance.",
          "readOnly": true
        },
        "replicationState": {
          "type": "string",
          "description": "Replication state of the failover group instance.",
          "readOnly": true
        },
        "partnerRegions": {
          "type": "array",
          "description": "Partner region information for the failover group.",
          "items": {
            "$ref": "#/$defs/PartnerRegionInfo"
          },
          "x-ms-mutability": [
            "read",
            "create"
          ]
        },
        "managedInstancePairs": {
          "type": "array",
          "description": "List of managed instance pairs in the failover group.",
          "items": {
            "$ref": "#/$defs/ManagedInstancePairInfo"
          }
        }
      },
      "required": [
        "readWriteEndpoint",
        "partnerRegions",
        "managedInstancePairs"
      ]
    },
    "InstanceFailoverGroupReadOnlyEndpoint": {
      "type": "object",
      "description": "Read-only endpoint of the failover group instance.",
      "properties": {
        "failoverPolicy": {
          "$ref": "#/$defs/ReadOnlyEndpointFailoverPolicy",
          "description": "Failover policy of the read-only endpoint for the failover group."
        }
      }
    },
    "InstanceFailoverGroupReadWriteEndpoint": {
      "type": "object",
      "description": "Read-write endpoint of the failover group instance.",
      "properties": {
        "failoverPolicy": {
          "$ref": "#/$defs/ReadWriteEndpointFailoverPolicy",
          "description": "Failover policy of the read-write endpoint for the failover group. If failoverPolicy is Automatic then failoverWithDataLossGracePeriodMinutes is required."
        },
        "failoverWithDataLossGracePeriodMinutes": {
          "type": "integer",
          "format": "int32",
          "description": "Grace period before failover with data loss is attempted for the read-write endpoint. If failoverPolicy is Automatic then failoverWithDataLossGracePeriodMinutes is required."
        }
      },
      "required": [
        "failoverPolicy"
      ]
    },
    "InstanceFailoverGroupReplicationRole": {
      "type": "string",
      "description": "Local replication role of the failover group instance.",
      "enum": [
        "Primary",
        "Secondary"
      ],
      "x-ms-enum": {
        "name": "InstanceFailoverGroupReplicationRole",
        "modelAsString": true,
        "values": [
          {
            "name": "Primary",
            "value": "Primary",
            "description": "Primary"
          },
          {
            "name": "Secondary",
            "value": "Secondary",
            "description": "Secondary"
          }
        ]
      }
    },
    "ManagedInstancePairInfo": {
      "type": "object",
      "description": "Pairs of Managed Instances in the failover group.",
      "properties": {
        "primaryManagedInstanceId": {
          "type": "string",
          "description": "Id of Primary Managed Instance in pair."
        },
        "partnerManagedInstanceId": {
          "type": "string",
          "description": "Id of Partner Managed Instance in pair."
        }
      }
    },
    "PartnerRegionInfo": {
      "type": "object",
      "description": "Partner region information for the failover group.",
      "properties": {
        "location": {
          "type": "string",
          "description": "Geo location of the partner managed instances."
        },
        "replicationRole": {
          "$ref": "#/$defs/InstanceFailoverGroupReplicationRole",
          "description": "Replication role of the partner managed instances.",
          "readOnly": true
        }
      }
    },
    "ProxyResource": {
      "type": "object",
      "title": "Proxy Resource",
      "description": "The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location",
      "allOf": [
        {
          "$ref": "#/$defs/Resource"
        }
      ]
    },
    "ReadOnlyEndpointFailoverPolicy": {
      "type": "string",
      "description": "Failover policy of the read-only endpoint for the failover group.",
      "enum": [
        "Disabled",
        "Enabled"
      ],
      "x-ms-enum": {
        "name": "ReadOnlyEndpointFailoverPolicy",
        "modelAsString": true,
        "values": [
          {
            "name": "Disabled",
            "value": "Disabled",
            "description": "Disabled"
          },
          {
            "name": "Enabled",
            "value": "Enabled",
            "description": "Enabled"
          }
        ]
      }
    },
    "ReadWriteEndpointFailoverPolicy": {
      "type": "string",
      "description": "Failover policy of the read-write endpoint for the failover group. If failoverPolicy is Automatic then failoverWithDataLossGracePeriodMinutes is required.",
      "enum": [
        "Manual",
        "Automatic"
      ],
      "x-ms-enum": {
        "name": "ReadWriteEndpointFailoverPolicy",
        "modelAsString": true,
        "values": [
          {
            "name": "Manual",
            "value": "Manual",
            "description": "Manual"
          },
          {
            "name": "Automatic",
            "value": "Automatic",
            "description": "Automatic"
          }
        ]
      }
    },
    "Resource": {
      "type": "object",
      "description": "Referenced by this document but never defined in it. API Evangelist added this empty placeholder so the document resolves; the shape is unknown and is NOT a claim about the API.",
      "x-ae-placeholder": true
    },
    "SecondaryInstanceType": {
      "type": "string",
      "description": "Type of the geo-secondary instance. Set 'Standby' if the instance is used as a DR option only.",
      "enum": [
        "Geo",
        "Standby"
      ],
      "x-ms-enum": {
        "name": "SecondaryInstanceType",
        "modelAsString": true,
        "values": [
          {
            "name": "Geo",
            "value": "Geo",
            "description": "Geo"
          },
          {
            "name": "Standby",
            "value": "Standby",
            "description": "Standby"
          }
        ]
      }
    }
  }
}