Context / Client / create_curation_policy_version
create_curation_policy_version¶
- Context.Client.create_curation_policy_version(**kwargs)¶
Publishes a curation policy’s working copy as a new, immutable version. The agent contexts associated with the policy start enforcing the new version. Returns the updated policy.
See also: AWS API Documentation
Request Syntax
response = client.create_curation_policy_version( clientToken='string', curationPolicyId='string', revisionId='string' )
- Parameters:
clientToken (string) –
A token that makes a retry safe. A retry with the same token and the same parameters returns the current policy instead of creating another version. A token used with different parameters is a ValidationException, checked first, and a retry with the same parameters after the policy was deleted is a ConflictException. Required at run time. The AWS SDKs generate one.
This field is autopopulated if not provided.
curationPolicyId (string) –
[REQUIRED]
The ID of the curation policy to publish a new version of.
revisionId (string) –
[REQUIRED]
The
revisionIdof the working copy to publish, as last read. A working copy whose revision has since advanced is a ConflictException.
- Return type:
dict
- Returns:
Response Syntax
{ 'id': 'string', 'arn': 'string', 'name': 'string', 'lastPublishedVersion': 'string', 'revisionId': 'string', 'createdAt': datetime(2015, 1, 1), 'updatedAt': datetime(2015, 1, 1), 'autoRejectAfterSeconds': 123, 'description': 'string', 'policyDocument': 'string', 'status': 'DRAFT'|'ACTIVE'|'DELETED' }
Response Structure
(dict) –
id (string) –
The ID of the curation policy. Requests take it as
curationPolicyId.arn (string) –
The ARN of the curation policy.
name (string) –
The name of the curation policy.
lastPublishedVersion (string) –
Newest published version. Absent until the policy’s first version is created (a DRAFT that has never been published has no version).
revisionId (string) –
An opaque revision token for the working copy. Pass it as
revisionIdonUpdateCurationPolicy. The update applies only if the token still matches the current working copy.createdAt (datetime) –
The date and time when the curation policy was created.
updatedAt (datetime) –
When the resource last changed. Equal to
createdAtuntil the first update.autoRejectAfterSeconds (integer) –
The number of seconds that a proposal held for review under this policy can wait for a decision before AWS Context rejects it with
statusReasonCodeREQUEST_EXPIRED. From 86,400 seconds (1 day) to 15,552,000 seconds (180 days). Absent if proposals held under this policy are never rejected automatically.description (string) –
The description of the curation policy.
policyDocument (string) –
The policy’s rules, as a Cedar policy document: the rule the engine evaluates. Always present on the resource.
status (string) –
The policy’s status.
Valid values:
DRAFT- The policy has never been published, so no agent context enforces it.ACTIVE- The policy has a published version, which the agent contexts associated with it enforce.DELETED- The policy is deleted. Nothing enforces it, and only GetCurationPolicy still returns it.
Exceptions