{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/scylladb/json-schema/scylladb-cluster-connection-schema.json",
  "title": "ClusterConnection",
  "description": "Peering details information",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/scylladb-account-network-cluster-connection-api-openapi.yml#/components/schemas/ClusterConnection",
  "type": "object",
  "x-public": true,
  "properties": {
    "awaitingData": {
      "allOf": [
        {
          "type": "object"
        },
        {
          "$ref": "#/$defs/ClusterConnectionAwaitingData"
        }
      ],
      "description": "AwaitingData represents information regarding the action that needs to be done to move connection creating process further"
    },
    "awaitingForClient": {
      "type": "boolean",
      "description": "AwaitingForClient if true, then going to next stage require user action"
    },
    "cidrlist": {
      "type": "array",
      "description": "CIDR list of the routes cluster have access through this connection",
      "items": {
        "$ref": "#/$defs/CIDR"
      }
    },
    "clusterDCID": {
      "type": "integer",
      "description": "ID of the cluster DC"
    },
    "clusterID": {
      "type": "integer",
      "description": "ID of the cluster"
    },
    "clusterVPCID": {
      "type": "integer",
      "description": "ID of the VPC"
    },
    "data": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      }
    },
    "externalID": {
      "type": "string",
      "description": "ExternalID and ID of the connection object on the cloud"
    },
    "id": {
      "type": "integer",
      "description": "ID of the created connection (ScyllaDB internal)"
    },
    "name": {
      "type": "string",
      "description": "Name if the connection, only to show on UI"
    },
    "stage": {
      "type": "string",
      "description": "Stage if there is ongoing process it shows where this process exactly at"
    },
    "stageMessage": {
      "type": "string",
      "description": "StageMessage is a message from stage processor why it can't move further"
    },
    "status": {
      "type": "string",
      "enum": [
        "INIT",
        "PENDING",
        "ACTIVE",
        "INACTIVE",
        "DELETING",
        "DELETED",
        "FAILED"
      ]
    },
    "type": {
      "type": "string",
      "enum": [
        "AWS_TGW_ATTACHMENT"
      ]
    }
  },
  "$defs": {
    "CIDR": {
      "type": "string",
      "description": "CIDR block in the form of ip/mask",
      "x-public": true
    },
    "ClusterConnectionAwaitingData": {
      "type": "object",
      "x-public": true,
      "additionalProperties": {
        "type": "string"
      }
    }
  }
}