Understanding the Problem
The community member tried using two different URLs: https://api.salesforce.com/platform/mcp/v1/
The issue was resolved when the community member changed the URL to the correct one. The correct URL is not explicitly stated in the Salesforce documentation, which can cause confusion.
The root cause of the issue is the incorrect URL used to connect to the hosted MCP server. The Salesforce documentation provides an example URL, but it is not applicable to custom MCP servers.
Troubleshooting Steps
To troubleshoot this issue, you can follow these steps:
- Check the URL used to connect to the hosted MCP server.
- Verify that the URL is in the correct format.
- Try changing the URL to the correct one.
Example Code
HostedMCPConnection.js
var serverName = "custom/chatgptserver"; var url = "https://api.salesforce.com/platform/mcp/v1/" + serverName; // Use the correct URL to connect to the hosted MCP server
Heads up: Make sure to use the correct URL for your custom MCP server.
Checklist
- Verify the URL used to connect to the hosted MCP server.
- Check the format of the URL.
- Try changing the URL to the correct one.
- Verify that authentication is successful.
- Test the feature after connecting to the hosted MCP server.
Frequently Asked Questions
What is the correct URL for connecting to a hosted MCP server?
The correct URL should be in the format https://api.salesforce.com/platform/mcp/v1/
Why is authentication successful but the feature cannot be tested?
This can be due to an incorrect URL or other configuration issues.
How do I troubleshoot the hosted MCP server connection issue?
You can follow the troubleshooting steps outlined above, including checking the URL and verifying authentication.
What is the difference between the free and paid versions of ChatGPT?
The free version of ChatGPT has limitations, and the paid version provides more features and capabilities.
Need help shipping this in production?
Genetrix builds and untangles Salesforce Marketing Cloud and Agentforce setups for teams that want it done right the first time. If anything in this post sounds familiar, talk to us before it ships.