mirror of
https://github.com/langflow-ai/langflow.git
synced 2026-07-23 17:06:46 +08:00
docs: fixes for consulting advantage (#13300)
* docs: lock mcp server management * docs: restrict custom components to superusers * docs: embedded mode to hide UI elements * docs: add custom component admin restriction
This commit is contained in:
@ -122,6 +122,8 @@ To add a new MCP server, click <Icon name="Plus" aria-hidden="true"/> **Add MCP
|
||||
|
||||
Click <Icon name="Ellipsis" aria-hidden="true"/> **More** to edit or delete an MCP server connection.
|
||||
|
||||
If your Langflow server administrator has locked MCP server management, you will receive a locked message when you try to add or modify servers. For more information, see [Lock MCP server management](/mcp-server#restrict-mcp-server-management).
|
||||
|
||||
## Modify MCP server environment variables with the API {#mcp-api-tweaks}
|
||||
|
||||
You can modify MCP server environment variables at runtime when running flows through the [Langflow API](/api-reference-api-examples) by tweaking the **MCP Tools** component.
|
||||
|
||||
@ -402,6 +402,15 @@ The default address is `http://localhost:6274`.
|
||||
|
||||
5. To quit MCP Inspector, press <kbd>Control+C</kbd> in the same terminal window where you started it.
|
||||
|
||||
## Restrict MCP server management to superusers {#restrict-mcp-server-management}
|
||||
|
||||
To prevent non-superusers from editing MCP server connections, set `LANGFLOW_MCP_SERVERS_LOCKED=true`.
|
||||
|
||||
When set to `true`, non-superusers can use existing MCP servers that are already configured, but they cannot configure MCP server connections in the UI or API.
|
||||
Superusers retain full access to MCP server configuration.
|
||||
|
||||
Locking the MCP server configuration for users does not disable Langflow's built-in MCP server for serving flows as MCP tools.
|
||||
|
||||
## MCP server environment variables
|
||||
|
||||
The following environment variables set behaviors related to your Langflow projects' MCP servers:
|
||||
@ -414,6 +423,7 @@ The following environment variables set behaviors related to your Langflow proje
|
||||
| `LANGFLOW_MCP_TOOL_EXECUTION_TIMEOUT` | Integer | `180` | Global timeout in seconds for MCP tool calls. See [Configure tool execution timeouts](#configure-tool-execution-timeouts). |
|
||||
| `LANGFLOW_MCP_MAX_SESSIONS_PER_SERVER` | Integer | `10` | Maximum number of MCP sessions to keep per unique server. |
|
||||
| `LANGFLOW_ADD_PROJECTS_TO_MCP_SERVERS` | Boolean | `True` | Whether to automatically add newly created projects to the user's MCP servers configuration. If `false`, projects must be manually added to MCP servers. |
|
||||
| `LANGFLOW_MCP_SERVERS_LOCKED` | Boolean | `False` | If `true`, non-superusers cannot add, edit, or remove MCP server connections through the UI or API. Superusers retain full access. For more information, see [Restrict MCP server management to superusers](#restrict-mcp-server-management). |
|
||||
|
||||
## Troubleshoot Langflow MCP servers {#troubleshooting-mcp-server}
|
||||
|
||||
|
||||
@ -21,7 +21,17 @@ This environment variable is a beta feature, and should not be your only safegua
|
||||
|
||||
In the event that Langflow could execute untrusted or LLM-generated code, run Langflow in an isolated and containerized execution environment.
|
||||
|
||||
### Configure a custom component allow-list
|
||||
### Restrict custom component creation to superusers{#restrict-custom-components-to-superusers}
|
||||
|
||||
To restrict custom component creation to superusers while keeping built-in components functional for users, set the following [environment variable](/environment-variables):
|
||||
|
||||
```bash
|
||||
LANGFLOW_CUSTOM_COMPONENT_ADMIN_ONLY=true
|
||||
```
|
||||
|
||||
When set to `true`, non-superusers can still view and use custom components in flows, but they cannot create new custom components or edit custom component code.
|
||||
|
||||
## Configure a custom component allow-list
|
||||
|
||||
`LANGFLOW_ALLOW_CUSTOM_COMPONENTS` works together with optional paths that define which component templates the server loads, and which code hashes are trusted.
|
||||
|
||||
|
||||
@ -483,4 +483,31 @@ See [Telemetry](/contributing-telemetry).
|
||||
| `LANGFLOW_MAX_VERTEX_BUILDS_TO_KEEP` | Integer | `3000` | Maximum number of vertex builds to keep in the database. Relates to [Playground](/concepts-playground) functionality. |
|
||||
| `LANGFLOW_MAX_VERTEX_BUILDS_PER_VERTEX` | Integer | `2` | Maximum number of builds to keep per vertex. Older builds are deleted. Relates to [Playground](/concepts-playground) functionality. |
|
||||
| `LANGFLOW_PUBLIC_FLOW_CLEANUP_INTERVAL` | Integer | `3600` | The interval in seconds at which data for [shared Playground](/concepts-playground#share-a-flows-playground) flows are cleaned up. Default: 3600 seconds (1 hour). Minimum: 600 seconds (10 minutes). |
|
||||
| `LANGFLOW_PUBLIC_FLOW_EXPIRATION` | Integer | `86400` | The time in seconds after which a [shared Playground](/concepts-playground#share-a-flows-playground) flow is considered expired and eligible for cleanup. Default: 86400 seconds (24 hours). Minimum: 600 seconds (10 minutes). |
|
||||
| `LANGFLOW_PUBLIC_FLOW_EXPIRATION` | Integer | `86400` | The time in seconds after which a [shared Playground](/concepts-playground#share-a-flows-playground) flow is considered expired and eligible for cleanup. Default: 86400 seconds (24 hours). Minimum: 600 seconds (10 minutes). |
|
||||
|
||||
### Hide UI elements with embedded mode {#embedded-mode}
|
||||
|
||||
When you embed the Langflow visual editor in another application, such as an iframe within a host portal, you can hide UI elements that are usually visible in the visual editor.
|
||||
|
||||
The embedded mode environment variables control which UI elements appear in the visual editor.
|
||||
Embedded mode controls UI visibility only, and does not block API endpoints or deploy Langflow.
|
||||
|
||||
Embedded mode is distinct from the [embedded chat widget](/concepts-publish#embedded-chat-widget), which embeds a single flow's chat UI in a website.
|
||||
|
||||
When `LANGFLOW_EMBEDDED_MODE=true`, Langflow hides the following buttons in the UI:
|
||||
|
||||
* **Logout**
|
||||
* **New project**
|
||||
* **New flow**
|
||||
* **Starter projects**
|
||||
|
||||
You can hide individual elements without enabling the umbrella flag.
|
||||
|
||||
| Variable | Format | Default | Description |
|
||||
|----------|--------|---------|-------------|
|
||||
| `LANGFLOW_EMBEDDED_MODE` | Boolean | `False` | Umbrella flag for embedded or iframe deployments. When `true`, hides standalone UI elements: logout, new project, new flow, and starter projects. Individual hide flags can also be set without enabling this flag. |
|
||||
| `LANGFLOW_HIDE_LOGOUT_BUTTON` | Boolean | `False` | If `true`, hides the logout button in the account menu. Automatically enabled when `LANGFLOW_EMBEDDED_MODE=true`. |
|
||||
| `LANGFLOW_HIDE_NEW_PROJECT_BUTTON` | Boolean | `False` | If `true`, hides the new project/folder button in the sidebar. Automatically enabled when `LANGFLOW_EMBEDDED_MODE=true`. |
|
||||
| `LANGFLOW_HIDE_NEW_FLOW_BUTTON` | Boolean | `False` | If `true`, hides the new flow button in the header. Automatically enabled when `LANGFLOW_EMBEDDED_MODE=true`. |
|
||||
| `LANGFLOW_HIDE_STARTER_PROJECTS` | Boolean | `False` | If `true`, hides the starter projects tab in the templates modal. Does not affect database seeding of starter projects. Automatically enabled when `LANGFLOW_EMBEDDED_MODE=true`. |
|
||||
| `LANGFLOW_HIDE_GETTING_STARTED_PROGRESS` | Boolean | `False` | If `true`, hides the getting-started onboarding progress UI. Not automatically enabled when `LANGFLOW_EMBEDDED_MODE=true`. |
|
||||
@ -155,6 +155,26 @@ For all changes, see the [Changelog](https://github.com/langflow-ai/langflow/rel
|
||||
|
||||
For setup instructions and configuration details, see [Manage vector data](/knowledge).
|
||||
|
||||
- MCP server management lock
|
||||
|
||||
Set `LANGFLOW_MCP_SERVERS_LOCKED=true` to prevent non-superusers from adding, editing, or removing MCP server connections.
|
||||
|
||||
For more information, see [Restrict MCP server management to superusers](/mcp-server#restrict-mcp-server-management).
|
||||
|
||||
- Embedded mode UI flags
|
||||
|
||||
Set `LANGFLOW_EMBEDDED_MODE=true` to hide standalone UI elements when embedding the Langflow visual editor in another application.
|
||||
|
||||
These flags control UI visibility only. They do not block the underlying API endpoints.
|
||||
|
||||
For more information, see [Embedded mode](/environment-variables#embedded-mode).
|
||||
|
||||
- Custom component admin-only restriction
|
||||
|
||||
Set `LANGFLOW_CUSTOM_COMPONENT_ADMIN_ONLY=true` to restrict custom component creation and code editing to superusers.
|
||||
|
||||
For more information, see [Restrict custom component creation to superusers](/deployment-block-custom-components#restrict-custom-components-to-superusers).
|
||||
|
||||
- macOS support matrix
|
||||
|
||||
A new [macOS support](./macos-support-matrix.mdx) page documents feature availability across Apple Silicon and Intel Macs.
|
||||
|
||||
Reference in New Issue
Block a user