All Products
Search
Document Center

File Storage NAS:ListRecycleBinJobs

Last Updated:Jul 31, 2026

Queries information about one or more tasks in the recycle bin.

Operation description

  • Only General-purpose NAS file systems support this feature.

  • You can query up to 50 most recently executed tasks.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

nas:ListRecycleBinJobs

get

*FileSystem

acs:nas:{#regionId}:{#accountId}:filesystem/{#FileSystemId}

None None

Request parameters

Parameter

Type

Required

Description

Example

FileSystemId

string

Yes

The file system ID.

1ca404****

JobId

string

No

The task ID.

rb-15****ed-r-1625****2441

PageSize

integer

No

The number of entries per page in a paged query.

Valid values: 1 to 100.

Default value: 10.

10

PageNumber

integer

No

The page number of the current page in a paged query.

Start value (default value): 1.

1

Status

string

No

The task status. Valid values:

  • Running: The task is running.

  • Defragmenting: Data is being defragmented.

  • PartialSuccess: The task partially succeeded.

  • Success: The task succeeded.

  • Fail: The task failed.

  • Cancelled: The task is canceled.

  • All (default): All statuses.

Valid values:

  • All :

    all statuses.

  • Defragmenting :

    data is being defragmented.

  • Running :

    the task is running.

  • PartialSuccess :

    the task partially succeeded.

  • Cancelled :

    the task is canceled.

  • Success :

    the task succeeded.

  • Fail :

    the task failed.

All

Response elements

Element

Type

Description

Example

object

Schema of Response

RequestId

string

The request ID.

9E15E394-38A6-457A-A62A-D9797C9A****

TotalCount

integer

The total number of tasks in the recycle bin.

1

PageNumber

integer

The page number of the returned page.

1

PageSize

integer

The number of tasks per page.

10

Jobs

array<object>

The collection of task information in the recycle bin.

object

Id

string

The task ID.

8C****C54

Type

string

The task type. Valid values:

  • Restore: A file restoration task.

  • Delete: A file deletion task.

Restore

FileId

string

The FileId of the file or directory associated with the task.

04***08

Status

string

The task status. Valid values:

  • Running: The task is running.

  • Defragmenting: Data is being defragmented.

  • PartialSuccess: The task partially succeeded.

  • Success: The task succeeded.

  • Fail: The task failed.

  • Cancelled: The task is canceled.

Fail

ErrorCode

string

The error code.

This value is valid only when Status is Fail or PartialSuccess.

InvalidFileId.NotFound

Progress

string

The execution progress of the task.

Valid values: 1 to 100.

100

CreateTime

string

The time when the task was created. The time follows the ISO 8601 standard in UTC. Format: yyyy-MM-ddTHH:mm:ssZ.

2021-05-30T10:08:08Z

FileName

string

The name of the file or directory associated with the task.

test001

ErrorMessage

string

The error message.

This value is valid only when JobStatus is Fail or PartialSuccess.

The Target File or Directory does not exist.

Examples

Success response

JSON format

{
  "RequestId": "9E15E394-38A6-457A-A62A-D9797C9A****",
  "TotalCount": 1,
  "PageNumber": 1,
  "PageSize": 10,
  "Jobs": [
    {
      "Id": "8C****C54",
      "Type": "Restore",
      "FileId": "04***08",
      "Status": "Fail",
      "ErrorCode": "InvalidFileId.NotFound",
      "Progress": "100",
      "CreateTime": "2021-05-30T10:08:08Z",
      "FileName": "test001",
      "ErrorMessage": "The Target File or Directory does not exist."
    }
  ]
}

Error codes

HTTP status code

Error code

Error message

Description

400 IllegalCharacters The parameter contains illegal characters. The parameter contains illegal characters.
400 MissingFileSystemId FileSystemId is mandatory for this action. The FileSystemId parameter is not specified.
400 InvalidStatus Specified parameter Status is not valid. The specified parameter Status is invalid.
404 InvalidFileSystem.NotFound The specified file system does not exist. The specified file system does not exist.
404 InvalidJobId.NotFound The specified JobId(%JobId) does not exist. The specified JobId (%JobId) does not exist.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.