RAM / Client / list_replace_permission_associations_work
list_replace_permission_associations_work¶
- RAM.Client.list_replace_permission_associations_work(**kwargs)¶
Retrieves the current status of the asynchronous tasks performed by RAM when you perform the ReplacePermissionAssociationsWork operation.
Note
Always check the
NextTokenresponse parameter for anullvalue when calling a paginated operation. These operations can occasionally return an empty set of results even when there are more results available. TheNextTokenresponse parameter value isnullonly when there are no more results to display.See also: AWS API Documentation
Request Syntax
response = client.list_replace_permission_associations_work( workIds=[ 'string', ], status='IN_PROGRESS'|'COMPLETED'|'FAILED', nextToken='string', maxResults=123 )
- Parameters:
workIds (list) –
A list of IDs. These values come from the ``id``field of the ``replacePermissionAssociationsWork``structure returned by the ReplacePermissionAssociations operation.
(string) –
status (string) – Specifies that you want to see only the details about requests with a status that matches this value.
nextToken (string) – Specifies that you want to receive the next page of results. Valid only if you received a
NextTokenresponse in the previous request. If you did, it indicates that more output is available. Set this parameter to the value provided by the previous call’sNextTokenresponse to request the next page of results.maxResults (integer) – Specifies the total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the number you specify, the
NextTokenresponse element is returned with a value (not null). Include the specified value as theNextTokenrequest parameter in the next call to the operation to get the next part of the results. Note that the service might return fewer results than the maximum even when there are more results available. You should checkNextTokenafter every operation to ensure that you receive all of the results.
- Return type:
dict
- Returns:
Response Syntax
{ 'replacePermissionAssociationsWorks': [ { 'id': 'string', 'fromPermissionArn': 'string', 'fromPermissionVersion': 'string', 'toPermissionArn': 'string', 'toPermissionVersion': 'string', 'status': 'IN_PROGRESS'|'COMPLETED'|'FAILED', 'statusMessage': 'string', 'creationTime': datetime(2015, 1, 1), 'lastUpdatedTime': datetime(2015, 1, 1) }, ], 'nextToken': 'string' }
Response Structure
(dict) –
replacePermissionAssociationsWorks (list) –
An array of data structures that provide details of the matching work IDs.
(dict) –
A structure that represents the background work that RAM performs when you invoke the ReplacePermissionAssociations operation.
id (string) –
The unique identifier for the background task associated with one ReplacePermissionAssociations request.
fromPermissionArn (string) –
The Amazon Resource Name (ARN) of the managed permission that this background task is replacing.
fromPermissionVersion (string) –
The version of the managed permission that this background task is replacing.
toPermissionArn (string) –
The ARN of the managed permission that this background task is associating with the resource shares in place of the managed permission and version specified in
fromPermissionArnandfromPermissionVersion.toPermissionVersion (string) –
The version of the managed permission that this background task is associating with the resource shares. This is always the version that is currently the default for this managed permission.
status (string) –
Specifies the current status of the background tasks for the specified ID. The output is one of the following strings:
IN_PROGRESSCOMPLETEDFAILED
statusMessage (string) –
Specifies the reason for a
FAILEDstatus. This field is present only when therestatusisFAILED.creationTime (datetime) –
The date and time when this asynchronous background task was created.
lastUpdatedTime (datetime) –
The date and time when the status of this background task was last updated.
nextToken (string) –
If present, this value indicates that more output is available than is included in the current response. Use this value in the
NextTokenrequest parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until theNextTokenresponse element comes back asnull. This indicates that this is the last page of results.
Exceptions
RAM.Client.exceptions.ServerInternalExceptionRAM.Client.exceptions.ServiceUnavailableExceptionRAM.Client.exceptions.InvalidNextTokenExceptionRAM.Client.exceptions.InvalidParameterException