feat: add homelab deployment configs, documentation, and automation scripts
This commit is contained in:
19
scripts/test_homepage_tempest_api.py
Normal file
19
scripts/test_homepage_tempest_api.py
Normal file
@@ -0,0 +1,19 @@
|
||||
import requests
|
||||
import json
|
||||
import urllib3
|
||||
urllib3.disable_warnings()
|
||||
|
||||
# Let's test the widget API endpoint on homepage
|
||||
url = "https://homepage.snarfnet.net/api/services/proxy?group=Environment%20%26%20Weather&service=Tempest%20Weather%20Station&index=0"
|
||||
|
||||
headers = {
|
||||
"User-Agent": "Mozilla/5.0"
|
||||
}
|
||||
|
||||
try:
|
||||
r = requests.get(url, headers=headers, verify=False, timeout=10)
|
||||
print("Status code:", r.status_code)
|
||||
print("Response body:")
|
||||
print(json.dumps(r.json(), indent=2))
|
||||
except Exception as e:
|
||||
print("Error:", e)
|
||||
Reference in New Issue
Block a user