Skip to content

jordyBonnet/FASTAPIHOME

Repository files navigation

FASTAPIHOME

Home server done with FAST API
http://127.0.0.1:8000/docs

Usefull home functions gathered into a local API.

Scheduled functions are runned by schedul_trhead.py script.
They call certain FAST API functions that uses pushbullet to send notifications on your smartphone.

To be installed on a raspberry py for example

  • run API server on VScode terminal:
source .venv/bin/activate
uvicorn main:app --reload
  • run scheduler on a terminal:
python3.11 /home/pommi/FASTAPIHOME/schedul_thread.py

Functions:

Send notifications to smartphones with pushbullet

installation:

  1. pip install fastapi
  2. pip install "uvicorn[standard]"
    see: https://fastapi.tia[text](requirements.txt)ngolo.com/
  3. pip install pushbullet.py
  4. [NOT USED] pip install fastapi-utils
    see: https://fastapi-utils.davidmontague.xyz/user-guide/repeated-tasks/
    for task/function scheduling

pip install -r requirements.txt
pip freeze > requirements.txt

## set git user & mail git config --global user.name jordy-Raspy git config --global user.email [email protected]

on raspberrypi OS:

virtual environment installation:
python3.11 -m venv .venv activate venv:
source .venv/bin/activate

Ideas:

Todo:

  • send messages with telegram API
  • create a sheduled function to send these messages

About

Home server done with FAST API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published