POST zstack/v1/accesskeys
Authorization: OAuth the-session-uuid
{ "params": { "accountUuid": "db517023502d34ef9309e49674af88d0", "userUuid": "019f0d7b414b31d98a8de6cab4a8b999" }, "systemTags": [], "userTags": [] }
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \ -X POST -d '{"params":{"accountUuid":"db517023502d34ef9309e49674af88d0","userUuid":"019f0d7b414b31d98a8de6cab4a8b999"}}' http://localhost:8080/zstack/v1/accesskeys
Name | Type | Location | Description | Optional Value | Starting Version |
---|---|---|---|---|---|
accountUuid | String | body (contained in the params structure) | The account UUID. | 3.2.0 | |
userUuid | String | body (contained in the params structure) | The user UUID. | 3.2.0 | |
description | String | body (contained in the params structure) | Optional. The detailed description of the resource. | 3.2.0 | |
AccessKeyID | String | body (contained in the params structure) | Optional. The generated AccessKey ID. | 3.7.0 | |
AccessKeySecret | String | body (contained in the params structure) | Optional. The generated AccessKey Secret. | 3.7.0 | |
resourceUuid | String | body (contained in the params structure) | Optional. | 3.2.0 | |
systemTags | List | body | Optional. | 3.2.0 | |
userTags | List | body | Optional. | 3.2.0 |
{ "inventory": { "uuid": "01f82a92a3f83136b3a5fa13b0f1dde6", "accountUuid": "bc81e5aad7363ebaa904ee81edbfdd1f", "userUuid": "20e90349268736d7950284d122f64213", "AccessKeyID": "1234567890abcdedfhij", "AccessKeySecret": "1234567890abcdedfhij1234567890abcdedfhij", "state": "Enabled" } }
Name | Type | Description | Starting Version |
---|---|---|---|
error | ErrorCode | The error code. If not null, the operation fails, or vice versa. For more information, see error. | 3.2.0 |
inventory | AccessKeyInventory | See inventory. | 3.2.0 |
Name | Type | Description | Starting Version |
---|---|---|---|
code | String | The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001. | 3.2.0 |
description | String | The brief description of the error. | 3.2.0 |
details | String | The details about the error. | 3.2.0 |
elaboration | String | The reserved field. Default value: null. | 3.2.0 |
opaque | LinkedHashMap | The reserved field. Default value: null. | 3.2.0 |
cause | ErrorCode | The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null. | 3.2.0 |
Name | Type | Description | Starting Version |
---|---|---|---|
uuid | String | The resource UUID. | 3.2.0 |
description | String | The detailed description of the resource. | 3.2.0 |
accountUuid | String | The account UUID. | 3.2.0 |
userUuid | String | The user UUID. | 3.2.0 |
AccessKeyID | String | 3.2.0 | |
AccessKeySecret | String | 3.2.0 | |
createDate | Timestamp | The creation date. | 3.2.0 |
lastOpDate | Timestamp | The last operation date. | 3.2.0 |
state | AccessKeyState | See state. | 3.2.0 |
Name | Type | Description | Starting Version |
---|---|---|---|
name | String | The resource name. | 3.2.0 |
ordinal | int | 3.2.0 |
CreateAccessKeyAction action = new CreateAccessKeyAction(); action.accountUuid = "db517023502d34ef9309e49674af88d0"; action.userUuid = "019f0d7b414b31d98a8de6cab4a8b999"; action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"; CreateAccessKeyAction.Result res = action.call();
CreateAccessKeyAction action = CreateAccessKeyAction() action.accountUuid = "db517023502d34ef9309e49674af88d0" action.userUuid = "019f0d7b414b31d98a8de6cab4a8b999" action.sessionId = "b86c9016b4f24953a9edefb53ca0678c" CreateAccessKeyAction.Result res = action.call()
DELETE zstack/v1/accesskeys/{uuid}?deleteMode={deleteMode}
Authorization: OAuth the-session-uuid
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \ -X DELETE http://localhost:8080/zstack/v1/accesskeys/7fcbb0096e3d3e2a8dd4f83610d3dac9?deleteMode=Permissive
Name | Type | Location | Description | Optional Value | Starting Version |
---|---|---|---|---|---|
uuid | String | url | The AccessKey UUID. | 3.2.0 | |
deleteMode | String | url | Optional. | 3.2.0 | |
systemTags | List | body | Optional. | 3.2.0 | |
userTags | List | body | Optional. | 3.2.0 |
{ "error": { "code": "SYS.1001", "description": "A message or a operation timeout", "details": "Create VM on KVM timeout after 300s" } }
DeleteAccessKeyAction action = new DeleteAccessKeyAction(); action.uuid = "7fcbb0096e3d3e2a8dd4f83610d3dac9"; action.deleteMode = "Permissive"; action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"; DeleteAccessKeyAction.Result res = action.call();
DeleteAccessKeyAction action = DeleteAccessKeyAction() action.uuid = "7fcbb0096e3d3e2a8dd4f83610d3dac9" action.deleteMode = "Permissive" action.sessionId = "b86c9016b4f24953a9edefb53ca0678c" DeleteAccessKeyAction.Result res = action.call()
GET zstack/v1/accesskeys GET zstack/v1/accesskeys/{uuid}
Authorization: OAuth the-session-uuid
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \ -X GET http://localhost:8080/zstack/v1/accesskeys?q=uuid=fc008e53779632989bf9393ecf074e25
curl -H "Content-Type: application/json;charset=UTF-8" \ -H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \ -X GET http://localhost:8080/zstack/v1/accesskeys/f99c1aea4a6e35e4a88c6abfe11cce8d
Queryable Fields
You can check all queryable fields and resource names that can be queried across tables by using zstack-cli, entering QueryAccessKey, and pressing the Tab key.
{ "inventories": [ { "uuid": "12be3dd32afa3cf2afa4c06037f218b7", "accountUuid": "324ecf74dd5c3b9a9f2b75edfdbd858f", "userUuid": "49c0bc4cfa6d3a67930fe4a4cc32248c", "AccessKeyID": "1234567890abcdedfhij", "AccessKeySecret": "1234567890abcdedfhij1234567890abcdedfhij", "state": "Enabled" } ] }
Name | Type | Description | Starting Version |
---|---|---|---|
error | ErrorCode | The error code. If not null, the operation fails, or vice versa. For more information, see error. | 3.2.0 |
inventories | List | See inventories. | 3.2.0 |
Name | Type | Description | Starting Version |
---|---|---|---|
code | String | The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001. | 3.2.0 |
description | String | The brief description of the error. | 3.2.0 |
details | String | The details about the error. | 3.2.0 |
elaboration | String | The reserved field. Default value: null. | 3.2.0 |
opaque | LinkedHashMap | The reserved field. Default value: null. | 3.2.0 |
cause | ErrorCode | The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null. | 3.2.0 |
Name | Type | Description | Starting Version |
---|---|---|---|
uuid | String | The resource UUID. | 3.2.0 |
description | String | The detailed description of the resource. | 3.2.0 |
accountUuid | String | The account UUID. | 3.2.0 |
userUuid | String | The user UUID. | 3.2.0 |
AccessKeyID | String | 3.2.0 | |
AccessKeySecret | String | 3.2.0 | |
createDate | Timestamp | The creation date. | 3.2.0 |
lastOpDate | Timestamp | The last operation date. | 3.2.0 |
state | AccessKeyState | See state. | 3.2.0 |
Name | Type | Description | Starting Version |
---|---|---|---|
name | String | The resource name. | 3.2.0 |
ordinal | int | 3.2.0 |
QueryAccessKeyAction action = new QueryAccessKeyAction(); action.conditions = asList("uuid=f0c530f17978349faa8c4736accd0375"); action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"; QueryAccessKeyAction.Result res = action.call();
QueryAccessKeyAction action = QueryAccessKeyAction() action.conditions = ["uuid=ee3c98b8528e3fe2aa9d817cd48b1358"] action.sessionId = "b86c9016b4f24953a9edefb53ca0678c" QueryAccessKeyAction.Result res = action.call()
Back to Top
Email Us
contact@zstack.ioEmail Us
contact@zstack.ioEmail Us
contact@zstack.ioThe download link is sent to your email address.
If you don't see it, check your spam folder, subscription folder, or AD folder. After receiving the email, click the URL to download the documentation.Thank you for using ZStack products and services.
Submit successfully.
We'll connect soon.Thank you for using ZStack products and services.