All Products
Search
Document Center

Data Management:ListUsers

Last Updated:Jun 11, 2026

Mengkueri detail pengguna.

Coba sekarang

Coba API ini di OpenAPI Explorer tanpa perlu penandatanganan manual. Panggilan yang berhasil akan secara otomatis menghasilkan contoh kode SDK sesuai dengan parameter Anda. Unduh kode tersebut dengan kredensial bawaan yang aman untuk penggunaan lokal.

Test

RAM authorization

Tabel berikut menjelaskan otorisasi yang diperlukan untuk memanggil API ini. Anda dapat menentukannya dalam kebijakan Resource Access Management (RAM). Kolom pada tabel dijelaskan sebagai berikut:

  • Action: Aksi yang dapat digunakan dalam elemen Action pada pernyataan kebijakan izin RAM untuk memberikan izin guna melakukan operasi tersebut.

  • API: API yang dapat Anda panggil untuk melakukan aksi tersebut.

  • Access level: Tingkat akses yang telah ditentukan untuk setiap API. Nilai yang valid: create, list, get, update, dan delete.

  • Resource type: Jenis resource yang mendukung otorisasi untuk melakukan aksi tersebut. Ini menunjukkan apakah aksi tersebut mendukung izin tingkat resource. Resource yang ditentukan harus kompatibel dengan aksi tersebut. Jika tidak, kebijakan tersebut tidak akan berlaku.

    • Untuk API dengan izin tingkat resource, jenis resource yang diperlukan ditandai dengan tanda bintang (*). Tentukan Nama Sumber Daya Alibaba Cloud (ARN) yang sesuai dalam elemen Resource pada kebijakan.

    • Untuk API tanpa izin tingkat resource, ditampilkan sebagai All Resources. Gunakan tanda bintang (*) dalam elemen Resource pada kebijakan.

  • Condition key: Kunci kondisi yang didefinisikan oleh layanan. Kunci ini memungkinkan kontrol granular, berlaku baik hanya untuk aksi maupun untuk aksi yang terkait dengan resource tertentu. Selain kunci kondisi spesifik layanan, Alibaba Cloud menyediakan serangkaian common condition keys yang berlaku di semua layanan yang didukung RAM.

  • Dependent action: Aksi dependen yang diperlukan untuk menjalankan aksi tersebut. Untuk menyelesaikan aksi tersebut, pengguna RAM atau role RAM harus memiliki izin untuk melakukan semua aksi dependen.

Action

Access level

Resource type

Condition key

Dependent action

dms:ListUsers

list

*全部资源

*

None None

Parameter permintaan

Parameter

Type

Required

Description

Example

Tid

integer

No

ID penyewa. Anda dapat memanggil operasi GetUserActiveTenant untuk memperoleh ID penyewa.

3***

Role

string

No

Peran pengguna. Nilai yang valid:

  • USER

  • DBA

  • ADMIN

  • SECURITY_ADMIN

  • STRUCT_READ_ONLY

Catatan

Anda dapat melihat peran Anda di sudut kanan atas konsol DMS.

DBA

UserState

string

No

Status pengguna. Nilai yang valid:

  • NORMAL

  • DISABLE

  • DELETE

NORMAL

SearchKey

string

No

Kata kunci yang digunakan untuk mencari pengguna. Pencocokan fuzzy didukung.

test

PageNumber

integer

No

Nomor halaman yang akan dikembalikan.

1

PageSize

integer

No

Jumlah entri yang akan dikembalikan pada setiap halaman.

Catatan

Nilai yang valid: 10, 20, 50, dan 100. Nilai default: 10.

10

Elemen respons

Element

Type

Description

Example

object

TotalCount

integer

Jumlah total entri yang dikembalikan.

3

RequestId

string

ID permintaan.

69161997-6030-53BA-A333-DBEC83B732FF

ErrorCode

string

Kode kesalahan.

InvalidTid

ErrorMessage

string

Pesan kesalahan.

Specified parameter Tid is not valid.

UserList

object

User

array<object>

Detail pengguna.

array<object>

Detail pengguna.

State

string

The status of the user. Valid values:

  • NORMAL: The user is normal.

  • DISABLE: The user is disabled.

  • DELETE: The user is deleted.

NORMAL

CurResultCount

integer

The number of rows that were queried on the current day.

0

UserId

string

The ID of the user.

8****

LastLoginTime

string

The time when the user last logged on to the console.

2021-11-08 13:43:43

MaxResultCount

integer

The maximum number of rows that can be queried on the current day.

50000

ParentUid

string

