You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/docs/components/tools/mcp.md
+38-1Lines changed: 38 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -38,6 +38,34 @@ tools:
38
38
from: mcp:http://example.com/v1/mcp
39
39
```
40
40
41
+
### Example: Connecting to an Auth-Enabled MCP Server (Streamable HTTP)
42
+
43
+
Streamable HTTP MCP tools support sending an `Authorization: Bearer` token via `mcp_auth_token`, or arbitrary HTTP headers via `mcp_headers`. Both parameters resolve [secret references](../secret-stores/) before the MCP client is constructed.
If both `mcp_auth_token` and a custom `Authorization` header in `mcp_headers` are set, `mcp_auth_token` wins and a warning is logged.
68
+
41
69
## Using MCP Tools with Models
42
70
43
71
Once configured, MCP tools can be assigned to models via the `tools` parameter. For example:
@@ -87,7 +115,9 @@ The `from` field specifies the transport mechanism for the MCP tool:
87
115
88
116
### `params`
89
117
90
-
The `params` field provides additional configuration for MCP tools. For stdio-based tools, use `mcp_args` to specify command-line arguments.
118
+
The `params` field provides additional configuration for MCP tools.
119
+
120
+
For stdio-based tools, use `mcp_args` to specify command-line arguments:
91
121
92
122
```yaml
93
123
tools:
@@ -97,6 +127,13 @@ tools:
97
127
mcp_args: -y @custom/tool
98
128
```
99
129
130
+
For Streamable HTTP tools, the following auth parameters are supported:
131
+
132
+
- `mcp_auth_token` — Sends `Authorization: Bearer <token>` on every request to the MCP server.
133
+
- `mcp_headers` — Sends additional HTTP headers using the same `Header: Value` comma- or semicolon-delimited format as the [HTTP data connector's `http_headers`](../data-connectors/https). Header values are marked sensitive.
134
+
135
+
Both parameters support [secret expansion](../secret-stores/). When `mcp_auth_token` is set, an `Authorization` header in `mcp_headers` is ignored and a warning is logged to avoid duplicate auth headers.
136
+
100
137
### `env`
101
138
102
139
For stdio-based MCP tools, environment variables can be set using the `env` field.
0 commit comments