175
176
constructor(
178
>
@ICopilotApiService private readonly _copilotApiService: ICopilotApiService,
179
>
) {
180
>
super(PROXY_USER_FACING_NAME, logService);
181
>
}
182
183
protected createState(githubToken: string): IClaudeProxyState {
185
>
}
186
187
async start(githubToken: string): Promise<IClaudeProxyHandle> {
189
>
// Late-binding token update covers the case where multiple
190
>
// concurrent callers awaited the same bind — last caller's token
191
>
// wins, matching the single-tenant contract.
192
>
runtime.state.githubToken = githubToken;
193
>
return {
194
>
baseUrl: runtime.baseUrl,
195
>
nonce: runtime.nonce,
196
>
dispose: release,
197
>
};
198
>
}
199
200
override dispose(): void {
202
>
this._onDidReportCredits.dispose();
203
>
}
204
205
protected override writeInternalError(res: http.ServerResponse): void {