Skip to main content

Lightning API Guide

Classic API

The Lightning API is a Classic API and does not follow the consolidated Core Platform standards. The Core Platform Guides (including global authentication, error handling, and rate limits) do not apply to this service. Please follow the instructions provided in this guide.

Analyze historical electrical activity and storm tracks for infrastructure impact or forensic reporting. This API allows you to retrieve precise strike locations, types, and intensities for both New Zealand and global regions over the last 24 hours. It serves as a comprehensive, searchable archive of detected lightning activity, essential for post-event damage assessment.

The API provides two complementary access modes:

  1. Historical strikes via REST (up to 24 hours in the past)
  2. Real-time strikes via WebSocket

Access Control & Coverage

All API access is secured using credentials (API key or short-lived tokens) associated with an approved geographical bounding box.

Requests may specify a wider bounding box, but only strikes falling within the key’s approved area will be returned.

Authentication

Two authentication methods are available:

API Key (Direct)

  • HTTPx-api-key request header
  • WebSocketAUTHENTICATE message containing the API key

We recommend using short-lived tokens instead of exposing your private API key directly.

Token Generation

POST /auth/token

Headers

x-api-key: <PRIVATE_API_KEY>

Body

{
"type": "http" | "ws" | "universal"
}

Token types

  • http → usable for HTTP requests only
  • ws → usable for WebSocket authentication only
  • universal → usable for both HTTP and WebSocket

Tokens are valid for 5 minutes.

Support

If you have any questions, require configuration changes, or wish to request an expanded geographical area, please visit our Support Centre or contact the team.