Changes

Line 175: Line 175:     
</font>
 
</font>
 +
 +
====Setting Multiple Parameters====
 +
 +
This next example describes how to set multiple parameters in a single config file, in this case, changes the default DHCP server values with custom ones:
 +
 +
{
 +
    "jsonrpc":"2.0", "id":1, "method":"call", "params":
 +
    [
 +
        "558a9b03c940e52f373f8c02498952e3", "uci", "set",
 +
        {
 +
            "config":"dhcp", "type":"dhcp", "match":
 +
    {
 +
    "start":"<span style=color:orange>100</span>",
 +
    "limit":"<span style=color:orange>150</span>",
 +
    "leasetime":"<span style=color:orange>12h</span>"
 +
},
 +
"values":
 +
                        {
 +
          "start":"<span style=color:orange>75</span>",
 +
    "limit":"<span style=color:orange>100</span>",
 +
    "leasetime":"<span style=color:orange>6h</span>"
 +
                        }
 +
        }
 +
    ]
 +
}
 +
The command above will change the router's DHCP Server's current Start address, Address limit and Lease time values (highlighted in orange) to custom values provided in the '''"values"''' section of the command (highlighted in green).

Navigation menu