UNPKG

@langchain/langgraph-sdk

Version:

Client library for interacting with the LangGraph API

20 lines (19 loc) • 718 B
//#region src/client/stream/resolve-client-api-url.ts /** * Resolve the LangGraph SDK `Client` base URL for hydration and history * reads when the caller uses a custom {@link AgentServerAdapter}. * * Explicit `apiUrl` wins; otherwise inherit from adapters that expose * `apiUrl` (e.g. {@link HttpAgentServerAdapter}). */ function resolveClientApiUrl(options) { if (options.apiUrl != null) return options.apiUrl; const { transport } = options; if (transport != null && typeof transport === "object") { const candidate = transport.apiUrl; if (typeof candidate === "string") return candidate; } } //#endregion exports.resolveClientApiUrl = resolveClientApiUrl; //# sourceMappingURL=resolve-client-api-url.cjs.map