@xpert-ai/chatkit-types 0.0.13 → 0.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +37 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -246,6 +246,11 @@ export declare type ChatKitOptions = {
|
|
|
246
246
|
*/
|
|
247
247
|
frameUrl?: string;
|
|
248
248
|
api: CustomApiConfig | HostedApiConfig;
|
|
249
|
+
/**
|
|
250
|
+
* Default request values that should be injected into every user message sent
|
|
251
|
+
* from this ChatKit instance.
|
|
252
|
+
*/
|
|
253
|
+
request?: ChatKitRequestOptions;
|
|
249
254
|
/**
|
|
250
255
|
* Locale override for ChatKit UI. If not provided, the browser's locale
|
|
251
256
|
* will be used. If the locale is not supported, will fall back to English.
|
|
@@ -426,6 +431,38 @@ export declare type ChatKitOptions = {
|
|
|
426
431
|
};
|
|
427
432
|
};
|
|
428
433
|
|
|
434
|
+
export declare type ChatKitRequestContext = {
|
|
435
|
+
/**
|
|
436
|
+
* Request-scoped runtime env overrides.
|
|
437
|
+
* ChatKit forwards this field to LangGraph as `context.env`.
|
|
438
|
+
*/
|
|
439
|
+
env?: Record<string, string>;
|
|
440
|
+
[key: string]: unknown;
|
|
441
|
+
};
|
|
442
|
+
|
|
443
|
+
export declare type ChatKitRequestOptions<TState = Record<string, any>, TContext extends ChatKitRequestContext = ChatKitRequestContext, TConfig extends Record<string, unknown> = Record<string, unknown>> = {
|
|
444
|
+
/**
|
|
445
|
+
* Custom graph state merged into every submitted message request.
|
|
446
|
+
* The active user input is always written into `state.human.input`.
|
|
447
|
+
*/
|
|
448
|
+
state?: TState;
|
|
449
|
+
/**
|
|
450
|
+
* Additional stream context merged into every submitted message request.
|
|
451
|
+
*
|
|
452
|
+
* Request-scoped runtime env overrides should be placed in `context.env`.
|
|
453
|
+
* Extend `TContext` with any other request-scoped context fields you need.
|
|
454
|
+
*/
|
|
455
|
+
context?: TContext;
|
|
456
|
+
/**
|
|
457
|
+
* Additional LangGraph run config merged into every submitted message request.
|
|
458
|
+
*
|
|
459
|
+
* This is forwarded to the hosted `runs.stream` request as `config`.
|
|
460
|
+
* Use this for LangGraph runtime controls such as tags or configurable values,
|
|
461
|
+
* not request-scoped env overrides.
|
|
462
|
+
*/
|
|
463
|
+
config?: TConfig;
|
|
464
|
+
};
|
|
465
|
+
|
|
429
466
|
export declare type ChatKitTheme = {
|
|
430
467
|
/**
|
|
431
468
|
* The color scheme to use for the ChatKit UI.
|