MCPcopy Create free account
hub / github.com/pingdotgg/t3code / createOpenCodeSdkClient

Function createOpenCodeSdkClient

apps/server/src/provider/opencodeRuntime.ts:505–517  ·  view source on GitHub ↗
(input)

Source from the content-addressed store, hash-verified

503 };
504
505 const createOpenCodeSdkClient: OpenCodeRuntimeShape["createOpenCodeSdkClient"] = (input) =>
506 createOpencodeClient({
507 baseUrl: input.baseUrl,
508 directory: input.directory,
509 ...(input.serverPassword
510 ? {
511 headers: {
512 Authorization: `Basic ${Buffer.from(`opencode:${input.serverPassword}`, "utf8").toString("base64")}`,
513 },
514 }
515 : {}),
516 throwOnError: true,
517 });
518
519 const loadProviders = (client: OpencodeClient) =>
520 runOpenCodeSdk("provider.list", () => client.provider.list()).pipe(

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected