Skip to content

Outbound Apps: expose the console's MCP-URL DCR auto-discovery via the SDK/API #750

Description

@tarracharan-glitch

Hi Descope team — a gap between the console and the SDK/API for DCR outbound
apps.

In the console, creating a DCR outbound app needs only the MCP server
URL
— Descope auto-discovers the OAuth endpoints (walks the discovery chain)
and registers the client; everything autofills on save.

Via the SDK/API there's no equivalent. Passing the resource URL as
discoveryUrl with useDcr: true fails:

await client.management.outboundApplication.createApplication({
  id, name,
  useDcr: true,
  discoveryUrl: "https://mcp.notion.com/mcp",
  defaultRedirectUrl: "https://api.descope.com/v1/outbound/oauth/callback",
});
// → E152006 "Failed to perform dynamic client registration" / "Failed to parse server URL"

So to register a DCR app programmatically, we have to reimplement the
discovery the console already does
— walk
www-authenticateoauth-protected-resourceauthorization_servers
.well-known/oauth-authorization-serverregistration_endpoint, then pass
that as dcrUrl (a field that isn't even in the OutboundApplication type —
see #746).

Ask

Let createApplication accept the MCP resource URL for DCR and perform the
same MCP-aware discovery the console does, server-side — so consumers don't have
to re-derive the registration endpoint themselves. (Either teach discoveryUrl
to accept an MCP resource URL, or add an explicit mcpUrl/resourceUrl input.)

Environment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions