Context / Client / put_resource_policy
put_resource_policy¶
- Context.Client.put_resource_policy(**kwargs)¶
Attaches a resource-based policy to an agent context, or replaces the one it has. The policy controls which other accounts can call operations on the agent context. Returns the policy’s revision ID.
See also: AWS API Documentation
Request Syntax
response = client.put_resource_policy( resourceArn='string', policy='string', expectedRevisionId='string' )
- Parameters:
resourceArn (string) –
[REQUIRED]
ARN of the agent context to attach the policy to.
policy (string) –
[REQUIRED]
The resource-based policy document.
expectedRevisionId (string) – The revision that you last read. The write succeeds only if it matches the stored revision.
- Return type:
dict
- Returns:
Response Syntax
{ 'resourceArn': 'string', 'revisionId': 'string' }
Response Structure
(dict) –
resourceArn (string) –
ARN of the agent context.
revisionId (string) –
Revision of the stored policy after this call.
Exceptions