Using httpPost in smart app


(Vinny Carvalho) #1

Hi there, I started writing my first app, and I wasn’t able to make a post to a local machine on my network.

Looking a bit more into the guts of smart apps it appears that apps could be running in the cloud or in the hub (I have the latest)

Is this the case? My app would not be able to send a request to an internal IP address known only at my LAN?

Thanks


(Ule) #2

Hi

The custom apps run in server, but the hub can upload the data from local, try to search apiPost


(Vinny Carvalho) #3

I found HubAction class and sendHubAction method that solves my problems :slight_smile: http://docs.smartthings.com/en/latest/cloud-and-lan-connected-device-types-developers-guide/building-lan-connected-device-types/building-the-device-type.html#making-outbound-http-calls-with-hubaction