![]() |
REST API
17
REST API for Luna Network HSMs
|
Submits a test payload to allow administrator to create test logs to initiate trap notifications.
Users with the following role privileges can perform this command:
Specifies the log facility to use when generating the test message. Valid values: kern, user, daemon, auth, syslog, authpriv, cron, local0, local1, local2, local3, local4, local5, local6, local7
Use: Required
JSON Schema:
Object type: string minLength: 4 maxLength: 8 pattern: ^(kern|user|daemon|auth|syslog|authpriv|cron|local0|local1|local2|local3|local4|local5|local6|local7)$
Specifies the severity level to assign to the test message. Valid values: emergency, alert, critical, crit, error, err, warning, warn, notice, info, debug
Use: Required
JSON Schema:
Object type: string minLength: 3 maxLength: 9 pattern: ^(emergency|alert|critical|crit|error|err|warning|warn|notice|info|debug)$
Specifies the system process to use when generating the test message. Valid values: Any process defined for the system. For example, NTLS, impievd, smartd, sysstatd.
Use: Required
JSON Schema:
Object type: string minLength: 1 maxLength: 32 pattern: ^[a-zA-Z0-9_]+$
A string that specifies the body text for the test message.
Use: Required
JSON Schema:
Object
type: string
minLength: 1
maxLength: 128
pattern: ^[a-zA-Z0-9_ $()[]{}*+./^!<>#%,:=@~?'-]*$
Add a process identifier to the test message.
Use: Not Required
JSON Schema:
Object type: Boolean
Success
Returned when the input data does not conform to the required validation schema.
No session cookie was found.
Failed to perform the specified operation.
POST
https://1.2.3.4:8443/api/lunasa/snmp/traps/test
{
"logFacility": "local0",
"logLevel": "info",
"process": "snmpd",
"message": "This is a test message",
"pid": true
}
{
}