File size: 343 Bytes
033ca06 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 | "use client";
import { Client as LangGraphClient } from "@langchain/langgraph-sdk/client";
import { getLangGraphBaseURL } from "../config";
let _singleton: LangGraphClient | null = null;
export function getAPIClient(): LangGraphClient {
_singleton ??= new LangGraphClient({
apiUrl: getLangGraphBaseURL(),
});
return _singleton;
}
|