Skip to content

ChatUserClientOptions

Defined in: libs/ccs-chat-user-client/src/chat-user-client.ts:11

chatApiUrl: string

Defined in: libs/ccs-chat-user-client/src/chat-user-client.ts:13

Chat API base URL, e.g. https://chat.centralcodestation.com/api/v1


tenantId: string

Defined in: libs/ccs-chat-user-client/src/chat-user-client.ts:15

The Identity Server tenant id the user is acting in.


applicationId: string

Defined in: libs/ccs-chat-user-client/src/chat-user-client.ts:17

Your TENANT application’s id (Chat runs inside it). Its own role → permission mapping applies.


getAccessToken: AccessTokenProvider

Defined in: libs/ccs-chat-user-client/src/chat-user-client.ts:23

Returns the signed-in user’s access token for the chat-api resource (aud = chat-api, scope chat:access) — not your own API’s token. Called before every request, so return a refreshed token when the old one nears expiry. See the README, “Getting the user’s Chat token”.


optional fetch?: {(input, init?): Promise<Response>; (input, init?): Promise<Response>; }

Defined in: libs/ccs-chat-user-client/src/chat-user-client.ts:25

Override fetch (tests, or runtimes without a global fetch).

(input, init?): Promise<Response>

MDN Reference

URL | RequestInfo

RequestInit

Promise<Response>

(input, init?): Promise<Response>

MDN Reference

string | URL | Request

RequestInit

Promise<Response>