---
title: "POST /listreplacepermissionassociationswork"
method: POST
path: "/listreplacepermissionassociationswork"
---

# POST /listreplacepermissionassociationswork

`POST /listreplacepermissionassociationswork`

Retrieves the current status of the asynchronous tasks performed by RAM when you perform the <a>ReplacePermissionAssociationsWork</a> operation.

## Query parameters

- `maxResults` string
- `nextToken` string

## Request body

- object
  - `workIds` String[] — A list of IDs. These values come from the <code>id</code>field of the <code>replacePermissionAssociationsWork</code>structure returned by the <a>ReplacePermissionAssociations</a> operation.
  - `status` 'IN_PROGRESS' | 'COMPLETED' | 'FAILED' — 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 <code>NextToken</code> response 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's <code>NextToken</code> response 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 <code>NextToken</code> response element is returned with a value (not null). Include the specified value as the <code>NextToken</code> request 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 check <code>NextToken</code> after every operation to ensure that you receive all of the results.

## Response `200`

Success

- ListReplacePermissionAssociationsWorkResponse
  - `replacePermissionAssociationsWorks` ReplacePermissionAssociationsWork[] — An array of data structures that provide details of the matching work IDs.
    - `id` string — The unique identifier for the background task associated with one <a>ReplacePermissionAssociations</a> request.
    - `fromPermissionArn` string — The <a href="https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Name (ARN)</a> 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 <code>fromPermissionArn</code> and <code>fromPermissionVersion</code>.
    - `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` 'IN_PROGRESS' | 'COMPLETED' | 'FAILED' — <p>Specifies the current status of the background tasks for the specified ID. The output is one of the following strings:</p> <ul> <li> <p> <code>IN_PROGRESS</code> </p> </li> <li> <p> <code>COMPLETED</code> </p> </li> <li> <p> <code>FAILED</code> </p> </li> </ul>
    - `statusMessage` string — Specifies the reason for a <code>FAILED</code> status. This field is present only when there <code>status</code> is <code>FAILED</code>.
    - `creationTime` string, date-time — The date and time when this asynchronous background task was created.
    - `lastUpdatedTime` string, date-time — 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 <code>NextToken</code> request parameter in a subsequent call to the operation to get the next part of the output. You should repeat this until the <code>NextToken</code> response element comes back as <code>null</code>. This indicates that this is the last page of results.

## Other responses

- `480` — ServerInternalException
- `481` — ServiceUnavailableException
- `482` — InvalidNextTokenException
- `483` — InvalidParameterException

---

[API](https://skmtc.net/aws/apis/ram.md) · [All operations](https://skmtc.net/aws/apis/ram/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/ram/versions/61869c19b93e/schema)
