Jetstream API
...
API Endpoints
Event Configuration

Get Events

6min

About

Return, but do not dequeue, the oldest pending event messages for the Jetstream user whose access key is being used. By default, no more than 100 messages will be returned on any given Get Events request.

Users must subscribe to Get Events by making an initial Get Events request with the applicable user access key. This initial subscription request will not return any events, as events are not queued until the subscription is created. Users will be automatically unsubscribed after 30 days of not making a Get Events request.

Each Get Events request returns a batch of event messages along with an associated batch ID. By using this batch ID with a Delete Events request, all events within this batch can be quickly removed.

Parameters

Property

Location

Details

AccessKey

string Required Unique

Header

The access key for your user account.

This value is a 36-character GUID provided in your user profile.

Limit

int

URL

The number of messages to return.

This value is a number within the following range: 1 - 512

This property is optional and does not need to be defined in all requests. If it is not defined, the value defaults to 100.

Type

string Searchable

URL

The event type.

Device

string Searchable

URL

The name of the device.

EventVersion

int Searchable

URL

The version of events returned.

Device events will have the version of 2. These are the device event: AggregateEvent, ObjectEvent, CommandCompletionEvent, HeartbeatEvent, LogEntryEvent, and SensorReadingEvent. All other events will have the version of the API that was called to generate them.

Example

Request URL

GET https://api.jetstreamrfid.com/3/events/5

Request Body

None Required

Response Code

200 OK

Response Body

{ "BatchId": "c15d316b-5fc3-4a7f-a2ba-b1a96aabcd32", "Count": 5, "Events": [ { "CommandId": "2bf00848-b06a-4820-86fc-58c12e08ee3e", "CommandName": "SetConfigValuesCommand", "OutputParameterList": [], "ExceptionList": [], "Device": "MyDeviceName1", "ReceivedTime": "2018-05-19T01:16:23Z", "Type": "CommandCompletionEvent", "EventId": "93723c89-cb44-44f0-8d86-87ede0fb3ba6", "EventTime": "2018-05-19T01:16:19Z", "Version":2 }, { "Device": "MyDeviceName1", "CommandId": "2bf00848-b06a-4820-86fc-58c12e08ee3e", "CommandName": "SetConfigValuesCommand", "URI": "/2/Devices/MyDeviceName1/policy/sync", "Verb": "Post", "User": "MyUserName", "Parameters": [ { "Key": "aggregateeventscancount", "Value": "4" } ], "Type": "CommandQueuedEvent", "EventId": "f3df515b-c53a-4b3b-b3e9-01ffe6ffd8f3", "EventTime": "2018-05-19T01:16:21Z", "Version":3 }, { "Device": "MyDeviceName2", "ReceivedTime": "2018-05-19T01:19:44Z", "Type": "HeartbeatEvent", "EventId": "b55cf245-4a17-438e-8b12-538c3ef6f536", "EventTime": "2018-05-19T01:19:43Z", "Version":3 }, { "Device": "MyDeviceName1", "ReceivedTime": "2018-05-19T02:05:40Z", "Type": "HeartbeatEvent", "EventId": "9e5d2294-655e-4a11-ba02-e504b435e75f", "EventTime": "2018-05-19T02:05:36Z", "Version":3 }, { "SensorReadings": [ { "Name": "TemperatureA", "Value": "-16", "ReadingTime": "2018-05-19T02:06:25Z" }, { "Name": "TemperatureB", "Value": "-61", "ReadingTime": "2018-05-19T02:06:25Z" } ], "Device": "MyDeviceName1", "ReceivedTime": "2018-05-19T02:06:28Z", "Type": "SensorReadingEvent", "EventId": "66524199-0c71-40d2-a36a-c05983b70355", "EventTime": "2018-05-19T02:06:25Z", "Version":3 } ] }

Version Changes

Added Version Property to Events.