Data Streamer

Compatibility notes: The Data Streamer is under active development. It’s regularly updated for performance and quality improvements so that you’re able to gain rich insights into the event and usage data when using the Event API or a data stream. If you’ve built custom integrations, you should expect that additional data may be added in the future. emnify recommends using mature and tested libraries designed for parsing or reading JSON for custom integrations to ensure compatibility.

Data properties

Data types are referred to in the following sections to assist with integration or database schemas. They should be interpreted as follows:

TypeDescription
IntegerAn integer value usually used for entity IDs, won’t exceed 32-bit values.
LongFor event and usage data record IDs, a 64 bit long value should be expected.
Booleantrue or false
StringA string value enclosed in " double quotation characters.
Decimal(14,6)Used for data volume measurements (volume.total, volume.tx, volume.rx) with 6 decimal places.
Decimal(14,10)Cost calculation (cost property) may have up to 10 decimal places.
TimestampTimestamp property in UTC enclosed in " double quotation characters.

Event object

See the Events Reference page.

Usage object

The following table shows the properties in a usage data record. These properties are included in all records, independent of traffic type:

PropertyTypeDescription
idLongUnique identifier of the usage data record.
traffic_typeJSON objectType of traffic (that is, data or SMS) (see Traffic type object).
start_timestampTimestampStart time of the reported service consumption.
end_timestampTimestampEnd time of the reported service consumption.
organisationJSON objectOrganization associated with the usage data record (see Organization object).
endpointJSON objectDevice details (see Endpoint object).
simJSON objectSIM details (see SIM object).
imsi_idIntegerUnique identifier of the active IMSI when service was consumed.
imsiStringInternational mobile subscriber identity (IMSI). The unique number identifying the currently active IMSI of the SIM.
session_idStringSession UUID for correlating PDP context events and usage record objects.
tariffJSON objectInformation about the tariff assigned to the device (see Tariff object).
operatorJSON objectMobile network operator (MNO) details (see Operator object).
volumeJSON objectVolume consumed in a PDP context (see Volume object).
costDecimal(14,10)Estimated cost calculation with up to 10 decimal places. This value represents either excess costs accrued or an estimation based on the assigned pay-as-you-go tariff (cost per MB).
currencyJSON objectCost currency details.

Traffic type object

PropertyTypeDescription
idIntegerUnique identifier of the traffic type, either 5 (Data) or 6 (SMS).
descriptionStringString representation of the traffic type, either "Data" or "SMS"

Tariff object

PropertyTypeDescription
idIntegerUnique identifier of the tariff used by the device.
nameStringName of the tariff.
ratezoneJSON objectDetails of the coverage area used by the device.

Operator object

PropertyTypeDescription
idLongUnique identifier of the mobile network operator (MNO) used.
nameStringName of the MNO.
countryJSON objectCountry of the MNO (see Country object).
mncJSON arrayList of mobile network codes (MNC) of the MNO used (see MNC array)