All Products
Search
Document Center

Platform For AI:GetDataset

Last Updated:Oct 17, 2025

Retrieves a dataset.

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

paidataset:GetDataset

get

*All Resource

*

None None

Request syntax

GET /api/v1/datasets/{DatasetId} HTTP/1.1

Path Parameters

Parameter

Type

Required

Description

Example

DatasetId

string

Yes

The ID of the dataset. For more information, see ListDatasets.

d-rbvg5wz****c9ks92

Request parameters

Parameter

Type

Required

Description

Example

No parameters required.

Response elements

Element

Type

Description

Example

object

The returned result.

RequestId

string

The request ID.

5A14FA81-DD4E-******-6343FE44B941

DatasetId

string

The ID of the dataset.

d-rbvg5wz****c9ks92

Name

string

The name of the dataset.

myName

Description

string

The description.

用于标注的数据。

GmtCreateTime

string

The time when the dataset was created.

2021-01-30T12:51:33.028Z

GmtModifiedTime

string

The time when the dataset was last updated.

2021-01-30T12:51:33.028Z

UserId

string

The ID of the user to whom the dataset belongs.

2485765****023475

OwnerId

string

The ID of the Alibaba Cloud account.

1631044****3440

Property

string

The property of the initial version v1 of the dataset. Valid values:

  • FILE: a file.

  • DIRECTORY: a folder.

Valid values:

  • DIRECTORY :

    DIRECTORY

  • FILE :

    FILE

DIRECTORY

DataSourceType

string

The type of the data source. Valid values:

  • OSS: Object Storage Service (OSS).

  • NAS: NAS.

Valid values:

  • NAS :

    NAS

  • OSS :

    OSS

NAS

Uri

string

The URI of the initial version v1. Examples:

  • If DataSourceType is OSS: oss://bucket.endpoint/object.

  • If DataSourceType is NAS: The format for a General-purpose NAS file system is nas://<nasfisid>.region/subpath/to/dir/. The format for CPFS 1.0 is nas://<cpfs-fsid>.region/subpath/to/dir/. The format for CPFS 2.0 is nas://<cpfs-fsid>.region/<protocolserviceid>/. CPFS 1.0 and CPFS 2.0 are distinguished by the fsid format. The fsid for CPFS 1.0 is in the `cpfs-<8 ASCII characters>` format. The fsid for CPFS 2.0 is in the `cpfs-<16 ASCII characters>` format.

nas://09f****f2.cn-hangzhou/

Labels

array

The list of labels.

Label

The labels that are added to the dataset.

{"Key": "env", "Value": "test"}

DataType

string

The data type of the dataset. Valid values:

  • COMMON: common data.

  • PIC: images.

  • TEXT: text.

  • VIDEO: videos.

  • AUDIO: audio.

Valid values:

  • VIDEO :

    VIDEO

  • COMMON :

    COMMON

  • TEXT :

    TEXT

  • PIC :

    PIC

  • AUDIO :

    AUDIO

COMMON

SourceType

string

The type of the data source for the initial version v1.

Valid values:

  • PAI_PUBLIC_DATASET :

    PAI_PUBLIC_DATASET

  • ITAG :

    ITAG

  • USER :

    USER

USER

SourceId

string

The ID of the data source for the initial version v1.

  • If SourceType is USER, you can customize this parameter.

  • If SourceType is ITAG, the dataset is generated from the annotation results of the iTAG module. In this case, SourceId is the task ID in iTAG.

  • If SourceType is PAI_PUBLIC_DATASET, the dataset is created from a PAI public dataset. In this case, SourceId is empty by default.

jdnhf***fnrimv

WorkspaceId

string

The ID of the workspace to which the dataset belongs.

478**

Options

string

The extended field of the initial version v1. The value is a JSON string. When DLC uses the dataset, you can configure the `mountPath` field to specify the default mount path for the dataset.

{ "mountPath": "/mnt/data/" }

Accessibility

string

The visibility of the dataset in the workspace. Valid values:

  • PRIVATE: The dataset is visible only to the dataset owner and administrators in the workspace.

  • PUBLIC: The dataset is visible to all users in the workspace.

Valid values:

  • PUBLIC :

    PUBLIC

  • PRIVATE :

    PRIVATE

PRIVATE

ProviderType

string

The type of the data source of the dataset. Valid values:

  • Ecs (default)

  • Lingjun

Ecs

Provider

string

The provider of the dataset. If the return value is "pai", the dataset is a public dataset on the PAI platform.

pai

SourceDatasetId

string

The ID of the source dataset for the iTAG annotation set.

d-rcdg3wxxxxxhc5jk87

SourceDatasetVersion

string

The version of the source dataset for the annotated dataset.

v2

TagTemplateType

string

The annotation template of the iTAG annotated dataset.

