VM Related Interfaces
Get Spice CA Certificates
Headers
Authorization: OAuth the-session-uuidCurl Example
curl -H "Content-Type: application/json;charset=UTF-8" \
-H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \
-X GET http://localhost:8080/zstack/v1/spice/certificatesParameter List
| Name | Type | Location | Description | Allowed Values | Starting Version |
|---|---|---|---|---|---|
| systemTags (Optional) | List | query | 3.7.0 | ||
| userTags (Optional) | List | query | 3.7.0 |
API Response
Response Example
{
"certificateStr": "-----BEGIN CERTIFICATE-----\nMIIDVTCCAj2gAwIBAgIJALGiHgRCxwkwMA0GCSqGSIb3DQEBCwUAeEExCzAJBgNV\nBAYTAkNOMREwDwYDVQQHDAhTaGFuZ2hhaTEPMA0GA1UECgwGWlN0YWNrMQ4wDAYD\nVQQDDAVteSBDQTAeFw0xOTA5MjQwNjMxMzBaFw0yOTA5MjEwNjMxMzBaMEExCzAJ\nBgNVBAYTAkNOMREwDwYDVQQHDAhTaGFuZ2hhaTEPMA0GA1UECgwGWlN0YWNrMQ4w\nDAYDVQQDDAVteSBDQTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALQq\nHgcza7xK7zQ+zPNrzR3q1JJHkQ/OPF+DH5gheGlwfruWaGtAwVX9w0vfKDHCJ0BB\ndMQ4m1r2OX0yONVXNmlUnwq5VMdieqyO/1r41cHauqUTP6MkJ5/yD7ipfZP0r7sB\ngFAUIwaSdZk4hwnPou2ah4Uk/9yd0thBHKYCYZoVldLyPIe7aUHmkdkRY+MMdzqj\nGnspV1K7ux8xP3zG7CUG9Ns64rrjGNLRu81IJTYaJSigZ1ykZu1eYsUcGHB2QDcE\n4d9fw/8YaRVJOsBsABEzj9Qvi81i6VdTCGg2oFjBrSgcF7tNVQDufZLgXw3rlIsE\n+1+pwh5CgcviRcNTue0CAwEAAaNQME4wHQYDVR0OBBYEFMNx0BYaStgcpq1s30tW\nmAwjlqXaMB8GA1UdIwQYMBaAFMNx0BYaStgcpq1s30tWmAwjlqXaMAwGA1UdEwQF\nMAMBAf8wDQYJKoZIhvcNAQELBQADggEBAAxDDzO8LDwI31sCr2K2t2P3n/hkxh0w\nnycRxKho9DFTnKSmMlusSd1AY/SjWO8+6dSi4wzmkJ/Zr0CeOBYhbDCFxG/OKO1K\nSfuR+gqZOAx8gB58Zk51KUxyYV3HKoRPftIh4nFO+mFUMXDuttuh12L7kbSQ6U3v\nL0uFg/59PnYe+aU+R/K1xXyZGViZJbgDqPDsCZYug0IRupu9j2Sces3XcX2TMCGR\nxPo2ZzBrOs3rJCK2nx16tHS5Zr5VP7zdn1YCS1/0HYUHRpi3HJPZAUR6dzDuK0IU\nPb0ufTldT6UOgJTof6TPMVl8dZATlJqMrjPtAOe3PtOKo8TPdjtQ15I=\n-----END CERTIFICATE-----"
}| Name | Type | Description | Starting Version |
|---|---|---|---|
| success | boolean | 0.6 | |
| certificateStr | String | Spice CA certificate | 3.7.0 |
| error | ErrorCode | Error code. If not null, the operation failed. When the operation succeeds, this field is null. For details, see error | 3.7.0 |
error
| Name | Type | Description | Starting Version |
|---|---|---|---|
| code | String | Error code number, a globally unique identifier of the error, for example SYS.1000, HOST.1001 | 3.7.0 |
| description | String | Brief description of the error | 3.7.0 |
| details | String | Detailed error information | 3.7.0 |
| elaboration | String | Reserved field, defaults to null | 3.7.0 |
| opaque | LinkedHashMap | Reserved field, defaults to null | 3.7.0 |
| cause | ErrorCode | Root cause. The error that triggered the current error. If there is no original error, this field is null | 3.7.0 |
SDK Examples
Java SDK
GetSpiceCertificatesAction action = new GetSpiceCertificatesAction();
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c";
GetSpiceCertificatesAction.Result res = action.call();Python SDK
GetSpiceCertificatesAction action = GetSpiceCertificatesAction()
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"
GetSpiceCertificatesAction.Result res = action.call()