Skip to content

kiskolabs/air-back

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 

AirBack

A simple Sinatra backend for fetching air quality data from the Netatmo API.

Features

  • Exchange a username & password for an access token
  • Refreshes the access token before it expires
  • Caches the tokens in Redis
  • Fetch current air quality data for all registered devices
  • Fetch data for the past hour for the given device ID
  • Measurement responses are automatically cached in Redis

Requirements

Developing

  1. Clone the repo
  2. Install dependencies with bundle install
  3. Create a .env.local file in the root of the project:
export NETATMO_CLIENT_ID="IDIDIDIDIDIDIDIDID"
export NETATMO_CLIENT_SECRET="SECRETSECRETSECRET"
export NETATMO_USERNAME="you@example.com"
export NETATMO_PASSWORD="superpassword"
  1. Start the Sinatra app: rackup

About

The backend for the air quality dashboard

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •