Setup Path-Based Routing
When deploying LangSmith with path-based routing (using a basePath), you need to configure additional environment variables to ensure URLs are generated correctly throughout the application.
Configure your basic path settings in your Helm chart values file:
config: basePath: "langsmith/dev" subdomain: "langsmith/dev"Add the required environment variables to fix backend URL generation:
commonEnv: - name: LANGCHAIN_ENDPOINT value: "/langsmith/dev/api" - name: LANGCHAIN_PLATFORM_ENDPOINT value: "/langsmith/dev/api"Set your hostname as usual:
hostname: "your-domain.com"Deploy your updated Helm chart configuration
Verify that attachment downloads and other operations now include the correct basePath in their URLs
Usage
After implementing this configuration, your LangSmith deployment will properly handle path-based routing. All API endpoints and file operations (including attachment downloads) will correctly include the basePath prefix in their URLs.
For example, instead of generating URLs like https://your-domain.com/api/public/download, the system will correctly generate https://your-domain.com/langsmith/dev/api/public/download.
Note: You may see a minor 404 error for favicon.ico on first audio playback, but this doesn't affect core functionality and occurs only on the initial attempt.