Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/langsmith/add-auth-server.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,15 @@ sequenceDiagram
participant User
participant Client
participant AuthServer
participant LangGraph Backend
participant Agent Server

User->>Client: Initiate login
User->>AuthServer: Enter credentials
AuthServer->>Client: Send tokens
Client->>LangGraph Backend: Request with token
LangGraph Backend->>AuthServer: Validate token
AuthServer->>LangGraph Backend: Token valid
LangGraph Backend->>Client: Serve request (e.g., run agent or graph)
Client->>Agent Server: Request with token
Agent Server->>AuthServer: Validate token
AuthServer->>Agent Server: Token valid
Agent Server->>Client: Serve request (e.g., run agent or graph)
```

## Prerequisites
Expand Down
10 changes: 5 additions & 5 deletions src/langsmith/auth.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -47,24 +47,24 @@ A typical authentication setup involves three main components:
* Handles user registration, login, password resets, etc.
* Issues tokens (JWT, session tokens, etc.) after successful authentication
* Examples: Auth0, Supabase Auth, Okta, or your own auth server
2. **LangGraph Backend** (Resource Server)
* Your LangGraph application that contains business logic and protected resources
2. **Agent Server** (Resource Server)
* Your agent or LangGraph application, which contains business logic and protected resources
* Validates tokens with the auth provider
* Enforces access control based on user identity and permissions
* Doesn't store user credentials directly
3. **Client Application** (Frontend)
* Web app, mobile app, or API client
* Collects time-sensitive user credentials and sends to auth provider
* Receives tokens from auth provider
* Includes these tokens in requests to LangGraph backend
* Includes these tokens in requests to the Agent Server

Here's how these components typically interact:

```mermaid
sequenceDiagram
participant Client as Client App
participant Auth as Auth Provider
participant LG as LangGraph Backend
participant LG as Agent Server

Client->>Auth: 1. Login (username/password)
Auth-->>Client: 2. Return token
Expand Down Expand Up @@ -143,7 +143,7 @@ sequenceDiagram
%% Actors
participant ClientApp as Client
participant AuthProv as Auth Provider
participant LangGraph as LangGraph Backend
participant LangGraph as Agent Server
participant SecretStore as Secret Store
participant ExternalService as External Service

Expand Down
2 changes: 1 addition & 1 deletion src/langsmith/server-mcp.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ sequenceDiagram
%% Actors
participant ClientApp as Client
participant AuthProv as Auth Provider
participant LangGraph as LangGraph Backend
participant LangGraph as Agent Server
participant SecretStore as Secret Store
participant MCPServer as MCP Server

Expand Down