mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-18 19:03:41 +00:00
new gateway
This commit is contained in:
parent
01958298e0
commit
9a0b848789
34 changed files with 1632 additions and 290 deletions
|
|
@ -43,6 +43,26 @@ export interface MarkdownSettings {
|
|||
codeBlockIndent?: string; // default: " "
|
||||
}
|
||||
|
||||
export interface GatewaySessionSettings {
|
||||
idleMinutes?: number;
|
||||
maxQueuePerSession?: number;
|
||||
}
|
||||
|
||||
export interface GatewayWebhookSettings {
|
||||
enabled?: boolean;
|
||||
basePath?: string;
|
||||
secret?: string;
|
||||
}
|
||||
|
||||
export interface GatewaySettings {
|
||||
enabled?: boolean;
|
||||
bind?: string;
|
||||
port?: number;
|
||||
bearerToken?: string;
|
||||
session?: GatewaySessionSettings;
|
||||
webhook?: GatewayWebhookSettings;
|
||||
}
|
||||
|
||||
export type TransportSetting = Transport;
|
||||
|
||||
/**
|
||||
|
|
@ -93,6 +113,7 @@ export interface Settings {
|
|||
autocompleteMaxVisible?: number; // Max visible items in autocomplete dropdown (default: 5)
|
||||
showHardwareCursor?: boolean; // Show terminal cursor while still positioning it for IME
|
||||
markdown?: MarkdownSettings;
|
||||
gateway?: GatewaySettings;
|
||||
}
|
||||
|
||||
/** Deep merge settings: project/overrides take precedence, nested objects merge recursively */
|
||||
|
|
@ -912,4 +933,8 @@ export class SettingsManager {
|
|||
getCodeBlockIndent(): string {
|
||||
return this.settings.markdown?.codeBlockIndent ?? " ";
|
||||
}
|
||||
|
||||
getGatewaySettings(): GatewaySettings {
|
||||
return structuredClone(this.settings.gateway ?? {});
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue