Lists the datasets in a workspace.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
paidataset:ListDatasets |
list |
*All Resource
|
None | None |
Request syntax
GET /api/v1/datasets HTTP/1.1
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| PageNumber |
integer |
No |
The page number for the paged query. Starts at 1. The default is 1. |
1 |
| PageSize |
integer |
No |
The number of datasets to return per page. The default is 10. |
10 |
| Order |
string |
No |
The sort order for the results, based on the
Valid values:
|
ASC |
| Name |
string |
No |
The dataset name. Fuzzy search is supported. |
myName |
| Properties |
string |
No |
The dataset properties. To specify multiple properties, separate them with commas (,). Valid values:
Valid values:
|
FILE |
| DataSourceTypes |
string |
No |
The data source type. To specify multiple types, separate them with commas (,). Valid values:
Valid values:
|
OSS |
| DataTypes |
string |
No |
The data type of the dataset. To specify multiple data types, separate them with commas (,). Valid values:
Valid values:
|
COMMON,TEXT |
| SourceId |
string |
No |
The source ID. The value of this parameter varies based on the
|
d-rbvg5wzljzjhc9ks92 |
| SourceTypes |
string |
No |
The source type. To specify multiple types, separate them with commas (,). Valid values:
|
USER,ITAG |
| WorkspaceId |
string |
No |
The ID of the workspace that contains the dataset. For information about how to obtain the workspace ID, see ListWorkspaces. If this parameter is not specified, the default workspace is used. An error is returned if the default workspace does not exist. |
324** |
| Label |
string |
No |
A label used to filter datasets. The operation returns datasets whose label key or value contains the specified string. |
test |
| Provider |
string |
No |
The dataset provider. Set this parameter to |
pai |
| SourceDatasetId |
string |
No |
The source dataset ID for an iTAG annotation set. |
d-rcdg3wxxxxxhc5jk87 |
| SortBy |
string |
No |
The sort field. Valid values:
|
GmtCreateTime |
| ShareScope |
string |
No |
A filter for shared datasets.
Valid values:
|
BY_ME |
| Edition |
string |
No |
The dataset edition. Valid values:
Valid values:
|
BASIC |
| Accessibility |
string |
No |
Specifies the dataset's visibility.
Valid values:
|
PRIVATE |
| DatasetIds |
string |
No |
A comma-separated list of dataset IDs. |
d-rcdg3wxxxxxhc5jk87 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response body. |
||
| RequestId |
string |
The request ID. |
5A14FA81-DD4E-******-6343FE44B941 |
| Datasets |
array |
The list of datasets. |
|
| Dataset |
A dataset. |
||
| TotalCount |
integer |
The total count of datasets. |
15 |
Examples
Success response
JSON format
{
"RequestId": "5A14FA81-DD4E-******-6343FE44B941",
"Datasets": [
{
"DatasetId": "d-c0h44g3****j8o4348",
"UserId": "2485765****023475",
"OwnerId": "1631044****3440",
"Name": "myName",
"DataSourceType": "NAS",
"Uri": "nas://09f****f2.cn-hangzhou/",
"GmtCreateTime": "2021-01-21T17:12:35.232Z",
"GmtModifiedTime": "2021-01-21T17:12:35.232Z",
"DataType": "COMMON",
"Property": "DIRECTORY",
"SourceType": "USER",
"SourceId": "jdnhf***fnrimv",
"Description": "This is a description of a dataset.",
"WorkspaceId": "478**",
"Options": "{\n \"mountPath\": \"/mnt/data/\"\n}",
"Accessibility": "PRIVATE",
"ProviderType": "Ecs",
"SourceDatasetId": "d-bvfasdfxxxxj8o411",
"SourceDatasetVersion": "v2",
"TagTemplateType": "text-classification",
"LatestVersion": {
"VersionName": "v1",
"GmtCreateTime": "2021-01-21T17:12:35.232Z",
"GmtModifiedTime": "2021-01-21T17:12:35.232Z",
"Property": "FILE",
"DataSourceType": "OSS",
"Uri": "OSS://xxx",
"Labels": [
{
"Key": "env",
"Value": "test"
}
],
"Options": "{\n \"mountPath\": \"/mnt/data/\"\n}",
"SourceType": "USER",
"Description": "base model v1",
"SourceId": "d-65mrsr5fub4u74lej3",
"DataCount": 10000,
"DataSize": 10000,
"MountAccess": "RO",
"ImportInfo": "{\n \"region\": \"cn-wulanchabu\",\n \"fileSystemId\": \"bmcpfs-xxxxxxxxxxx\",\n \"path\": \"/mnt\",\n \"mountTarget\": \"cpfs-xxxxxxxxxxxx-vpc-gacs9f.cn-wulanchabu.cpfs.aliyuncs.com\",\n \"isVpcMount\": true\n}"
},
"MountAccess": "RO RW",
"ImportInfo": "{\n \"region\": \"cn-wulanchabu\",\n \"fileSystemId\": \"bmcpfs-xxxxxxxxxxx\",\n \"path\": \"/mnt\",\n \"mountTarget\": \"cpfs-xxxxxxxxxxxx-vpc-gacs9f.cn-wulanchabu.cpfs.aliyuncs.com\",\n \"isVpcMount\": true\n}",
"Edition": "BASIC",
"IsShared": false,
"SharedFrom": {
"Status": "ACTIVE",
"SourceTenantId": "148***************115",
"SourceWorkspaceId": "33**19",
"TenantId": "153***************249",
"WorkspaceId": "42**2",
"IsSecureMode": true,
"SharedAt": "2025-08-27T12:23:58Z",
"ExpiresAt": "2026-08-27T12:23:58Z",
"AllowedMountAccessLevels": [
"RO"
],
"Extra": "{\"AllowExportModel\":false,\"AllowAccessDLCWebTerminal\":false,\"AllowAccessDLCFullLog\":false}"
},
"SharingConfig": {
"SharedTo": [
{
"Status": "ACTIVE",
"SourceTenantId": "148***************115",
"SourceWorkspaceId": "33**19",
"TenantId": "153***************249",
"WorkspaceId": "42**2",
"IsSecureMode": true,
"SharedAt": "2025-08-27T12:23:58Z",
"ExpiresAt": "2026-08-27T12:23:58Z",
"AllowedMountAccessLevels": [
"RO"
],
"Extra": "{\"AllowExportModel\":false,\"AllowAccessDLCWebTerminal\":false,\"AllowAccessDLCFullLog\":false}"
}
]
},
"Labels": [
{
"Key": "env",
"Value": "test"
}
],
"MountAccessReadWriteRoleIdList": [
"PAI.AlgoOperator"
],
"AccessibleRoleIdList": [
""
]
}
],
"TotalCount": 15
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.