curl --location 'https://api.mcpfy.ai/dev/v1/generate-mcp-token' \ --header 'Content-Type: application/json' \ --header 'Authorization: Bearer <YOUR_API_KEY>' \ --data-raw '{ "mcpServerId": "63re68ca47d201fa9d2974fa", "customerDetails": { "primaryIdentity": "[email protected]" } }'
{ "status": "success", "data": { "url": "https://mcp.mcpfy.ai/5ftIjklywsiC9u6rMG45Xgtxzq1SAsFv/stream", "token": "5ftIjklywsiC9u6rMG45Xgtxzq1SAsFv", "customerId": "68d1a6ccdde500225e8cd70c" } }
Generate a new MCP URL for a specific server and customer
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Bearer <token>
<token>
MCP server ID and customer details for URL generation
The unique identifier for the MCP server
"63re68ca47d201fa9d2974fa"
Show child attributes
Primary identifier for the customer (typically email)
"[email protected]"
Customer's full name
"John Doe"
Customer's company name
"Acme Corp"
Customer's department
"Engineering"
MCP URL generated successfully
Indicates whether the request was successful
success
error
"success"
The MCP stream URL for connecting to the server
"https://mcp.mcpfy.ai/5ftIjklywsiC9u6rMG45Xgtxzq1SAsFv/stream"
The generated MCP token for authentication
"5ftIjklywsiC9u6rMG45Xgtxzq1SAsFv"
The unique identifier for the customer associated with this token
"68d1a6ccdde500225e8cd70c"
Error code identifying the type of error
"invalid_server_id"
Human-readable error message describing the issue
"The provided MCP server ID is invalid or not found"
Seconds to wait before retrying (only for rate limit errors)
45