Network Events

Comprehensive guide to Network Events provided by the 1NCE Data Streamer, including Network Events, PDP Context Events, Quota Events, and SIM Management Events.

Network Events

The 1NCE Data Streamer Service provides a real-time stream of Network Events from your IoT devices and network infrastructure. These Network Events give you comprehensive visibility into device connectivity, location updates, data usage, quota management, and system activities. The exact format of the Network Events depends on the integration used, but this chapter focuses on the JSON Object format delivered by the Data Streamer.

Network Events are categorized into several types:


Network Event Structure Overview

All Network Events share a common structure with the following main components:


Example Network Events

Here are sample Network Events from different categories showing the JSON structure delivered by the Data Streamer:

{
  "id": 12345678,
  "timestamp": "2024-12-13T12:49:57.000Z",
  "event_type": {
    "id": 1,
    "description": "Update location"
  },
  "event_severity": {
    "id": 0,
    "description": "INFO"
  },
  "event_source": {
    "id": 0,
    "description": "Network"
  },
  "organisation": {
    "id": 100018,
    "name": "81013181"
  },
  "alert": false,
  "description": "New location received from VLR for IMSI = '901405105682328', now attached to VLR = '491720215095'",
  "sim": {
    "id": 10000106,
    "iccid": "8988228066605682328",
    "msisdn": "882285105682328"
  },
  "imsi": {
    "id": 100000106,
    "imsi": "901405105682328"
  },
  "endpoint": {
    "id": 100000325,
    "imei": "8697060538230193",
    "name": "8988228066605682328",
    "ip_address": "10.0.0.180"
  },
  "detail": {
    "id": 3,
    "name": "Vodafone",
    "country": {
      "id": 74,
      "mcc": "262",
      "name": "Germany",
      "iso_code": "de",
      "country_code": "49"
    },
    "mnc": [
      {
        "id": 3,
        "mnc": "02"
      }
    ],
    "tapcode": [
      {
        "id": 2,
        "tapcode": "DEUD2"
      }
    ]
  }
}

Generic Properties

Generic Properties are fields that are always included in a Network Event JSON message received via the Data Streamer. These properties provide essential information about every Network Event.

PropertyData TypeDescription
idLONG (64 bit)Unique ID for each Network Event sent. Duplicate received Network Event IDs indicate possible retransmissions.
timestampTIMESTAMP (UTC)Timestamp with date and time of the Network Event occurrence in the ISO 8601 format.
event_typeJSON ObjectObject with an id and a description about the occurred Network Event. See Event Types for a list of all possible values.
event_severityJSON ObjectJSON object with an id and a description about the severity of the Network Event. See Event Severity for a list of all possible values.
event_sourceJSON ObjectAn id and a description about the source of the Network Event. See Event Source for a list of all possible values.
organisationJSON ObjectObject with the ID and the name of the organization. See Event Organization for more information.
alertBOOLEANNetwork Events with a high impact on connectivity operation are flagged as an Alert.
descriptionSTRINGString with a human readable description of the Network Event.
Event Types

The different types of Network Events are indicated by the Event Type nested object. This object contains an ID and a short description of the Network Event. The following table lists all possible Event Types that can be received via the Data Streamer.

Event IDDescription
1Update location
2Update GPRS location
3Create PDP Context
4Update PDP Context
5Delete PDP Context
8SIM activation
9SIM suspension
11Endpoint blocked
15Purge location
16Purge GPRS location
18Quota Threshold Reached
19Quota used up
20SMS Quota Threshold Reached
21SMS quota used up
29OpenVPN disconnect
30OpenVPN authentication
42Endpoint enabled
43Endpoint disabled
52Data quota enabled
53Data quota disabled
54SMS quota enabled
55SMS quota disabled
56Data quota assigned
57Data quota deleted
58SMS quota assigned
59SMS quota deleted
60Data quota expired
61SMS quota expired
100Regional Pool Data Quota used up
101Regional Pool Data Quota Threshold Reached
102Regional Pool SMS Quota used up
103Regional Pool SMS Quota Threshold Reached
121Endpoint deleted
Event Severity

The severity levels of a Network Event indicate what impact the Network Event has on the correct operation of the system. The possible Event Severity values are listed below:

Severity IDDescription
0INFO
1WARN
2WARN
3ERROR
4CRITICAL
Event Source

Based on the Event Type, a different originating Event Source might be responsible for triggering the Network Event. The possible sources consisting of an ID and a Description are listed below.

IDDescription
0Network
1Policy Control
2API
Event Organization

Each Network Event includes information about the originating organization. This helps to identify the organization in the use case of multiple Data Streamer for sub organizations. The JSON property fields of this object are listed below.

PropertyData TypeDescription
idINTEGERUnique identifier of the organization
nameSTRINGName of the organization