The ID of the Alibaba Cloud account of the user.

140692647406****

RoleIdList

object

RoleIds

array

The IDs of the roles.

integer

The ID of the role that is assigned to the user. Valid values:

  • 1: a regular user role.

  • 2: a DBA role.

  • 3: a DMS administrator role.

  • 4: a security administrator role.

  • 6: a schema read-only user role.

3

RoleNameList

object

RoleNames

array

The names of roles.

string

The name of the role that is assigned to the user. Valid values:

  • USER: a regular user.

  • DBA : a DBA.

  • ADMIN: a DMS administrator.

  • SECURITY_ADMIN: a security administrator.

  • STRUCT_READ_ONLY: a schema read-only user.

ADMIN

NickName

string

The nickname of the user.

test_NickName

MaxExecuteCount

integer

The maximum number of queries that can be performed on the current day.

2000

CurExecuteCount

integer

The number of queries that were performed on the current day.

0

Mobile

string

The mobile phone number of the user.

Catatan
  • The system returns this parameter if you have set a mobile phone number in the console. To set a mobile phone number in the console, move the pointer over the profile picture in the upper-right corner and click the Edit icon next to Notice.

  • The system does not return this parameter if you have not set a mobile phone number.

1389999****

Uid

string

The ID of the Alibaba Cloud account.

167382665015****

Email

string

The email address that is used to receive notifications.

Catatan
  • The system returns this parameter if you have set an email address in the console. To set an email address in the console, move the pointer over the profile picture in the upper-right corner and click the Edit icon next to Notice.

  • The system does not return this parameter if you have not set an email address.

username@example.com

DingRobot

string

The DingTalk chatbot URL that is used to receive notifications.

Catatan
  • The system returns this parameter if you have set a DingTalk chatbot URL in the console. To set a DingTalk chatbot URL in the console, move the pointer over the profile picture in the upper-right corner and click the Edit icon next to Notice.

  • The system does not return this parameter if you have not set a DingTalk chatbot URL.

https://XXX.dingtalk.com/robot/send?access_token=9b7a4a562cbe7fcdea9962afac7b9d7b4504d564948083419750f9cafa78e4ef

Webhook

string

The webhook URL that is used to receive notifications.

Catatan
  • If you have set a webhook URL, DMS sends notifications to the specified URL.

  • The system does not return this parameter if you have not set a webhook URL.

http://dms-XXX.aliyun.com:8***

SignatureMethod

string

The signature method that is used to secure connections when a webhook URL is used. Valid values:

  • NONE: no signature.

  • HMAC_SHA1: HMAC_SHA1.

HMAC_SHA1

NotificationMode

string

The notification method. The system returns one or more values. Valid values:

  • SMS: text message

  • EMAIL: email.

  • DINGDING: DingTalk.

  • DINGROBOT: DingTalk chatbot.

  • WEBHOOK: webhook.

DINGROBOT

Success

boolean

Menunjukkan apakah permintaan berhasil. Nilai yang valid:

  • true: Permintaan berhasil.

  • false: Permintaan gagal.

true

Contoh

Respons sukses

JSONformat

{
  "TotalCount": 3,
  "RequestId": "69161997-6030-53BA-A333-DBEC83B732FF",
  "ErrorCode": "InvalidTid",
  "ErrorMessage": "Specified parameter Tid is not valid.",
  "UserList": {
    "User": [
      {
        "State": "NORMAL",
        "CurResultCount": 0,
        "UserId": "8****",
        "LastLoginTime": "2021-11-08 13:43:43",
        "MaxResultCount": 50000,
        "ParentUid": "140692647406****",
        "RoleIdList": {
          "RoleIds": [
            3
          ]
        },
        "RoleNameList": {
          "RoleNames": [
            "ADMIN"
          ]
        },
        "NickName": "test_NickName",
        "MaxExecuteCount": 2000,
        "CurExecuteCount": 0,
        "Mobile": "1389999****",
        "Uid": "167382665015****",
        "Email": "username@example.com",
        "DingRobot": "https://XXX.dingtalk.com/robot/send?access_token=9b7a4a562cbe7fcdea9962afac7b9d7b4504d564948083419750f9cafa78e4ef",
        "Webhook": "http://dms-XXX.aliyun.com:8***",
        "SignatureMethod": "HMAC_SHA1",
        "NotificationMode": "DINGROBOT"
      }
    ]
  },
  "Success": true
}

Kode kesalahan

Lihat Error Codes untuk daftar lengkap.

Catatan rilis

Lihat Release Notes untuk daftar lengkap.