Add custom headers to direct connections (#2922)

* Add custom headers to direct connections

* Address custom header review feedback

* Fix direct connection header integration

* Fix desktop relay E2E transport setup

---------

Co-authored-by: Claude <claude@Claudes-Mac-mini.local>
Co-authored-by: Mohamed Boudra <boudra.moha@gmail.com>
This commit is contained in:
Claude
2026-08-06 11:05:40 +02:00
committed by GitHub
co-authored by Claude Mohamed Boudra
parent 098122be8d
commit 73ba37a07a
38 changed files with 1190 additions and 125 deletions
+2 -1
View File
@@ -301,6 +301,7 @@ export interface DaemonClientConfig {
runtimeGeneration?: number | null;
password?: string;
authHeader?: string;
headers?: Record<string, string>;
suppressSendErrors?: boolean;
transportFactory?: DaemonTransportFactory;
webSocketFactory?: WebSocketFactory;
@@ -1249,7 +1250,7 @@ export class DaemonClient {
return;
}
const headers: Record<string, string> = {};
const headers: Record<string, string> = { ...this.config.headers };
const password = normalizePassword(this.config.password);
if (password) {
headers.Authorization = `Bearer ${password}`;