Nope. It’s easier than you think
def sendRequest() {
TRACE("sendRequest()")
def httpRequest = [
method: settings.httpMethod,
path: settings.httpResource,
headers: [
HOST: state.networkAddr,
Accept: "*/*",
]
]
def hubAction = new physicalgraph.device.HubAction(httpRequest)
sendHubCommand(hubAction)
}
where ‘state.networkAdd’ is IP:PORT in dotted notation.