Authentication overview
Authentication within the Helium network ensures that only authorized devices transmit data and that only authorized applications can interact with network services. Given Helium's decentralized nature as a “network of networks,” the authentication processes differ slightly depending on whether a user is operating a Hotspot, a data-transmitting device, or an application interacting with the network via an API. The core principle involves proving ownership or control over specific resources, primarily Data Credits for data transmission and API keys for programmatic access to network management tools.
For devices sending data on Helium's LoRaWAN network (Helium IOT), authentication relies on a combination of device identity and the availability of Data Credits (DC). These DCs are a utility token pegged to the US dollar and issued by burning Helium Network Tokens (HNT) at a fixed rate, as described in the official Helium Data Credits documentation. Every packet transmitted consumes a small amount of DC. This approach decentralizes authentication by linking usage directly to a fungible resource rather than a centralized authority.
For developers building applications that interface with Helium’s infrastructure, such as managing devices, monitoring Hotspots, or retrieving data, traditional API key-based authentication is typically employed. These keys provide programmatic access to endpoints that facilitate interaction with the network's various components, including the Helium Console or other backend services. The specific method for obtaining and using these keys is detailed in the respective service's documentation.
Supported authentication methods
Helium primarily supports two distinct authentication paradigms, tailored to different use cases within its decentralized ecosystem:
- Data Credits (DC) for device-level data transmission: This method is fundamental for any device sending data over the Helium LoRaWAN network. Devices do not have traditional usernames and passwords; instead, their ability to transmit data is authenticated by the presence and consumption of Data Credits associated with their registered Organization in the Helium Console. Each data packet sent consumes DC, effectively authenticating the right to use network bandwidth.
- API Keys for application-level access: For developers and organizations building applications that manage devices, integrate with third-party platforms, or retrieve network data, API keys serve as the primary authentication mechanism. These keys are generated within the Helium Console or similar management interfaces and are used to authorize requests to specific API endpoints.
Authentication Method Comparison
| Method | When to Use | Security Level |
|---|---|---|
| Data Credits (DC) | Device transmitting data over Helium IOT (LoRaWAN) | High (cryptographically secured by tokenomics) |
| API Keys | Applications managing devices, integrating services, or accessing network data programmatically | Moderate to High (depends on key management and transport security) |
Getting your credentials
The process for obtaining credentials depends on the type of interaction with the Helium network:
For Data Credits (DC)
- Acquire HNT: Helium Network Tokens (HNT) are traded on various cryptocurrency exchanges. Users must first acquire HNT.
- Burn HNT to create Data Credits: Within the Helium Wallet app or through the Helium Console, HNT can be "burned" to produce Data Credits. This is a one-way conversion. The official Helium documentation on acquiring Data Credits provides detailed steps.
- Associate DC with an Organization: Data Credits are typically managed within an Organization on the Helium Console, which then allocates them to devices for data transfer.
For API Keys
- Create a Helium Console Account: Navigate to the Helium Console and sign up for an account if you don't already have one.
- Create an Organization: Within the Console, create or select an existing Organization.
- Generate an API Key: In your Organization settings or a dedicated API section within the Helium Console, locate the option to generate a new API key. The Console interface provides instructions on key scope and permissions.
- Store the Key Securely: Once generated, the API key will be displayed. It is critical to copy and store this key securely, as it typically cannot be retrieved again after initial generation. Refer to the Helium Console API Keys guide for specific instructions.
Authenticated request example
For API-based authentication, an API key is commonly passed in the Authorization header of an HTTP request. The following example demonstrates a hypothetical authenticated request to a Helium Console API endpoint using a Bearer token scheme. The actual endpoint and payload would vary based on the specific Helium API being called.
curl -X GET \
'https://console.helium.com/api/v1/organizations/{organization_id}/devices' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'Content-Type: application/json'
In this example:
YOUR_API_KEYshould be replaced with the actual API key generated from your Helium Console.{organization_id}should be replaced with your specific organization identifier.- The
Authorization: Bearerheader is a standard method for passing API tokens or access tokens, specified by RFC 6750 for Bearer Token Usage.
Security best practices
Adhering to security best practices is essential when working with Helium authentication credentials to protect your devices, data, and network resources:
- API Key Management:
- least privilege: Only grant your API keys the minimum necessary permissions required for the tasks they perform. Avoid using superuser keys for routine operations.
- Rotate Keys Regularly: Periodically generate new API keys and revoke old ones. This minimizes the impact if a key is compromised.
- Environment Variables/Secret Management: Never hardcode API keys directly into your application code. Use environment variables (e.g., in a
.envfile) or a dedicated secret management service (e.g., AWS Secrets Manager, Google Secret Manager) to store and retrieve keys securely. This prevents keys from being exposed in source control. - Secure Transport: Always use HTTPS for all API communications to ensure that API keys are encrypted in transit and not susceptible to eavesdropping.
- IP Whitelisting: If supported by the Helium Console API, restrict API key usage to a specific set of trusted IP addresses. This adds an extra layer of security, ensuring that even if a key is stolen, it can only be used from authorized locations.
- Data Credit (DC) Management:
- Monitor DC Usage: Regularly check your Data Credit balance and consumption patterns. Unexpected spikes could indicate unauthorized device activity or misconfigured devices.
- Budgeting: Set realistic budgets for Data Credit usage to prevent unexpected depletion and ensure continuous device operation.
- Wallet Security:
- Secure your HNT Wallet: As HNT is used to generate Data Credits, protecting your HNT wallet is paramount. Use strong, unique passwords for your wallet, enable two-factor authentication (2FA) if available, and keep your seed phrase or private keys offline and in a secure location.
- Hardware Wallets: For significant amounts of HNT, consider using a hardware wallet for enhanced security against software-based threats.
- Device Security:
- Secure Device Firmware: Ensure that your IoT devices are running the latest, most secure firmware versions.
- Physical Security: Protect physical access to your devices to prevent tampering that could compromise their ability to securely transmit data or interact with the network.
- GDPR Compliance:
- For applications handling user accounts, ensure compliance with data protection regulations such as GDPR. This includes transparent data handling, consent mechanisms, and secure storage of any personal data processed through your Helium-connected applications.