Additional Properties

Network Events that directly relate to SIMs, Endpoints, or Users might include some of the following optional properties.

PropertyData TypeDescription
imsiJSON ObjectInternational Mobile Subscriber Identity, see IMSI Object for more information.
simJSON ObjectSubscriber Identification Module, see SIM Object for more information.
endpointJSON ObjectEndpoint/Device information object, see Endpoint Object for more information.
userSTRINGUser identifier if the Network Event was triggered by a specific user action.
IMSI Object

The International Mobile Subscriber Identity is used to identify each device with a SIM. The following parameters are included in a Network Event.

PropertyData TypeDescription
idINTEGERUnique ID of the IMSI.
imsiSTRINGThe International Mobile Subscriber Identity as String.
SIM Object

Each SIM card has unique properties and parameters. This data is included in the Network Event stream. A list of the available data fields is shown below.

PropertyData TypeDescription
idINTEGERUnique ID of the SIM.
iccidSTRINGIntegrated Circuit Card Identifier of the SIM.
msisdnSTRINGMobile Subscriber ISDN of the SIM Card.
Endpoint Object

As a SIM is placed inside a device, some information about this endpoint is transferred via the mobile network. This information is useful to identify the specific device type and certain connection parameters. A list of all Endpoint Objects is listed below.

PropertyData TypeDescription
idINTEGERUnique ID of the Endpoint.
nameSTRINGName of the Endpoint configuration.
ip_addressSTRINGSpecific static IP Address of the SIM card/Endpoint.
tagsSTRINGAny Tags assigned to the Endpoint.
imeiSTRINGInternational mobile equipment identity of the Endpoint/Device with the SIM.

Detail Properties

For certain Network Event Types, additional information parameters are added in the Detail Properties. The content varies based on the Network Event Type and provides specific context for that Network Event category.

Network Detail Properties

Network Events include operator and country information in their detail properties.

PropertyData TypeDescription
idINTEGERUnique ID for the used mobile network operator.
nameSTRINGName of the mobile network operator.
countryJSON ObjectCountry of the mobile network operator. See Country Object for more information.
mncARRAYArray of Mobile Network Code objects with id and mnc fields.
tapcodeARRAYArray of TAP code objects with id and tapcode fields.
PDP Context Detail Properties

PDP Context Events include comprehensive information about the data session in their detail properties.

PropertyData TypeDescription
idINTEGERUnique ID for the used mobile network operator.
nameSTRINGName of the mobile network operator.
countryJSON ObjectCountry of the mobile network operator. See Country Object for more information.
pdp_contextJSON ObjectObject with details about the PDP Context. See PDP Context Object for more information.
Quota Detail Properties

Quota Events include quota information and optionally regional pool details.

PropertyData TypeDescription
quotaJSON ObjectObject with details about the quota. See Quota Object for more information.
regional_poolJSON ObjectObject with regional pool information (for regional pool Network Events).
VPN Detail Properties

VPN Events include client and connection information.

PropertyData TypeDescription
vpn_idINTEGEROSS VPN ID
regionSTRINGAWS region code
clientJSON ObjectObject with version, private_ip, and public_ip fields
Country Object

A nested JSON object inside the Detail Properties contains more information about the country where the SIM Network Event took place. The fields of the Country JSON are listed below.

PropertyData TypeDescription
id INTEGERUnique ID of a country.
name STRINGName of the country.
country_code STRINGCountry Code
mccSTRINGMobile Country Code (MCC)
iso_code STRINGISO Country Code
PDP Context Object

A Network Event for a PDP Context includes a wide range of additional information in the Detail Properties. The individual fields are listed below.

PropertyData TypeDescription
pdp_context_idINTEGERID of the PDP Context
tunnel_createdTIMESTAMP (UTC)Creation time of the PDP Session
gtp_versionINTEGERGTP Version 1/2
ggsn_control_plane_ip_addressSTRINGIP Address of GGSN/PGW Control Plane
ggsn_data_plane_ip_addressSTRINGIP Address of GGSN/PGW Data Plane
sgsn_control_plane_ip_addressSTRINGIP Address of SGSN/SGW Control Plane
sgsn_data_plane_ip_addressSTRINGIP Address of SGSN/SGW Data Plane
regionSTRINGRegion of the Data Plane
breakout_ipSTRINGIP Address used for the Internet Breakout
apnSTRINGAccess Point Name (APN)
nsapiINTEGERNetwork Service Access Point Identifier (NSAPI)
ue_ip_addressSTRINGIP address of the device
imeisvSTRINGInternational Mobile Equipment Identity - Software version
mccSTRINGMobile Country Code (MCC)
mncSTRINGMobile Network Code (MNC)
lacINTEGERLocation Area Code (LAC)
sacINTEGERService Area code (SAC)
racINTEGERRouting Area code (RAC)
ciINTEGERCell Identification (CI)
rat_typeINTEGERRadio Access Type (RAT)
1 - 3G
2 - 2G
5 - HSPA+
6 - LTE
8 - NB-IoT
9 - CAT-M
gtp_v1_uliJSON ObjectGTP V1 User Location Information with lac, ci, sac, rac fields
gtp_v2_uliJSON ObjectGTP V2 User Location Information with cgi, sai, rai, tac, eci, lac, menbi, emenbi fields
tx_teid_data_planeINTEGERPGW/GGSN TEID user_plane
tx_teid_control_planeINTEGERPGW/GGSN TEID control_plane
rx_teidINTEGERReceived Tunnel Endpoint Identifier
tariff_idSTRINGTariff identifier
operator_idSTRINGOperator identifier
ratezone_idSTRINGRate zone identifier
ipcan_session_idSTRINGIP-CAN session identifier
Quota Object

