Skip to content

[Remote MCP] Error when trying to log in - Error: Metadata error: #5953

Closed

Description

@MrAshRhodes

What version of Codex is running?

codex-cli 0.50.0

What subscription do you have?

api key

Which model were you using?

gpt-5

What platform is your computer?

Darwin 25.1.0 arm64 arm

What issue are you seeing?

Ive set my config to use a remote mcp with oauth.

I have set - experimental_use_rmcp_client = true

[mcp_servers.remote]
type = "http"
url = "https://xxxx.com/mcp/default"

when using codex mcp login remote

Error: Metadata error: Failed to parse metadata: error decoding response body

The mcp server and oauth work in other applications i.e copilot, claude etc

What steps can reproduce the bug?

set config for a remote server

run codex mcp login $server_name

What is the expected behavior?

directed to an oauth login page for authentication.

Additional information

No response

Activity

  1. added
    bug
    on Oct 30, 2025
  2. added
    mcp
    on Oct 30, 2025
  3. github-actions commented on Oct 30, 2025

    @github-actions
    Contributor

    Potential duplicates detected. Please review them and close your issue if it is a duplicate.

    Powered by Codex Action

  4. gpeal commented on Oct 30, 2025

    @gpeal
    Contributor

    Can you share the MCP server? Is the url publicly accessible even if I may or may not be able to log in?

  5. benglewis commented on Nov 4, 2025

    @benglewis

    I am getting this with HuggingFace's MCP:

    $ codex mcp add --url "https://huggingface.co/mcp?login" huggingface

    Added global MCP server 'huggingface'.
    Detected OAuth support. Starting OAuth flow…
    Error: Metadata error: Failed to parse metadata: error decoding response body

  6. sorech commented on Nov 25, 2025

    @sorech

    I had the same problem and traced it to the MCP rust-sdk and fixed it there.
    The fix is now incorporated in release:
    https://github.com/modelcontextprotocol/rust-sdk/releases/tag/rmcp-v0.9.1

    All that is left is to bump
    rmcp = { version = "0.9.0", default-features = false } -> rmcp = { version = "0.9.1", default-features = false }
    https://github.com/openai/codex/blob/0dd822264a9265749d4f698674553a8d8f747ede/codex-rs/Cargo.toml#L171C1-L171C55

  7. bolinfest commented on Dec 2, 2025

    @bolinfest
    Collaborator
  8. etraut-openai commented on Mar 29, 2026

    @etraut-openai
    Contributor

    This bug report hasn't received any upvotes or additional posts in three months. Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugmcp

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions