Skip to main content
POST
Send an MCP message to a server

Authorizations

X-Api-Key
string
header
required

Personal or workspace LangSmith API key. Personal keys identify the user. Workspace keys are limited to server listing and MCP calls and must also supply the end user's OIDC token or X-LangSmith-Identity.

X-Tenant-Id
string
header
required

Workspace UUID. This header selects a workspace; it does not authenticate the caller.

Headers

X-LangSmith-Identity
string

Advanced alternative to a user OIDC token with a workspace API key. Set to the user's Tool Gateway identity UUID or provider:subject. Using that user's stored credentials requires workspaces:credentials:use or agent-auth-credentials:use. Ignored for personal credentials.

X-LangSmith-Profile
string<uuid>

Profile ID whose admin-connected credentials to use instead of a user's. Requires workspaces:credentials:use or agent-auth-credentials:use and cannot be combined with X-LangSmith-Identity or a user OIDC token.

MCP-Session-Id
string

Session ID returned by the MCP server, when required for an established session

MCP-Protocol-Version
string

Negotiated MCP protocol version

Last-Event-ID
string

Last received SSE event ID when resuming a stream

Path Parameters

id
string
required

Workspace server ID or built-in server key

Response

Upstream MCP JSON message or SSE stream.