- check if observation already exits in Db, then insert
This commit is contained in:
parent
095cfdfe24
commit
e2ceb107c9
4 changed files with 185 additions and 50 deletions
|
@ -65,10 +65,10 @@ class MyApi():
|
|||
# self.access_token = res.json()['access_token']
|
||||
# else:
|
||||
# # Token expired -> re-authenticate
|
||||
def getSensorData(self, sensor: string):
|
||||
def getSensorData(self, sensor: string, date):
|
||||
''' request observations'''
|
||||
try:
|
||||
request = self.session.get('https://api.dgnss-sensors.com/gschliefgraben?sensors=(\''+sensor+ '\')&start=2022-02-28&end=2022-02-28',
|
||||
request = self.session.get('https://api.dgnss-sensors.com/gschliefgraben?sensors=(\''+sensor+ '\')&start='+date+'&end='+date,
|
||||
headers={
|
||||
'cache-control': 'no-cache',
|
||||
'Content-Type': 'application/x-www-form-urlencoded',
|
||||
|
|
Loading…
Add table
editor.link_modal.header
Reference in a new issue