Code Monkey home page Code Monkey logo

hass-formulaoneapi's Introduction

hacs_badge

Home Assistant Formula One API

Formula One API will be down for the remaining of the season while I work on a solution to update the data and prevent polling the API. The terms and condition of the API prevent polling.

Formula One API Integration Into Home Assistant: Bring live information the current season!

2022-10-05 - This sensor was seperated into 4 new sensors. Please check the frontend.md to correct the visuals

2023-01-11 - I will be shutting down the project on February 15th if nobody takes over. The cost of the server and the strain on it are too much.

Installation: Manual

  1. Copy the formulaone_api folder to the custom_components folder in your Home Assistant configuration directory.
  2. Restart Home Assistant to allow the required packages to be installed.
  3. Add the following minimum code in your configuration.yaml file. See Configuration for more advanced options:
sensor:
  - platform: formulaone_api
  1. Restart Home Assistant one final time.

Installation: HACS

This method assumes you have HACS already installed.

Use this button: Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.

OR Manually

  1. In the HACS Store, click Custom Repository from the top right menu.
  2. Enter delzear/hass-formulaoneapi in the URL textbox and Integration in the Category.
  3. Click Install
  4. Restart Home Assistant to allow the required packages to be installed.
  5. Add the following code in your configuration.yaml file. See Configuration for more advanced options:
sensor:
  - platform: formulaone_api
  1. Restart Home Assistant one final time.

Configuration

key required type usage
platform true string formulaone_api

Exposed Information

The sensor will expose 3 state attributes:

state description
next_race The Next race of the current championship season
races Array of all the races of the current championship season
drivers Sorted array of all drivers of the current championship season ordered by descending points
constructors Sorted array of all constructors of the current championship season ordered by descending points
last_result Sorted array of the last race result

The sensor will return the following state attributes whether or not a game is in progress:

Examples

Use the FormulaOne-Card for displaying the information OR use the markdown card: frontend.md

Objectives Checklist

  • Consume Formula One Stats API locally with the least amount of resources possible.
  • Pass information to Home Assistant as sensor data. (ex. Next game scheduled, live scores, goal description, etc.)
  • Create a "live" event platform to use as a trigger for automations.
  • Display the information in the front-end in its own Lovelace card.
  • Add support for HACS.
  • Add notification service for qualifying, sprint and race

Resources

The Home Assistant NHL API

hass-formulaoneapi's People

Contributors

delzear avatar huizebruin avatar marcokreeft87 avatar austensmith avatar hmmbob avatar lrvdlinden avatar brhahlen avatar bram-pkg avatar phpersson avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.