register_type
async
¶
register_type(
*,
config_overrides: Optional[AsyncCloudFormationClientConfig] = None,
type: Optional[RegistryType] = None,
type_name: Optional[TypeName] = None,
schema_handler_package: Optional[S3Url] = None,
logging_config: Optional[LoggingConfig] = None,
execution_role_arn: Optional[RoleARN2] = None,
client_request_token: Optional[RequestToken] = None,
) -> RegisterTypeOutput
Registers an extension with the CloudFormation service. Registering an extension makes it available for use in CloudFormation templates in your Amazon Web Services account, and includes:
-
Validating the extension schema.
-
Determining which handlers, if any, have been specified for the extension.
-
Making the extension available for use in your account.
For more information about how to develop extensions and ready them for registration, see Creating resource types using the CloudFormation CLI in the CloudFormation Command Line Interface (CLI) User Guide.
You can have a maximum of 50 resource extension versions registered at a time. This maximum is per account and per Region. Use DeregisterType to deregister specific extension versions if necessary.
Once you have initiated a registration request using RegisterType, you can use DescribeTypeRegistration to monitor the progress of the registration request.
Once you have registered a private extension in your account and Region, use SetTypeConfiguration to specify configuration properties for the extension. For more information, see Edit configuration data for extensions in your account in the CloudFormation User Guide.
Parameters:
-
type(Optional[RegistryType], default:None) –The kind of extension.
-
type_name(Optional[TypeName], default:None) –The name of the extension being registered.
We suggest that extension names adhere to the following patterns:
-
For resource types,
company_or_organization::service::type. -
For modules,
company_or_organization::service::type::MODULE. -
For Hooks,
MyCompany::Testing::MyTestHook.
The following organization namespaces are reserved and can't be used in your extension names:
-
Alexa -
AMZN -
Amazon -
AWS -
Custom -
Dev
-
-
schema_handler_package(Optional[S3Url], default:None) –A URL to the S3 bucket that contains the extension project package that contains the necessary files for the extension you want to register.
For information about generating a schema handler package for the extension you want to register, see submit in the CloudFormation Command Line Interface (CLI) User Guide.
The user registering the extension must be able to access the package in the S3 bucket. That's, the user needs to have GetObject permissions for the schema handler package. For more information, see Actions, Resources, and Condition Keys for Amazon S3 in the Identity and Access Management User Guide.
-
logging_config(Optional[LoggingConfig], default:None) –Specifies logging configuration information for an extension.
-
execution_role_arn(Optional[RoleARN2], default:None) –The Amazon Resource Name (ARN) of the IAM role for CloudFormation to assume when invoking the extension.
For CloudFormation to assume the specified execution role, the role must contain a trust relationship with the CloudFormation service principal (
resources.cloudformation.amazonaws.com). For more information about adding trust relationships, see Modifying a role trust policy in the Identity and Access Management User Guide.If your extension calls Amazon Web Services APIs in any of its handlers, you must create an IAM execution role that includes the necessary permissions to call those Amazon Web Services APIs, and provision that execution role in your account. When CloudFormation needs to invoke the resource type handler, CloudFormation assumes this execution role to create a temporary session token, which it then passes to the resource type handler, thereby supplying your resource type with the appropriate credentials.
-
client_request_token(Optional[RequestToken], default:None) –A unique identifier that acts as an idempotency key for this registration request. Specifying a client request token prevents CloudFormation from generating more than one version of an extension from the same registration request, even if the request is submitted multiple times.
Raises:
-
CFNRegistryException–An error occurred during a CloudFormation registry operation.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_cloudformation/_services/async_cloud_formation.py
6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 | |