LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Agent
  • Middleware
  • Backends
  • Sandboxes
  • Skills
  • Subagents
  • Types
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
  • Vitest
⌘I

LangChain Assistant

Ask a question to get started

Enter to send•Shift+Enter new line

Menu

OverviewAgentMiddlewareBackendsSandboxesSkillsSubagentsTypes
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
Vitest
Language
Theme
JavaScriptdeepagentsbrowserCompositeBackendresolveBackendForPath
Method●Since v1.14

resolveBackendForPath

Copy
resolveBackendForPath(path: string): [BackendProtocolV2, string]
View source on GitHub

Parameters

NameTypeDescription
path*string

Returns the backend for path, with the matched prefix stripped (/foo → /). Routes match on path-segment boundaries: /foo matches /foo/bar but not /foobar.