Mengkueri kelompok host yang diizinkan atau tidak diizinkan dikelola oleh pengguna bastion host.
Coba sekarang
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
yundun-bastionhost:ListHostGroupsForUser |
get |
*全部资源
|
None | None |
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| InstanceId |
string |
Yes |
ID bastion host yang penggunanya ingin Anda kueri. Catatan
Anda dapat memanggil operasi DescribeInstances untuk mengkueri ID bastion host. |
bastionhost-cn-st220aw**** |
| RegionId |
string |
No |
ID wilayah bastion host yang penggunanya ingin Anda kueri. Catatan
Untuk Pemetaan antara ID wilayah dan nama wilayah, lihat Regions and zones. |
cn-hangzhou |
| Mode |
string |
No |
Kategori kelompok host yang akan dikueri. Nilai valid:
|
Authorized |
| UserId |
string |
Yes |
ID pengguna. Catatan
Anda dapat memanggil operasi ListUsers untuk mengkueri ID pengguna. |
1 |
| PageNumber |
string |
No |
Nomor halaman. Nilai default: 1. |
1 |
| PageSize |
string |
No |
Jumlah entri per halaman. Catatan
Jangan mengosongkan parameter ini. |
20 |
| HostGroupName |
string |
No |
Nama kelompok host yang akan dikueri. Panjang nama maksimum 128 karakter. Hanya pencocokan persis yang didukung. |
group |
Semua operasi API Alibaba Cloud harus menyertakan parameter permintaan umum. Untuk informasi selengkapnya tentang parameter permintaan umum, lihat Common request parameters. Untuk contoh permintaan, lihat Sample requests.
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
|||
| TotalCount |
integer |
The total number of host groups returned. |
1 |
| RequestId |
string |
The request ID. |
EC9BF0F4-8983-491A-BC8C-1B4DD94976DE |
| HostGroups |
array<object> |
The host groups returned. |
|
|
object |
|||
| HostGroupId |
string |
The host group ID. |
1 |
| Comment |
string |
The remarks of the host group. |
comment |
| HostGroupName |
string |
The name of the host group. |
group |
Contoh
Respons sukses
JSONformat
{
"TotalCount": 1,
"RequestId": "EC9BF0F4-8983-491A-BC8C-1B4DD94976DE",
"HostGroups": [
{
"HostGroupId": "1",
"Comment": "comment",
"HostGroupName": "group"
}
]
}
Kode kesalahan
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidParameter | The argument is invalid. | |
| 500 | InternalError | An unknown error occurred. |
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.