bruxy70 / Garbage-Collection

🗑 Custom Home Assistant sensor for scheduling garbage collection (or other regularly re-occurring events - weekly on given days, semi-weekly or monthly)
MIT License
382 stars 90 forks source link

Not pulling data from abfall_io #422

Closed tinkerberlin closed 2 years ago

tinkerberlin commented 2 years ago

Before you submit a new bug report, please check that

Write your question here

Hi there, I hope you can help, but if not, just let me know...

I'm using garbage collection to pull in data from abfall_io. I think I've parsed the correct info from the Alba Berlin website (see code below; I've removed a single digit from the street code so that not everything is public; replaced with a "*" ;-) ).

However, it's not pulling the data into HA. Can you help?

waste_collection_schedule:
  sources:
    - name: bsr_de
      args:
        abf_strasse: "XXXXXXXX., 12345 Berlin (Reinickendorf)"
        abf_hausnr: XX
      customize:
        - type: "Abholung Hausmüll"
          alias: Hausabfall
          icon: mdi:trash-can
        - type: "Abholung Biogut"
          alias: Biogut
          icon: mdi:recycle
    - name: abfall_io
      args:
        key: "9583a2fa1df97ed95363382c73b41b1b"
        f_id_kommune: 3227
        f_id_strasse: 806*
        f_abfallarten: 127
      customize:
        - type: "127"
          alias: Wertstofftonne
          icon: mdi:recycle-variant
  fetch_time: "04:00"
  day_switch_time: "08:00"

sensor:
  - platform: waste_collection_schedule
    name: Wertstoff
    details_format: "upcoming"
    value_template: >-
      {% if value.daysTo == 0 %}
      HEUTE
      {% elif value.daysTo == 1 %}
      MORGEN
      {% else %}
      in {{value.daysTo}} Tagen
      {% endif %}
    types:
      - Wertstofftonne
      - 
  - platform: waste_collection_schedule
    name: Restmuell
    details_format: "upcoming"
    value_template: >-
      {% if value.daysTo == 0 %}
      HEUTE
      {% elif value.daysTo == 1 %}
      MORGEN
      {% else %}
      in {{value.daysTo}} Tagen
      {% endif %}
    types:
      - Hausabfall

  - platform: waste_collection_schedule
    name: Biomuell
    details_format: "upcoming"
    value_template: >-
      {% if value.daysTo == 0 %}
      HEUTE
      {% elif value.daysTo == 1 %}
      MORGEN
      {% else %}
      in {{value.daysTo}} Tagen
      {% endif %}
    types:
      - Biogut

  - platform: waste_collection_schedule
    name: abfallnaechster
    details_format: "upcoming"
    value_template: >-
      {% if value.daysTo == 0 %}
      HEUTE
      {% elif value.daysTo == 1 %}
      MORGEN
      {% else %}
      in {{value.daysTo}} Tagen
      {% endif %}