Skip to content

h5p-mcp-app: Claude rejects the card when --domain is set #329

Done

Description

@alekswebnet

With --domain https://lessons.example, the card's _meta.ui.domain is that origin. Claude checks ui.domain against its own form, <first 32 hex of sha256(connector URL)>.claudemcpcontent.com, and fails the card:

[mcp-ext-apps-host] ui.domain validation failed for connector "https://lessons.example". Compute the expected ui.domain by substituting your full connector URL into: …

domain is ChatGPT's setting, and ChatGPT reads it from openai/widgetDomain as well (an Apps SDK alias that OpenAI keeps). MCP Apps leaves the form of ui.domain to each chat, so one value cannot suit both.

Fix: write each chat's own form. ChatGPT's stays domain, as openai/widgetDomain. Claude's, as _meta.ui.domain, is computed from the address each request was sent to (<origin>/mcp, the only path the server answers), as Claude computes it from the connector's address. Claude's docs: a bad value shows an error in place of the card, and a site framed in the card keeps localStorage only with a valid one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions