TECHZEN Zenoss User Community ARCHIVE  

JSON API - addMaintWindow - Paramaters

Subject: JSON API - addMaintWindow - Paramaters
Author: Kamesh Murugan
Posted: 2018-11-12 05:09

Hello All,

Looking for the available parameters for JSON API "addMaintWindow" Method which is under "devicemanagementrouter" class. Its not available in the below document.

Zenoss JSON API 6.2.0

I have tried with the below parameters and its not working in 6.2 version

uid,name,startTime,repeat,startProductionState,enabled

------------------------------
Kamesh
------------------------------


Subject: RE: JSON API - addMaintWindow - Paramaters
Author: Steve Aiello
Posted: 2018-11-13 08:56

There is an example that can be found in the zenoss-RM-api github repo under the examples directory, DeviceManagementRouter_addMaintWindow_SysArgv.py.

For reference here is an example of the raw JSON http post:
{
	"action": "DeviceManagementRouter",
	"method": "addMaintWindow",
	"data": [{
			"params": {
				"uid": "/zport/dmd/Devices/Web/devices/test1",
				"id": "",
				"name": "APICreatedMaintWin1",
				"enabled": true,
				"startDate": "07/26/2017",
				"startHours": "12",
				"startMinutes": "45",
				"durationDays": "0",
				"durationHours": "8",
				"durationMinutes": "0",
				"repeat": "Daily",
				"startProductionState": 300
			}
		}
	],
	"tid": 1
}


------------------------------
Steve Aiello
Zenoss
------------------------------


< Previous
Cannot open zenoss
  Next
ZenApiLib updates
>