Giter Club home page Giter Club logo

home-assistant-ssam-garbagecollection's Introduction

SSAM - Garbage collection days in Home assistant

Instructions:

  1. Download the ssam.yaml file and place in your home assistant configuration folder or in a subfolder.

  2. Search using this page to get your full address and code, then copy in to the configuration. https://edpfuture.ssam.se/FutureWeb/SimpleWastePickup/Simplewastepickup

  3. Update the row for the rest sensor resource template: Replace Streetname 1, City (12345) with your address and code (don't remove surrounding quotes).

  4. Add in configuration.yaml (assuming the ssam.yaml file is in a subfolder packages):

homeassistant:
  packages:
    ssam: !include packages/ssam.yaml
  1. Example automations to remind you about the garbage collection on the evening before:
- id: ac22a80d775d4cbba83e174f0fc75dd4
  alias: Påminn om sophämtning 1
  trigger:
  - platform: time
    at: '18:00:00'
  condition:
  - condition: template
    value_template: '{{ (float(as_timestamp(states("sensor.sophamtning_karl_1"),"%Y-%m-%d")-86400)|
      timestamp_custom("%Y-%m-%d")) == (as_timestamp(now()) | timestamp_custom("%Y-%m-%d"))
      }}'
  action:
  - data:
      message: Sophämtning Soptunna 1 imorgon!
      title: Sophämtning kärl 1
    service: notify.notify
    
- id: 068a13b37bac4eb1afbec7b9d5fce444
  alias: Påminn om sophämtning 2
  trigger:
  - platform: time
    at: '18:00:00'
  condition:
  - condition: template
    value_template: '{{ (float(as_timestamp(states("sensor.sophamtning_karl_2"),"%Y-%m-%d")-86400)|
      timestamp_custom("%Y-%m-%d")) == (as_timestamp(now()) | timestamp_custom("%Y-%m-%d"))
      }}'
  action:
  - data:
      message: Sophämtning Soptunna 2 imorgon!
      title: Sophämtning kärl 2
    service: notify.notify

home-assistant-ssam-garbagecollection's People

Contributors

endor-force avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Forkers

zombiefredrik

home-assistant-ssam-garbagecollection's Issues

Just a comment and a thanks!

No issue really but:
Forked your code and modified it to work with June Avfall for northern småland as well! Thanks!

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.