SpaceAPI


The spaceapi component allow Hackerspaces to expose information to web apps or any other application with the SpaceAPI.

Configuration

To setup the spaceapi component in your installation, add the following to your configuration.yaml file:

# Example configuration.yaml entry
spaceapi:
  space: HACKERSPACE_NAME
  logo: URL_FOR_LOGO
  url: URL
  location:
    address: ADDRESS
  contact:
    email: EMAIL_ADDRESS
  issue_report_channels:
    - email
  state:
    entity_id: binary_sensor.front_door

Configuration Variables

space

(string)(Required)Name of the Hackerspace.

logo

(URL)(Required)URL of the hackerspace’s web site.

location

(map)(Required)Location of the Hackerspace.

address

(String)(Required)The physical address of the Hackerspace.

contact

(map)(Required)Contact information of the Hackerspace.

email

(String)(Required)The email address of the Hackerspace.

irc

(String)(Optional)The IRC channel of the Hackerspace

mailing_list

(String)(Optional)The mailing list of the Hackerspace.

twitter

(String)(Optional)The Twitter account of the Hackerspace.

issue_report_channels

(List)(Required)The reporting channel for issues. Pick an entity from contact:.

state

(list)(Required)The current state of the Hackerspace.

entity_id

(entity_id)(Required)The entity_id of a binary sensor that represents the current state.

icon_open

(URL)(Optional)The URL which is publicly accessible of the icon for the open Hackerspace.

icon_closed

(URL)(Optional)The URL which is publicly accessible of the icon for the closed Hackerspace.

sensors

(list)(Optional)List of sensors to expose.

temperature

(entity_id)(Required)List of temperature sensors.

humidity

(entity_id)(Required)List of humidity sensors.

Examples

In this section you find some real life examples of how to use this component.

Eastermundigen

A possible configuration entry for Eastermundigen, a Hackerspace in Switzerland, could look like this.

# Example configuration.yaml entry
spaceapi:
  space: Eastermundigen
  logo: https://eastermundigen.ch/logo.png
  url: https://eastermundigen.ch
  location:
    address: "Steinbruchweg 16, 3072 Ostermundigen, Schweiz"
  contact:
    phone: "+41311111111"
    twitter: "@eastermundigen"
    email: "info@eastermundigen.ch"
  issue_report_channels:
    - email
  state:
    entity_id: binary_sensor.front_door"
    icon_open: https://eastermundigen.ch/open.png
    icon_closed: https://eastermundigen.ch/close.png
  sensors:
    temperature:
      - "sensor.temperature_in"
      - "sensor.temperature_out"
    humidity:
      - "sensor.humidity_in"
      - "sensor.humidity_out"