Add HealthChat API and extended profile services (#9)

Expose OpenID tokens and homeserver credentials from the client proxy, and
add fork-only services for the HealthChat member directory backend
(api.healthchat.ch) plus a service that reads MSC4133 extended profile
fields directly from the homeserver. Groundwork for the members tab and
the profile screens.

Claude-Session: https://claude.ai/code/session_013qdTbAWsZj2quQzEkagXaS
This commit is contained in:
2026-09-22 16:56:20 +02:00
parent 07918562dd
commit 00f08ab2dc
19 changed files with 1807 additions and 0 deletions
@@ -244,6 +244,14 @@ protocol ClientProxyProtocol: AnyObject {
func profile(for userID: String) async -> Result<UserProfile, ClientProxyError>
/// An OpenID token for authenticating against services that trust the homeserver (MSC1961).
/// Short-lived — cache per call site.
func requestOpenIDToken() async -> Result<OpenIDToken, ClientProxyError>
/// The session's REST credentials for client-server API calls the SDK doesn't cover.
/// The access token can rotate after a refresh, so re-read for every request.
func homeserverCredentials() -> Result<HomeserverCredentials, ClientProxyError>
func roomDirectorySearchProxy() -> RoomDirectorySearchProxyProtocol
func resolveRoomAlias(_ alias: String) async -> Result<ResolvedRoomAlias, ClientProxyError>