I just posted syntax for the cli under the heading:
Do we have an API to delete files from the flash of the controller?
But it looks something like this:
apiPath = '/caasapi/v1/exec/cmd'
apiMethod = 'POST'
apiParams = {
'group_name': '{0}/{1}'.format('CENTRALGROUPNAME', '00:00:00:00:00:00') <- this is the central group and device mac
}
apiData = {
'cli_cmds': ["hostname TESTROUTER", "!", "interface vlan 2", "ip address 10.0.0.1 255.255.255.128", "!"]} <- a list of the commands to execute