Skip to main content

Live events

GET /events/stream

A long-lived Server-Sent Events stream of what your readers are seeing, as it happens. It's the same feed that drives Live Reads in the hub. Use it instead of polling when you need to react to tags arriving or moving.

Connecting​

Authenticate with your API key as usual and keep the connection open:

curl -N https://hub.titanrfid.com/api/v1/events/stream \
-H "Authorization: Bearer $KEY" \
-H "Accept: text/event-stream"

The first thing you receive is a hello event, which confirms you're connected:

event: hello
data: {}

After that, each message is an event: line naming the type and a data: line holding JSON, followed by a blank line.

Event types​

tag_read​

Sent when a reader starts seeing a tag, then again periodically while the tag stays in view.

event: tag_read
data: {"epc":"E2801160600002084F1A3C21","tagId":"0b7f0b8e-…","label":"BRK-2210","attrs":{"sku":"BRK-2210"},"readerId":"3c9a2f61-…","antennaPort":1,"zoneId":"9d2e4f60-…","zoneName":"Receiving","rssiCdbm":-5250,"lastSeen":"2026-10-10T14:03:22.418Z","readCount":184}
Field
epc, tagIdThe tag.
labelThe tag's name (its name field). Absent if it has none.
attrsThe tag's values for fields shown in tables. Absent if none.
readerId, antennaPortWhich reader and port saw it.
zoneId, zoneNameThe zone that antenna watches. Absent if the port isn't mapped.
rssiCdbmRecent signal strength in hundredths of a dBm (-5250 is −52.5 dBm). This is a smoothed average, not the peak.
lastSeenWhen it was last read.
readCountReads of this tag on this antenna during this stretch of presence.

tag_moved​

Sent when a tag's location changes to a different zone. This is the event to use if you want to know "where is it now?".

event: tag_moved
data: {"tagId":"0b7f0b8e-…","epc":"E2801160600002084F1A3C21","label":"BRK-2210","fromZoneId":"9d2e4f60-…","toZoneId":"2a3b4c5d-…","zoneName":"Goods Out","at":"2026-10-10T14:05:40.000Z"}

fromZoneId is absent the first time a tag is placed. zoneName is the name of the zone it moved to.

Other events​

You may also see session events, which Titan uses internally to track when a tag starts and stops being seen on an antenna. Their format isn't documented and may change, so ignore them. Treat any event type you don't recognise the same way.

Building a reliable consumer​

  • Reconnect when the stream drops, with a short delay. Network equipment, proxies and our deployments will all close long-lived connections from time to time.
  • Events aren't replayed. Anything that happens while you're disconnected isn't sent when you reconnect. After reconnecting, catch up from the regular endpoints, such as GET /tags for current zones or GET /inventory/summary.
  • Read promptly. Titan doesn't queue events for a slow consumer. If your client stops reading, events for it are dropped. Do the heavy work off the reading thread.
  • The stream contains only your organisation's data.
  • Alerts aren't on this stream. Poll GET /alerts for those.

In a browser, the built-in EventSource can't send an Authorization header. The stream is meant for server-side integrations, so keep API keys off the browser.