markers data test

This commit is contained in:
Daniel Nagel 2025-09-07 12:51:50 +00:00
parent d974cf4abe
commit 69ce35e03e

View File

@ -1,14 +1,13 @@
const url = "https://data.arenos.danielnagel.at/api/docs/rp78Zashtzfe7mgFSbeMkd";
const apiKey = "77fc2fdb0b54a27e4da954a077a670e67f45b203";
async function main() {
const response = await fetch(url, {
headers: {
"Authorization": `Bearer ${apiKey}`
}
});
const json = await response.json();
console.log(json);
// markers.js
async function testGateway() {
try {
const res = await fetch("/api/places"); // Edge-Caddy proxyt zu data_gateway
const data = await res.json();
console.log("Antwort vom Gateway:", data);
} catch (err) {
console.error("Fehler:", err);
}
}
main();
// Direkt beim Laden einmal ausführen:
testGateway();