extended-salmon
extended-salmon•3mo ago

Is it possible to send the call Id through the mcp tool ?

I am trying to figure out if it would be possible to send the call id when an mcp tool call is made during a call so that i can map the call data?
8 Replies
optimistic-gold
optimistic-gold•3mo ago
We're actually looking at something similar - we want to use an MCP server in a multitenant fashion. Is there a way to pass the assistantId or call id to give the tool / action more context? Is there a limit to how many MCP servers we can add? Can we just attach them as tools?
foreign-sapphire
foreign-sapphire•3mo ago
Yes, by including context.callId as a parameter in your tool schema, or use the built-in get_call tool to retrieve it during the session..
extended-salmon
extended-salmonOP•3mo ago
thanks @Kings_big💫 so it would be something on the likes of the following inside the prompt ? use the get_call tool to retrieve the call id and assistant id and map it to the callId and assistantId variable
foreign-sapphire
foreign-sapphire•3mo ago
Yes
extended-salmon
extended-salmonOP•3mo ago
@Kings_big💫 it didn't work for me unfortunately. this is the call id 6466a2b0-5b11-42b5-9440-8c2c4e5569a2
Sahil
Sahil•3mo ago
Hi Raju, The Call ID is already included in the request payload your MCP server receives. You can extract it directly from there—there’s no need to embed it in the prompt. Manually adding it won’t work because the assistant isn’t configured to pass the Call ID to a tool. Once you pull it from the payload, your tool calls should function correctly.
extended-salmon
extended-salmonOP•3mo ago
@Shubham Bajaj im guessing this will only work with a pure mcp server and not in an n8n mcp trigger node. Can you confirm this ? I don't see a way of doing it inside n8n
Sahil
Sahil•3mo ago
Yes, it will work with the N8N MCP servers as well. If you have a doubt, you can share a call id. I will pinpoint exactly how it looks like.

Did you find this page helpful?