get https://api.thethings.io/v2/me/resources/?subscribe=true&keepAlive=
Endpoint to subscribe to the real-time updates. Once subscribed, you will receive a message each time that the resource receives a new value.
If there are no updates the server will send {} after the interval you specified for keepAlive. You should also keep a timer, and if you don’t receive updates after the keepAlive time is expired, yo have to resubscribe. This could happen if the Wi-Fi is down or something happens to the connection.
To subscribe from a browser we recommend to use Websocket. REST API subscription is not reliable on browsers.