Skip to content
This repository has been archived by the owner on Jan 20, 2021. It is now read-only.

Commit

Permalink
changes for HACS
Browse files Browse the repository at this point in the history
  • Loading branch information
badguy99 committed Mar 17, 2020
1 parent 52b3c27 commit ca611b6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions octocost.py → apps/octocost/octocost.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ def initialize(self):
self.auth = self.args['auth']
MPAN = self.args['mpan']
SERIAL = self.args['serial']
region = self.args['region']
region = self.args['region']
self.startdate = datetime.date.fromisoformat(str(self.args['startdate']))
self.consumptionurl = 'https://api.octopus.energy/v1/electricity-meter-points/' + str(MPAN) + '/meters/' + str(SERIAL) + '/consumption/'
self.costurl= 'https://api.octopus.energy/v1/products/AGILE-18-02-21/electricity-tariffs/E-1R-AGILE-18-02-21-' + str(region) + '/standard-unit-rates/'
self.costurl= 'https://api.octopus.energy/v1/products/AGILE-18-02-21/electricity-tariffs/E-1R-AGILE-18-02-21-' + str(region).upper() + '/standard-unit-rates/'
time = datetime.datetime.now()
time = time + datetime.timedelta(seconds=5)
self.run_every(self.cost_and_usage_callback, time, 120 * 60)
Expand Down

0 comments on commit ca611b6

Please sign in to comment.