Query ZCE-X and Third-party Alert Platform Relationship

GET/zstack/v1/zce-x-plugin/alert-platform

Headers

Authorization: OAuth the-session-uuid

Curl Example

curl -H "Content-Type: application/json;charset=UTF-8" \
-H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \
-X GET http://localhost:8080/zstack/v1/zce-x-plugin/alert-platform?q=zceXUuid=77e1393bf5aa4536a018b4c0c4e29c72

Queryable Fields

Run the CLI command tool, enter QueryZceX and press Tab to view all queryable fields and resource names that can be queried across tables.

API Response

Response Example

{
  "inventories": [
    {
      "zceXUuid": "77e1393bf5aa4536a018b4c0c4e29c72",
      "thirdPartyPlatformUuid": "eec32b6fe11a464790641439f1d7c754",
      "createDate": "Nov 14, 2017 2:20:57 PM"
    }
  ]
}
NameTypeDescriptionStarting Version
successbooleanWhether the query was successful4.10.6
inventoriesListFor details, see inventories4.10.6
errorErrorCodeError code. If not null, the operation failed. If null, the operation succeeded. For details, see error4.10.6

inventories

NameTypeDescriptionStarting Version
zceXUuidStringZCE-X resource UUID4.10.6
thirdPartyPlatformUuidStringAssociated third-party alert platform UUID4.10.6
createDateTimestampCreation time4.10.6

error

NameTypeDescriptionStarting Version
codeStringError code number, globally unique identifier of the error, for example SYS.1000, HOST.10014.10.0
descriptionStringBrief summary of the error4.10.0
detailsStringDetailed error information4.10.0
elaborationStringReserved field, defaults to null4.10.0
opaqueLinkedHashMapReserved field, defaults to null4.10.0
causeErrorCodeRoot cause: the source error that triggered the current error. If there is no original error, this field is null4.10.0

SDK Examples

Java SDK

QueryZceXThirdPartyPlatformAlertRefAction action = new QueryZceXThirdPartyPlatformAlertRefAction();
action.conditions = asList("zceXUuid=77e1393bf5aa4536a018b4c0c4e29c72");
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c";
QueryZceXThirdPartyPlatformAlertRefAction.Result res = action.call();

Python SDK

QueryZceXThirdPartyPlatformAlertRefAction action = QueryZceXThirdPartyPlatformAlertRefAction()
action.conditions = ["zceXUuid=77e1393bf5aa4536a018b4c0c4e29c72"]
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"
QueryZceXThirdPartyPlatformAlertRefAction.Result res = action.call()