Dahua HTTP API questions

2ndLeaf

Young grasshopper
Dec 13, 2018
50
16
California
It appears I can use getConfig to get any configuration, as long as I know the exact configuration parameters. For example, I can get QoS configuration by the following get request:


I will get the following output:
table.Qos.Commands=0
table.Qos.LiveVideo=0

But if I send the following get request:

I will get the following error:
Error
Bad Request!

Does anybody know is there any way to set configuration?

Also if I use the following get request to backup configuration:

I will be prompted to enter a file name. Then all configurations will be saved to that file. I thought there should be an API to restore the configuration from a file. However, I can't find one. Does anybody know if such API exists?

Dahua API has a restore config API. In the API doc, it has the following example:


When I try it, it simply returns ok. Where does this API restore the configuration from?
 
Last edited:
setConfig syntax:
Code:
http://ip-address/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<paramName>=<paramValue>…]

Code:
http://ip-address/cgi-bin/configManager.cgi?action=setConfig&Qos.Commands=0
 
  • Like
Reactions: TonyR and 2ndLeaf
setConfig syntax:
Code:
http://ip-address/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<paramName>=<paramValue>…]

Code:
http://ip-address/cgi-bin/configManager.cgi?action=setConfig&Qos.Commands=0

Cool. That works! Thanks for the reply.