web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Copilot Studio - Model Context Protocol
Suggested answer

How to pass a variable value as header to MCP tool?

(3) ShareShare
ReportReport
Posted on by 2
I want to pass a variable value as header to the MCP custom connector from copilot agent. How to achieve this?. Any other alternatives?.
I have the same question (0)
  • CU14071758-0 Profile Picture
    2 on at
    How to pass a variable value as header to MCP tool?
    @Michael E. Gernaey Thanks for looking into this.
    I'm able to pass static values to the MCP server using HTTP Header template in custom connector. But how to have a dynamic value as the header value there?. Also, the header value I want to pass to custom connector is a copilot studio agent variable. There is no option to pass a variable as input or header to the MCP tool in copilot studio agent tools.
  • Suggested answer
    Michael E. Gernaey Profile Picture
    47,111 Super User 2025 Season 2 on at
    How to pass a variable value as header to MCP tool?
     
    Is this your custom connector?
     
    You can certainly add custom headers into it and populate them dynamically. But can I ask also, are you certain that your custom connector can accept it atm? and does the further down MCP server use it as well?
     
    You can however, Go to Definition/Policies/New Policy then create a new HTTP Header Template to add in new custom dynamic ones.

    If these suggestions help resolve your issue, Please consider Marking the answer as such and also maybe a like.

    Thank you!
    Sincerely, Michael Gernaey

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Copilot Studio

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 468 Super User 2025 Season 2

#2
stampcoin Profile Picture

stampcoin 52 Super User 2025 Season 2

#3
trice602 Profile Picture

trice602 46 Super User 2025 Season 2