Skip to content

[Bug]: after issue 1078 change, how to add X-Upstream-Authorization header when click Authorize in admin UI #1092

@feiyang9999

Description

@feiyang9999

🐞 Bug Summary

After #1078 merged, I understand when use curl, it need to add below header info -H "X-Upstream-Authorization: Bearer $MCP_SERVER_TOKEN", but when use admin UI in http://mcpgateway/admin/#gateways, after configure one MCP server as Oauth2, then click button Authorize, it always failed as {"detail":"Authentication required"}, so question is how to add such header info when trigger from admin web UI?

🧩 Affected Component

Select the area of the project impacted:

  • mcpgateway - API
  • mcpgateway - UI (admin panel)
  • mcpgateway.wrapper - stdio wrapper
  • Federation or Transports
  • CLI, Makefiles, or shell scripts
  • Container setup (Docker/Podman/Compose)
  • Other (explain below)

🔁 Steps to Reproduce

  1. login to http://mcpgateway/admin/#gateways
  2. add one MCP server as Oauth2
  3. click button Authorize

🤔 Expected Behavior

It should start Oauth authorize workflow after click the Authorize button.

📓 Logs / Error Output

Paste any relevant stack traces or logs here.
⚠️ Do not paste secrets, credentials, or tokens.


🧠 Environment Info

You can retrieve most of this from the /version endpoint.
commit: 0de855b


🧩 Additional Context (optional)

Add any configuration details, flags, or related issues.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingtriageIssues / Features awaiting triage

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions