When this becomes a decision
This decision becomes necessary when your business needs to connect external services to FastGPT for LLM tool calls, or expose FastGPT-built AI apps via the standardized MCP protocol for external use. Existing tool calling or app publishing methods may not meet cross-platform unified communication needs.
You must make this decision if your team will integrate with multiple MCP-compatible client vendors, or require fine-grained permission isolation for cross-team tool calls. FastGPT v4.9.6 and above supports MCP features. You need to clarify configuration logic and constraints for both MCP usage directions if you use this version or later, have external service integration or app exposure needs, require SSE-compatible MCP services for self-hosted deployments, or need identity proxy for granular permission control.
What to settle first
| Criterion | What to set | Basis |
|---|---|---|
| Whether you need to connect external services to FastGPT as a tool set | Select "Yes" to configure an MCP Toolkit; select "No" to focus on publishing apps as an MCP Server | Official documentation guide/build/tools/mcp_tools |
| Which transport address to use for external exposure | Use Streamable HTTP by default; for self-hosted deployments needing SSE compatibility, deploy the standalone fastgpt-mcp-server service and configure SSEMCPSERVERPROXYENDPOINT | Official MCP publishing and environment variable documentation |
| Whether you need cross-team member permission isolation | Select "Yes" to enable identity proxy and configure request headers; select "No" to use the default identity of the MCP Server publisher | Official documentation guide/build/publish/mcp_server Identity Proxy section |
| Whether your client supports the SSE protocol | Select "Yes" to use SSE transport; select "No" to prioritize Streamable HTTP | Official documentation guide/build/publish/mcp_server |
| Whether your self-hosted FastGPT version meets requirements | MCP Server functionality requires FastGPT v4.9.6 or higher | Official MCP publishing and self-hosted deployment documentation |
| Whether you need to dynamically adjust the execution identity of tool calls | Select "Yes" to use the identity proxy mechanism; select "No" to skip additional identity configuration | Official documentation guide/build/publish/mcp_server Identity Proxy Prerequisites section |
All criteria are independent. You can use both MCP Toolkit and MCP Server at the same time. FastGPT cloud service uses Streamable HTTP directly. Check client compatibility first before using SSE. Identity proxy requires team owner permissions, and you must ensure proxied users are active team members with read access to target apps. The v4.15.7 release notes mention that a failed Streamable HTTP connection falls back to SSE, and that release fixed duplicate request headers during that fallback. Confirm supported transport for each service based on your actual environment.
How to do it
Connect External MCP Services as a Toolkit
- Log into the FastGPT workspace, go to the app creation page, and select New MCP Toolkit.
- Obtain the access URL of the external MCP service, then enter it in the configuration popup.
- Click Parse. The system automatically pulls and parses the tool list from the MCP service.
- Confirm the tool list is correct, then click Create to finish building the toolkit.
- Enter the toolkit page to debug individual tools and verify their availability.
- Use the toolkit in two ways: Select specific tools for the model, or add the entire toolkit node and connect it with a Tool Calling node for the model to automatically select tools.
FastGPT v4.17.0 fixes an issue where MCP tool definitions expired with workflow snapshots by reading definitions at runtime.
Publish FastGPT Apps as an MCP Server
- Log into the FastGPT workspace, click MCP Server to enter the management page.
- Click Create MCP Server, enter a custom name, and select the FastGPT apps to associate (multiple apps are allowed).
- Save the configuration, then click Start Using to get the MCP Server access URL and integration script.
- Import the JSON configuration file into an MCP-compatible client, then enable the MCP Server.
- For example, in Cursor, switch to Agent mode to trigger MCP Server calls.
Transport Protocol and Self-Hosted Deployment Configuration
- Streamable HTTP addresses are provided directly by FastGPT.
- SSE addresses are only available after deploying the standalone fastgpt-mcp-server service for self-hosted deployments.
Self-hosted configuration steps:
- Modify docker-compose.yml to add the fastgpt-mcp-server service, and set FASTGPT_ENDPOINT to the internal access address of FastGPT.
- Add the SSEMCPSERVERPROXYENDPOINT environment variable to the FastGPT container, and set its value to the client-accessible address of the fastgpt-mcp-server service (do not add a trailing /).
- Restart FastGPT and fastgpt-mcp-server services to apply changes.
Identity Proxy Configuration
Prerequisites: Only team owners can enable identity proxy. Proxied users must be active team members with read permission for target apps. The key in the published MCP URL is an execution credential; do not share it with unauthorized users. Configuration steps:
- Edit an existing MCP Server, enable Auth proxy in the publishing settings, then save the configuration.
- If no identity proxy header is included in a request, the tool runs as the MCP Server publisher.
- Pass identity information via MCP transport headers (not tool arguments). FastGPT accepts two headers: Either header is sufficient. If both are provided, they must resolve to the same team member.
x-fastgpt-auth-proxy-username: Team member login username (usually their email address, recommended)x-fastgpt-auth-proxy-tmb-id: FastGPT team member ID (use if your system stores these IDs)
- For MCP clients supporting custom headers, add the headers to the copied integration script.
- For SSE addresses, disconnect and reconnect after modifying request headers. Streamable HTTP reads request headers per call.
- Verify the configuration to confirm correct execution and permission attribution.
How to verify
- Verify external MCP Toolkit access: Click Parse on the FastGPT MCP Toolkit page, confirm the tool list is successfully pulled and displayed. Run an individual tool on the debug page to confirm it returns expected business results.
- Verify MCP Server publishing: On the workspace MCP Server management page, confirm the created server and the number of associated apps are displayed correctly. Import the integration script into an MCP-compatible client, confirm the tool list corresponding to the associated apps is shown.
- Verify transport protocol functionality: Use the Streamable HTTP address to call tools and confirm normal returns. For self-hosted deployments, use the SSE address to connect, confirm the client can list and call tools normally.
- Verify identity proxy functionality: Configure the identity proxy request header, call a tool to confirm it runs under the specified member's identity, and chat and runtime records are attributed to that member. Call a tool without the request header to confirm it runs under the MCP Server publisher's identity.
- Verify permission control: Call a tool using a team member without read permission for the target app, confirm a permission denied prompt is returned. Call the tool using a valid team member, confirm the tool runs normally and returns expected results.
- Verify self-hosted deployment: Confirm the fastgpt-mcp-server service is running normally, confirm the SSEMCPSERVERPROXYENDPOINT configuration in the FastGPT container is correct, and confirm the client can connect to the SSE address MCP Server normally.
Limits: when this approach does not hold
- FastGPT versions below v4.9.6 do not support MCP Toolkit and MCP Server features. You must upgrade your FastGPT version first.
- FastGPT v4.17.1 fixes DNS rebinding SSRF risks and tightens address family validation. If an external MCP address that previously worked fails to resolve after upgrading, confirm the resolved address based on your actual environment.
- Identity proxy cannot function if your client does not support custom MCP protocol request headers, making fine-grained permission control unavailable.
- Some external MCP services may fail to parse in FastGPT due to differences in server-side transport implementations. Confirm compatibility based on your actual environment.
- Tool calls will return permission errors if the proxied team member has left the team or had their read permission for the target app revoked. Regularly clean up invalid proxy member configurations.
- MCP integration or publishing will fail if your enterprise network has strict outbound restrictions that block access to external MCP services or the fastgpt-mcp-server deployment address. Configure network proxies or adjust firewall rules to resolve this.
Keep reading
References
Next steps
The criteria above can be checked against public documentation. To apply this process to a specific deployment, contact sales for support; the cloud service can be used directly to validate the process first.
- Contact sales: apply this process to your deployment
- Get started: validate the process on the cloud service
- Pricing: compare what each form covers