doorbuzz/spacestatus.py

10 lines
211 B
Python
Raw Normal View History

2016-04-01 00:37:54 +02:00
#!/usr/bin/env python
# -*- coding: utf-8 -*-
2015-04-08 22:16:20 +02:00
import urllib, json
2016-04-01 00:37:54 +02:00
2015-04-08 22:16:20 +02:00
url = "https://spaceapi.syn2cat.lu/status/json"
response = urllib.urlopen(url);
data = json.loads(response.read())
print data["state"]["open"]