Skip to main content
System Management/System Settings/SNMP
GETSNMPSince 4.10.0SynchronousAuth Required

Query SNMP Agent

Query SNMP Agent

Execution Availability

Try It Out

Submit a mock request using the current auth context and example-driven inputs.

Request Inputs

This API requires no request parameters.

Responses

200 OK

On success, this API returns the following response structure.

  • successbooleanRequired

    操作是否成功。

  • errorErrorCodeRequired

    Error code. If not null, the operation failed. This field is null when the operation succeeds. See error

    • codeStringRequired

      Error code number. A globally unique identifier for the error, e.g., SYS.1000, HOST.1001

    • descriptionStringRequired

      Brief description of the error

    • detailsStringRequired

      Detailed error information

    • elaborationStringRequired

      Reserved field. Defaults to null

    • opaqueLinkedHashMapRequired

      Reserved field. Defaults to null

    • causeErrorCodeRequired

      Root error. The source error that caused this error. Null if no root cause exists

  • inventoriesListRequired

    See inventories

    • uuidStringRequired

      Resource UUID. Uniquely identifies the resource

    • versionStringRequired

      SNMP agent protocol version

    • readCommunityStringRequired

      Read community string (used when version is v2c)

    • userNameStringRequired

      Username (used when version is v3)

    • authAlgorithmStringRequired

      Authentication algorithm

    • authPasswordStringRequired

      Authentication password

    • privacyAlgorithmStringRequired

      Privacy algorithm

    • privacyPasswordStringRequired

      Privacy password

    • portintRequired

      Port

    • statusStringRequired

      Whether the SNMP agent is enabled

    • securityLevelStringRequired

      Security level

    • createDateTimestampRequired

      Creation time

    • lastOpDateTimestampRequired

      Last modification time

Endpoint

GET/zstack/v1/snmp/agent

/zstack/v1/snmp/agent

Operation ID

QuerySnmpAgent

Permalink

Request Example

curl -X GET 'http://{host}/zstack/v1/snmp/agent' -H 'Authorization: OAuth {sessionUuid}'

Response Example

200
{ "inventories": [ { "uuid": "f0ef8d847b573c6b86565e1d9111723b", "version": "v3", "userName": "zstack", "authAlgorithm": "SHA512", "authPassword": "auth_password", "privacyAlgorithm": "DES", "privacyPassword": "priv_password", "port": 161, "status": "Enable", "securityLevel": "authPriv" } ] }

Change History

This API has no change history records yet.

View all change history