Add mobile services, web proxy, and Gemma4 agent loop

- Mobile: add push notification and calendar sync services with full test suite (calendar, eventStore, notifications,
  screens)
- Mobile: add EAS build config and Jest setup
- Web: add API proxy, update useDestinationStation/useJourneys hooks, add middleware tests
- Web: update next.config and rebuild
- Agent: add Gemma4-based agent loop (agent_base, ttl_agent, ts_agent)
- Docs: add privacy policy, post-MVP plan, and aider rules
This commit is contained in:
2026-05-11 18:32:54 +02:00
parent 20159262c1
commit 5bcfafcbaf
120 changed files with 8626 additions and 860 deletions
+14
View File
@@ -74,6 +74,20 @@ export class ApiClient {
return res.json();
}
/**
* Send an arbitrary HAFAS protocol body to the /api/hafas endpoint.
* This handles TripSearch, LocMatch, and any other HAFAS methods.
*/
async hafasRequest<T = Record<string, unknown>>(body: unknown): Promise<T> {
const res = await fetch(`${this.baseUrl}/api/hafas`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(body),
});
if (!res.ok) throw new Error(`HAFAS request failed: ${res.status}`);
return res.json();
}
async searchJourneys(
fromStationExtId: string,
toStationExtId: string,