SetConfigPorts
Apply a batch JSON configuration to multiple ports.
GoUint8 SetConfigPorts(char* jsonInfo, GoInt jsonInfoLen)
Parameters
jsonInfo: JSON buffer mapping ports to config objects.
jsonInfoLen: Length of jsonInfo in bytes.
Return Value
GoUint8: 0 on success.
JSON Structure Example:
// JSON Structure
{
60000: {
"port": 60000,
"country": ["US", "CA"],
"state": "California",
"city": "San Francisco",
"zip": "94105",
"isp": "Comcast",
"refresh": true, // áp dụng tự động refresh
"rotation": false // áp dụng cho rotation
}
}
Example
// example
SetConfigPorts((char*)j, (GoInt)strlen(j));
Last updated
Was this helpful?