TextClassification

LatestVersion DatasetVersion

The latest version of the dataset.

MountAccess

string

The permissions on the dataset when it is mounted.

  • RO: read-only mount

  • RW: read and write mount

RW

MountAccessReadWriteRoleIdList

array

The list of workspace role names that have read and write permissions on the dataset. A role ID that starts with `PAI` is a basic role ID. A role ID that starts with `role-` is a custom role ID. If the list contains `*`, all roles have read and write permissions.

string

The ID of the workspace role.

PAI.AlgoOperator

ImportInfo

string

The storage import configuration of the dataset. OSS, NAS, and CPFS are supported.

OSS

{
"region": "${region}",//Region ID
"bucket": "${bucket}",//Bucket name
"path": "${path}" //File path
}

NAS

{
"region": "${region}",//Region ID
"fileSystemId": "${file_system_id}", //File system ID
"path": "${path}", //File system path
"mountTarget": "${mount_target}" //File system mount target
}

CPFS

{
"region": "${region}",//Region ID
"fileSystemId": "${file_system_id}", //File system ID
"protocolServiceId":"${protocol_service_id}", //Protocol service of the file system
"exportId": "${export_id}", //Export directory of the file system
"path": "${path}", //File system path
}

CPFS for Intelligent Computing

{
"region": "${region}",//Region ID
"fileSystemId": "${file_system_id}", //File system ID
"path": "${path}", //File system path
"mountTarget": "${mount_target}" //File system mount target. This parameter is specific to CPFS for Intelligent Computing.
"isVpcMount": boolean, //Specifies whether the mount target is a VPC mount target. This parameter is specific to CPFS for Intelligent Computing.
}

{ "region": "cn-wulanchabu", "fileSystemId": "bmcpfs-xxxxxxxxxxx", "path": "/mnt", "mountTarget": "cpfs-xxxxxxxxxxxx-vpc-gacs9f.cn-wulanchabu.cpfs.aliyuncs.com", "isVpcMount": true }

Edition

string

The type of the dataset. Enumeration values:

  • BASIC: Basic. Does not support file metadata management for datasets.

  • ADVANCED: Advanced. Supported only for OSS datasets. Each version supports metadata management for up to 1 million files.

BASIC

IsShared

boolean

Indicates whether the dataset is a shared dataset.

Valid values:

  • false :

    false

  • true :

    true

false

SharedFrom DatasetShareRelationship

The source relationship of the shared dataset. This parameter is valid only when IsShared is true.

SharingConfig

object

The sharing configurations of the current dataset.

SharedTo

array

The sharing configuration relationships.

DatasetShareRelationship

The sharing configuration relationship of the shared dataset.

Examples

Success response

JSON format

{
  "RequestId": "5A14FA81-DD4E-******-6343FE44B941",
  "DatasetId": "d-rbvg5wz****c9ks92",
  "Name": "myName",
  "Description": "用于标注的数据。",
  "GmtCreateTime": "2021-01-30T12:51:33.028Z",
  "GmtModifiedTime": "2021-01-30T12:51:33.028Z",
  "UserId": "2485765****023475",
  "OwnerId": "1631044****3440",
  "Property": "DIRECTORY",
  "DataSourceType": "NAS",
  "Uri": "nas://09f****f2.cn-hangzhou/",
  "Labels": [
    {
      "Key": "env",
      "Value": "test"
    }
  ],
  "DataType": "COMMON",
  "SourceType": "USER",
  "SourceId": "jdnhf***fnrimv",
  "WorkspaceId": "478**",
  "Options": "{\n  \"mountPath\": \"/mnt/data/\"\n}",
  "Accessibility": "PRIVATE",
  "ProviderType": "Ecs",
  "Provider": "pai",
  "SourceDatasetId": "d-rcdg3wxxxxxhc5jk87\n",
  "SourceDatasetVersion": "v2",
  "TagTemplateType": "TextClassification",
  "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": "RW",
  "MountAccessReadWriteRoleIdList": [
    "PAI.AlgoOperator"
  ],
  "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",
    "AllowedMountAccessLevels": [
      "RO"
    ],
    "IsSecureMode": true,
    "SharedAt": "2025-08-27T12:23:58Z",
    "ExpiresAt": "2026-08-27T12:23:58Z"
  },
  "SharingConfig": {
    "SharedTo": [
      {
        "Status": "ACTIVE",
        "SourceTenantId": "148***************115",
        "SourceWorkspaceId": "33**19",
        "TenantId": "153***************249",
        "WorkspaceId": "42**2",
        "AllowedMountAccessLevels": [
          "RO"
        ],
        "IsSecureMode": true,
        "SharedAt": "2025-08-27T12:23:58Z",
        "ExpiresAt": "2026-08-27T12:23:58Z"
      }
    ]
  }
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.