{
  "typeName" : "AWS::IVS::StorageConfiguration",
  "description" : "Resource Type definition for AWS::IVS::StorageConfiguration",
  "sourceUrl" : "https://github.com/aws-cloudformation/aws-cloudformation-rpdk.git",
  "definitions" : {
    "Tag" : {
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "Key" : {
          "type" : "string",
          "description" : "The key name of the tag. You can specify a value that is 1 to 128 Unicode characters in length and cannot be prefixed with aws:. You can use any of the following characters: the set of Unicode letters, digits, whitespace, _, ., /, =, +, and -.",
          "minLength" : 1,
          "maxLength" : 128
        },
        "Value" : {
          "type" : "string",
          "description" : "The value for the tag. You can specify a value that is 0 to 256 Unicode characters in length and cannot be prefixed with aws:. You can use any of the following characters: the set of Unicode letters, digits, whitespace, _, ., /, =, +, and -.",
          "minLength" : 0,
          "maxLength" : 256
        }
      },
      "required" : [ "Value", "Key" ]
    },
    "S3StorageConfiguration" : {
      "description" : "A complex type that describes an S3 location where recorded videos will be stored.",
      "type" : "object",
      "additionalProperties" : false,
      "properties" : {
        "BucketName" : {
          "description" : "Location (S3 bucket name) where recorded videos will be stored. Note that the StorageConfiguration and S3 bucket must be in the same region as the Composition.",
          "type" : "string",
          "minLength" : 3,
          "maxLength" : 63,
          "pattern" : "^[a-z0-9-.]+$"
        }
      },
      "required" : [ "BucketName" ]
    }
  },
  "properties" : {
    "Arn" : {
      "description" : "Storage Configuration ARN is automatically generated on creation and assigned as the unique identifier.",
      "type" : "string",
      "pattern" : "^arn:aws[-a-z]*:ivs:[a-z0-9-]+:[0-9]+:storage-configuration/[a-zA-Z0-9-]+$",
      "minLength" : 0,
      "maxLength" : 128
    },
    "Name" : {
      "description" : "Storage Configuration Name.",
      "type" : "string",
      "minLength" : 0,
      "maxLength" : 128,
      "pattern" : "^[a-zA-Z0-9-_]*$"
    },
    "S3" : {
      "$ref" : "#/definitions/S3StorageConfiguration"
    },
    "Tags" : {
      "description" : "A list of key-value pairs that contain metadata for the asset model.",
      "type" : "array",
      "uniqueItems" : true,
      "insertionOrder" : false,
      "maxItems" : 50,
      "items" : {
        "$ref" : "#/definitions/Tag"
      }
    }
  },
  "additionalProperties" : false,
  "tagging" : {
    "taggable" : true,
    "tagOnCreate" : true,
    "tagUpdatable" : true,
    "cloudFormationSystemTags" : true,
    "tagProperty" : "/properties/Tags",
    "permissions" : [ "ivs:TagResource", "ivs:UntagResource", "ivs:ListTagsForResource" ]
  },
  "required" : [ "S3" ],
  "primaryIdentifier" : [ "/properties/Arn" ],
  "readOnlyProperties" : [ "/properties/Arn" ],
  "createOnlyProperties" : [ "/properties/Name", "/properties/S3", "/properties/S3/BucketName" ],
  "handlers" : {
    "create" : {
      "permissions" : [ "ivs:CreateStorageConfiguration", "ivs:GetStorageConfiguration", "ivs:TagResource", "s3:GetBucketLocation", "s3:GetBucketPolicy", "s3:PutBucketPolicy" ]
    },
    "read" : {
      "permissions" : [ "ivs:GetStorageConfiguration", "ivs:ListTagsForResource", "s3:GetBucketLocation" ]
    },
    "update" : {
      "permissions" : [ "ivs:GetStorageConfiguration", "ivs:TagResource", "ivs:UntagResource", "ivs:ListTagsForResource" ]
    },
    "delete" : {
      "permissions" : [ "ivs:DeleteStorageConfiguration", "ivs:UntagResource", "s3:GetBucketPolicy", "s3:DeleteBucketPolicy", "s3:PutBucketPolicy" ]
    },
    "list" : {
      "permissions" : [ "ivs:ListStorageConfigurations", "s3:GetBucketLocation", "ivs:ListTagsForResource" ]
    }
  }
}