{
 "additionalProperties": false,
 "createOnlyProperties": [
  "/properties/SecurityProfileName",
  "/properties/InstanceArn"
 ],
 "definitions": {
  "Application": {
   "additionalProperties": false,
   "properties": {
    "ApplicationPermissions": {
     "insertionOrder": false,
     "items": {
      "$ref": "#/definitions/ApplicationPermission"
     },
     "maxItems": 10,
     "minItems": 1,
     "type": "array",
     "uniqueItems": true
    },
    "Namespace": {
     "maxLength": 128,
     "minLength": 1,
     "type": "string"
    },
    "Type": {
     "enum": [
      "MCP",
      "THIRD_PARTY_APPLICATION"
     ],
     "type": "string"
    }
   },
   "required": [
    "ApplicationPermissions",
    "Namespace"
   ],
   "type": "object"
  },
  "ApplicationPermission": {
   "maxLength": 128,
   "minLength": 1,
   "type": "string"
  },
  "DataTableAccessControlConfiguration": {
   "additionalProperties": false,
   "properties": {
    "PrimaryAttributeAccessControlConfiguration": {
     "$ref": "#/definitions/PrimaryAttributeAccessControlConfigurationItem"
    }
   },
   "type": "object"
  },
  "FlowModule": {
   "additionalProperties": false,
   "properties": {
    "FlowModuleId": {
     "maxLength": 128,
     "minLength": 1,
     "type": "string"
    },
    "Type": {
     "enum": [
      "MCP"
     ],
     "maxLength": 128,
     "minLength": 1,
     "type": "string"
    }
   },
   "required": [
    "Type",
    "FlowModuleId"
   ],
   "type": "object"
  },
  "Permission": {
   "maxLength": 128,
   "minLength": 1,
   "type": "string"
  },
  "PrimaryAttributeAccessControlConfigurationItem": {
   "additionalProperties": false,
   "properties": {
    "PrimaryAttributeValues": {
     "items": {
      "$ref": "#/definitions/PrimaryAttributeValue"
     },
     "maxItems": 5,
     "minItems": 1,
     "type": "array",
     "uniqueItems": true
    }
   },
   "required": [
    "PrimaryAttributeValues"
   ],
   "type": "object"
  },
  "PrimaryAttributeValue": {
   "additionalProperties": false,
   "properties": {
    "AccessType": {
     "enum": [
      "ALLOW"
     ],
     "type": "string"
    },
    "AttributeName": {
     "maxLength": 127,
     "minLength": 1,
     "pattern": "^(?!aws:|connect:)[\\p{L}\\p{Z}\\p{N}\\-_.:=@'|]+$",
     "type": "string"
    },
    "Values": {
     "items": {
      "maxLength": 1000,
      "minLength": 1,
      "pattern": "^[\\u0009\\u000A\\u000D\\u0020-\\u007E\\u00A1-\\u00FF]+$",
      "type": "string"
     },
     "maxItems": 2,
     "minItems": 1,
     "type": "array",
     "uniqueItems": true
    }
   },
   "required": [
    "AccessType",
    "AttributeName",
    "Values"
   ],
   "type": "object"
  },
  "ResourceName": {
   "maxLength": 128,
   "minLength": 1,
   "type": "string"
  },
  "Tag": {
   "additionalProperties": false,
   "properties": {
    "Key": {
     "maxLength": 128,
     "minLength": 1,
     "pattern": "^(?!aws:)[a-zA-Z+-=._:/]+$",
     "type": "string"
    },
    "Value": {
     "maxLength": 256,
     "minLength": 0,
     "type": "string"
    }
   },
   "required": [
    "Key",
    "Value"
   ],
   "type": "object"
  }
 },
 "primaryIdentifier": [
  "/properties/SecurityProfileArn"
 ],
 "properties": {
  "AllowedAccessControlHierarchyGroupId": {
   "maxLength": 127,
   "minLength": 0,
   "pattern": "^[a-zA-Z0-9-]+$",
   "type": "string"
  },
  "AllowedAccessControlTags": {
   "insertionOrder": false,
   "items": {
    "$ref": "#/definitions/Tag"
   },
   "maxItems": 2,
   "type": "array",
   "uniqueItems": true
  },
  "AllowedFlowModules": {
   "insertionOrder": false,
   "items": {
    "$ref": "#/definitions/FlowModule"
   },
   "maxItems": 10,
   "minItems": 0,
   "type": "array",
   "uniqueItems": true
  },
  "Applications": {
   "insertionOrder": false,
   "items": {
    "$ref": "#/definitions/Application"
   },
   "maxItems": 10,
   "minItems": 0,
   "type": "array",
   "uniqueItems": true
  },
  "Description": {
   "maxLength": 250,
   "minLength": 0,
   "type": "string"
  },
  "GranularAccessControlConfiguration": {
   "additionalProperties": false,
   "properties": {
    "DataTableAccessControlConfiguration": {
     "$ref": "#/definitions/DataTableAccessControlConfiguration"
    }
   },
   "type": "object"
  },
  "HierarchyRestrictedResources": {
   "insertionOrder": false,
   "items": {
    "$ref": "#/definitions/ResourceName"
   },
   "maxItems": 10,
   "type": "array",
   "uniqueItems": true
  },
  "InstanceArn": {
   "pattern": "^arn:aws[-a-z0-9]*:connect:[-a-z0-9]*:[0-9]{12}:instance/[-a-zA-Z0-9]*$",
   "type": "string"
  },
  "LastModifiedRegion": {
   "pattern": "[a-z]{2}(-[a-z]+){1,2}(-[0-9])?",
   "type": "string"
  },
  "LastModifiedTime": {
   "type": "number"
  },
  "Permissions": {
   "insertionOrder": false,
   "items": {
    "$ref": "#/definitions/Permission"
   },
   "maxItems": 500,
   "minItems": 0,
   "type": "array",
   "uniqueItems": true
  },
  "SecurityProfileArn": {
   "pattern": "^arn:aws[-a-z0-9]*:connect:[-a-z0-9]*:[0-9]{12}:instance/[-a-zA-Z0-9]*/security-profile/[-a-zA-Z0-9]*$",
   "type": "string"
  },
  "SecurityProfileName": {
   "maxLength": 127,
   "minLength": 1,
   "pattern": "^[ a-zA-Z0-9_@-]+$",
   "type": "string"
  },
  "TagRestrictedResources": {
   "insertionOrder": false,
   "items": {
    "$ref": "#/definitions/ResourceName"
   },
   "maxItems": 10,
   "minItems": 0,
   "type": "array",
   "uniqueItems": true
  },
  "Tags": {
   "insertionOrder": false,
   "items": {
    "$ref": "#/definitions/Tag"
   },
   "maxItems": 50,
   "type": "array",
   "uniqueItems": true
  }
 },
 "readOnlyProperties": [
  "/properties/SecurityProfileArn",
  "/properties/LastModifiedRegion",
  "/properties/LastModifiedTime"
 ],
 "required": [
  "InstanceArn",
  "SecurityProfileName"
 ],
 "sourceUrl": "https://github.com/aws-cloudformation/aws-cloudformation-resource-providers-connect",
 "tagging": {
  "cloudFormationSystemTags": true,
  "tagOnCreate": true,
  "tagProperty": "/properties/Tags",
  "tagUpdatable": true,
  "taggable": true
 },
 "typeName": "AWS::Connect::SecurityProfile"
}
