{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-kms/json-schema/amazon-kms-describe-custom-key-stores-response-schema.json",
  "title": "DescribeCustomKeyStoresResponse",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-kms-custom-key-store-api-openapi.yml#/components/schemas/DescribeCustomKeyStoresResponse",
  "type": "object",
  "properties": {
    "CustomKeyStores": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/CustomKeyStoresListEntry"
      },
      "description": "Contains metadata about each custom key store."
    },
    "NextMarker": {
      "type": "string",
      "description": "When Truncated is true, this element is present and contains the value to use for the Marker parameter in a subsequent request."
    },
    "Truncated": {
      "type": "boolean",
      "description": "A flag that indicates whether there are more items in the list. When this value is true, the list in this response is truncated. To get more items, pass the value of the NextMarker element in this response to the Marker parameter in a subsequent request."
    }
  },
  "$defs": {
    "CustomKeyStoresListEntry": {
      "type": "object",
      "properties": {
        "CustomKeyStoreId": {
          "type": "string",
          "description": "A unique identifier for the custom key store."
        },
        "CustomKeyStoreName": {
          "type": "string",
          "description": "The user-specified friendly name for the custom key store."
        },
        "CloudHsmClusterId": {
          "type": "string",
          "description": "A unique identifier for the CloudHSM cluster that is associated with an CloudHSM key store. This field appears only when the CustomKeyStoreType is AWS_CLOUDHSM."
        },
        "TrustAnchorCertificate": {
          "type": "string",
          "description": "The trust anchor certificate of the CloudHSM cluster associated with an CloudHSM key store. When you initialize the cluster, you create this certificate and save it in the customerCA.crt file. This field appears only when the CustomKeyStoreType is AWS_CLOUDHSM."
        },
        "ConnectionState": {
          "type": "string",
          "enum": [
            "CONNECTED",
            "CONNECTING",
            "FAILED",
            "DISCONNECTED",
            "DISCONNECTING"
          ],
          "description": "Indicates whether the custom key store is connected to its backing key store. For an CloudHSM key store, the ConnectionState indicates whether it is connected to its CloudHSM cluster. For an external key store, the ConnectionState indicates whether it is connected to the external key store proxy that communicates with your external key manager. You can create and use KMS keys in your custom key stores only when its ConnectionState is CONNECTED. The ConnectionState value is DISCONNECTED only if the key store has never been connected or you use the DisconnectCustomKeyStore operation to disconnec"
        },
        "ConnectionErrorCode": {
          "type": "string",
          "enum": [
            "INVALID_CREDENTIALS",
            "CLUSTER_NOT_FOUND",
            "NETWORK_ERRORS",
            "INTERNAL_ERROR",
            "INSUFFICIENT_CLOUDHSM_HSMS",
            "USER_LOCKED_OUT",
            "USER_NOT_FOUND",
            "USER_LOGGED_IN",
            "SUBNET_NOT_FOUND",
            "INSUFFICIENT_FREE_ADDRESSES_IN_SUBNET",
            "XKS_PROXY_ACCESS_DENIED",
            "XKS_PROXY_NOT_REACHABLE",
            "XKS_VPC_ENDPOINT_SERVICE_NOT_FOUND",
            "XKS_PROXY_INVALID_RESPONSE",
            "XKS_PROXY_INVALID_CONFIGURATION",
            "XKS_VPC_ENDPOINT_SERVICE_INVALID_CONFIGURATION",
            "XKS_PROXY_TIMED_OUT",
            "XKS_PROXY_INVALID_TLS_CONFIGURATION"
          ],
          "description": "Describes the connection error. This field appears in the response only when the ConnectionState is FAILED. Many failures can be resolved by updating the properties of the custom key store. To update a custom key store, disconnect it (DisconnectCustomKeyStore), correct the errors (UpdateCustomKeyStore), and try to connect again (ConnectCustomKeyStore). For additional help resolving these errors, see How to Fix a Connection Failure in Key Management Service Developer Guide. All custom key stores: INTERNAL_ERROR — KMS could not complete the request due to an internal error. Retry the request. Fo"
        },
        "CreationDate": {
          "type": "string",
          "format": "date-time",
          "description": "The date and time when the custom key store was created."
        },
        "CustomKeyStoreType": {
          "type": "string",
          "enum": [
            "AWS_CLOUDHSM",
            "EXTERNAL_KEY_STORE"
          ],
          "description": "Indicates the type of the custom key store. AWS_CLOUDHSM indicates a custom key store backed by an CloudHSM cluster. EXTERNAL_KEY_STORE indicates a custom key store backed by an external key store proxy and external key manager outside of Amazon Web Services."
        },
        "XksProxyConfiguration": {
          "$ref": "#/$defs/XksProxyConfigurationType"
        }
      }
    },
    "XksProxyConfigurationType": {
      "type": "object",
      "properties": {
        "Connectivity": {
          "type": "string",
          "enum": [
            "PUBLIC_ENDPOINT",
            "VPC_ENDPOINT_SERVICE"
          ],
          "description": "Indicates whether the external key store proxy uses a public endpoint or an Amazon VPC endpoint service to communicate with KMS."
        },
        "AccessKeyId": {
          "type": "string",
          "description": "The part of the external key store proxy authentication credential that uniquely identifies the secret access key."
        },
        "UriEndpoint": {
          "type": "string",
          "description": "The URI endpoint for the external key store proxy. If the external key store proxy has a public endpoint, it is displayed here. If the external key store proxy uses an Amazon VPC endpoint service name, this field displays the private DNS name associated with the VPC endpoint service."
        },
        "UriPath": {
          "type": "string",
          "description": "The path to the external key store proxy APIs."
        },
        "VpcEndpointServiceName": {
          "type": "string",
          "description": "The Amazon VPC endpoint service used to communicate with the external key store proxy. This field appears only when the external key store proxy uses an Amazon VPC endpoint service to communicate with KMS."
        },
        "VpcEndpointServiceOwner": {
          "type": "string",
          "description": "The Amazon Web Services account ID that owns the Amazon VPC endpoint service used to communicate with the external key store proxy (XKS). This field appears only when the XKS uses an VPC endpoint service to communicate with KMS."
        }
      }
    }
  }
}