This URL creates/updates the syslog configuration for faults notification.
Resource URL
PUT /domain/<domain_id>/notification/faults/syslog
Request Parameters
URL Request Parameters:
| Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| domain_id | Domain id | Int | Yes |
Payload Parameter
Details of SyslogNotification:
| Field Name | Description | Data Type |
|---|---|---|
| enableSyslog | Enable syslog notification | Boolean |
| parentAndChildDomain | Parent and child domain | Boolean |
| serverIp | Server IP address | String |
| serverPort | Server port | Number |
| facilities | Facilities | String |
| severity | Severity mapping | Object |
| forwrdResults | Forward results | String |
| Message | Message | String |
Details of severity mapping:
| Field Name | Description | Data Type |
|---|---|---|
| inforamtionTo | Information mapping | String |
| warningTo | Warning mapping | String |
| errorTo | Error mapping | String |
| criticalTo | Critical mapping | String |
Response Parameters
Following fields are returned if the request parameters are correct, otherwise error details are returned.
| Field Name | Description | Data Type |
|---|---|---|
| status | Set to 1 if the operation was successful | Number |
Example
Request
PUT https://<NSM_IP>/sdkapi/domain/0/notification/faults/syslog
Request Payload
{
"enableSyslog": true,
"parentAndChildDomain": true,
"serverIp": "1.1.1.2",
"serverPort": 515,
"facilities": "CLOCK_DAEMON_NOTE_2",
"severityMapping":
{
"informationTo": "EMERGENCY_SYSTEM_UNUSABLE",
"errorTo": "EMERGENCY_SYSTEM_UNUSABLE",
"warningTO": "EMERGENCY_SYSTEM_UNUSABLE",
"criticalTo": "EMERGENCY_SYSTEM_UNUSABLE"
},
"forwrdResults": "INFORMATIONAL_AND_ABOVE",
"message": "$IV_ACK_INFORMATION$ $IV_ADMIN_DOMAIN$ $IV_DESCRIPTION$"
}
Error Information
Following error codes are returned by this URL:
| No | HTTP Error Code | SDK API errorId | SDK API errorMessage |
|---|---|---|---|
| 1 | 404 | 1105 | Invalid domain |
| 2 | 400 | 1725 | Invalid facilities |
| 3 | 400 | 1726 | Invalid severity mapping |
| 4 | 400 | 1727 | Invalid forward results |