Dispatch STOMP topics
You can connect to a websocket endpoint and subscribe to receive STOMP messages when tows change or when devices (tow drivers) move.
Very little data is sent in the STOMP message itself, instead receiving the stomp message should trigger you to make a request to one of our /dispatch endpoints.
/topic/dispatch.activeTows.{regionCode}
/topic/dispatch.activeTow.{towId}
/topic/device.location.{deviceId}
Â
Â
Â
/topic/dispatch.activeTows.{regionCode}
would trigger a call to /towInfo/active/{regionCode}
/topic/dispatch.activeTow.{towId}
would trigger a call to /towInfo/{towId}
though this returns the same data as the call to /towInfo/active/{regionCode}
just for a single tow
/topic/device.location.{deviceId}
is actually an outlier in that it actually sends the device location in the push. This one should only be used if you want really up to time locations for that device, otherwise just subscribe to /topic/dispatch.activeTows.{regionCode}
and then you’ll get notified when the ETA changes.