Use the Helios APIs in Python
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs
helios
tests
.gitignore
LICENSE
MANIFEST.in
README.md
examples.py
setup.cfg
setup.py

README.md

Helios - SDK - Python

Documentation PyPI license

Use the Helios APIs in Python.

Helios® weather analytics from Harris Corporation provide fast and accurate local ground weather intelligence to assist organizations with real-time decision making. Helios analyzes content from thousands of existing public and private video cameras, providing immediate confirmation of ground weather condition changes at a detailed local level.

For more information visit helios.earth.

Interacting with the Helios APIs.

This example creates an instance of the Cameras API, queries for New York cameras and then parses the camera IDs from the resulting GeoJSON information.

import helios

cameras = helios.Cameras()

# Retrieve GeoJSON Feature Collection for New York state cameras.
ny_cams = cameras.index(state='New York')

# Gather the camera IDs from the results.

# Combines all id attributes from each GeoJSON feature using a convenience property.
ny_cams_ids = ny_cams.id

# Alternatively, you can iterate and extract individual fields from each feature.
ny_cams_ids_2 = [x.id for x in ny_cams.features]

Installation

To install the Helios SDK use one of the following two methods:

  • Install the Helios SDK from PyPI:
pip install helios-sdk
  • For the bleeding edge, install from the GitHub source:
git clone https://github.com/harris-helios/helios-sdk-python.git

Then cd to the helios-sdk-python folder and run the install command:

cd helios-sdk-python
pip install .

Authentication

All Helios API methods require valid authentication and are protected using the OAuth 2.0 "client credentials" flow. The general process for authenticating requests involves first requesting an access token using the developer API key pair, and then requesting protected data using the access token. Request access if you would like to obtain an API key.

Using Environment Variables

  1. Add "helios_client_id": "your ID key"
  2. Add "helios_client_secret": "your secret key"
  3. Add "helios_api_url": "API URL associated with your account credentials"
    • "helios_api_url" is optional.

Using an Authentication File

  1. Create a ".helios" directory in your home directory.

  2. Create a "credentials.json" file in the ".helios" directory.

  3. Copy and paste the following into the "credentials.json" file and fill in your credentials:

    • "helios_api_url" is optional. If you do not need a custom API URL, then leave this out of your json file or set to null.
    {
    	"helios_client_id" : "your ID key" ,
    	"helios_client_secret" : "your secret key",
    	"helios_api_url" : null
    }

Documentation