Quota Events include detailed information about quota status and usage. The content description of the fields is listed below.

PropertyData TypeDescription
idINTEGERUnique quota identifier
volumeDECIMALRemaining volume (can be negative if exceeded)
total_volumeDECIMALTotal allocated volume
accumulated_total_volumeDECIMALSum of all quota allocations
last_volume_addedDECIMALMost recent quota addition
serviceSTRINGService type: "data" or "sms"
thresholdJSON ObjectObject with volume and percentage fields for threshold settings
threshold_percentageINTEGERPercentage threshold (0-100)
threshold_volumeDECIMALCalculated threshold volume
expiry_dateTIMESTAMP (UTC)When the quota expires
created_atTIMESTAMP (UTC)When the quota was created
statusJSON ObjectObject with id and description for quota status

Network Event Categories

Network Events are organized into the following functional categories:

Network Events

Network Events track device location changes and network attachments.

Update Location (ID: 1)

  • Sent when endpoint changes CS (Circuit Switched) network location
  • Includes VLR attachment information

Update GPRS Location (ID: 2)

  • Sent when endpoint changes PS (Packet Switched) network location
  • Includes SGSN attachment information

Purge Location (ID: 15)

  • Sent when CS network location information is cleaned up

Purge GPRS Location (ID: 16)

  • Sent when PS network location information is cleaned up
PDP Context Events

PDP Context Events track the lifecycle of data sessions.

Create PDP Context (ID: 3)

  • Sent when endpoint establishes a data session
  • Includes comprehensive PDP context details
  • Also sent for IMEI lock violations

Update PDP Context (ID: 4)

  • Sent when data session is updated
  • Includes updated PDP context information

Delete PDP Context (ID: 5)

  • Sent when data session is terminated
  • Includes final PDP context state
SIM Management Events

SIM Management Events track SIM lifecycle and status changes.

SIM Activation (ID: 8)

  • Sent when SIM status changes to activated

SIM Suspension (ID: 9)

  • Sent when SIM status changes to suspended/disabled

Endpoint Enabled (ID: 42)

  • Sent when endpoint status is set to enabled

Endpoint Disabled (ID: 43)

  • Sent when endpoint status is set to disabled

Endpoint Blocked (ID: 11)

  • Sent when endpoint is blocked (e.g., monthly limit exceeded)

Endpoint Deleted (ID: 121)

  • Sent when endpoint is deleted from organization
Quota Events

Quota Events track data and SMS quota management and usage.

Data Quota Events

  • Data quota enabled/disabled (ID: 52/53)
  • Data quota assigned/deleted (ID: 56/57)
  • Data quota expired (ID: 60)
  • Quota threshold reached (ID: 18)
  • Quota used up (ID: 19)

SMS Quota Events

  • SMS quota enabled/disabled (ID: 54/55)
  • SMS quota assigned/deleted (ID: 58/59)
  • SMS quota expired (ID: 61)
  • SMS quota threshold reached (ID: 20)
  • SMS quota used up (ID: 21)

Regional Pool Events

  • Regional pool data/SMS quota used up (ID: 100/102)
  • Regional pool data/SMS quota threshold reached (ID: 101/103)
System Events

System Events track infrastructure and service activities.

VPN Events

  • OpenVPN authentication (ID: 30)
  • OpenVPN disconnect (ID: 29)

These Network Events include VPN client details and connection information.


Network Event Processing

When processing Network Events from the Data Streamer:

  1. Check Network Event ID: Use the unique id field to detect retransmissions
  2. Monitor Alerts: Pay attention to Network Events where alert is true
  3. Filter by Severity: Use event_severity to focus on critical issues
  4. Track Organizations: Use organisation to separate multi-tenant scenarios
  5. Parse Detail Properties: Extract Network Event-specific information from the detail object based on Network Event type