CloudFront / Client / put_resource_policy
put_resource_policy¶
- CloudFront.Client.put_resource_policy(**kwargs)¶
Creates a resource control policy for a given CloudFront resource.
See also: AWS API Documentation
Request Syntax
response = client.put_resource_policy( ResourceArn='string', PolicyDocument='string' )
- Parameters:
ResourceArn (string) –
[REQUIRED]
The Amazon Resource Name (ARN) of the CloudFront resource for which the policy is being created.
PolicyDocument (string) –
[REQUIRED]
The JSON-formatted resource policy to create.
- Return type:
dict
- Returns:
Response Syntax
{ 'ResourceArn': 'string' }
Response Structure
(dict) –
ResourceArn (string) –
The Amazon Resource Name (ARN) of the CloudFront resource for which the policy was created.
Exceptions
CloudFront.Client.exceptions.PreconditionFailedCloudFront.Client.exceptions.AccessDeniedCloudFront.Client.exceptions.EntityNotFoundCloudFront.Client.exceptions.UnsupportedOperationCloudFront.Client.exceptions.InvalidArgumentCloudFront.Client.exceptions.IllegalUpdate