This URL exports the Sensor configuration to an xml file.
Resource URL
PUT /sensor/<sensor_id>/ exportconfiguration
Request Parameters
URL Parameters:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Sensor id | Number | Yes |
Payload Request Parameters:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| The details of what to export from sensor | Object | Yes |
Details of SensorConfigExportElement:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Location as to where to store the file | String | Yes |
| Export failover configuration | Boolean | No |
| Export firewall configuration | Boolean | No |
| Export SSL configuration | Boolean | No |
| Export exceptions configuration | Boolean | No |
| Export exceptions configuration | Boolean | No |
| Export monitoring ports configuration | Boolean | No |
| Export NTBA configuration | Boolean | No |
Response Parameters
Following fields are returned if the request parameters are correct, otherwise error details are returned.
Field Name | Description | Data Type |
|---|---|---|
| Set to 1 if the operation was successful | Number |
Example
Request
PUT https://<NSM_IP>/sdkapi/sensor/1002/exportconfiguration
Payload
{
"exportFirewallConfig": true,
"exportMonitoringPortConfig": true,
"exportFOConfig": true,
"exportNACConfig": true,
"exportSSLConfig": true,
"exportExceptionsConfig": true,
"fileDestination": "C:\\sensorconfigexport\\sensorAPIallTRUE",
"exportNTBAConfig": true
}
Response
{
"status": 1
}
Error Information
Following error codes are returned by this URL:
No | HTTP Error Code | SDK API errorId | SDK API errorMessage |
|---|---|---|---|
1 | 404 | 1106 | Invalid Sensor |
2 | 400 | 5308 | No destination file specified |