fix(den): standardize external MCP OAuth on enterprise client - #2810
Merged
reachjalil merged 10 commits intoJul 15, 2026
Conversation
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
@reachjalil is attempting to deploy a commit to the Different AI Team on Vercel. A member of the Team first needs to authorize it. |
reachjalil
marked this pull request as ready for review
July 15, 2026 20:36
…mcp-oauth # Conflicts: # ee/apps/den-api/src/routes/org/mcp-connections.ts # ee/apps/den-web/app/(den)/dashboard/_components/mcp-connections-screen.tsx
This was referenced Jul 16, 2026
benjaminshafii
added a commit
that referenced
this pull request
Jul 25, 2026
…t path (#3122) An external MCP capability got 30s for the whole session -- connect, OAuth refresh, initialize and tools/call shared one budget -- and execute_capability spent that budget twice, once for schema-digest discovery and once for the call. Slow providers died at ~31s. The 120s/150s tool budget from #2750 was never reached. #2810 deleted the legacy runtime, so callExternalMcpTool resolves to the enterprise client, and the adapter's tool-call path forwarded no lifecycle deadline -- unlike listExternalMcpTools beside it -- leaving the package's 30s default in charge. A Math.min(operationTimeoutMs, ...) clamp meant injecting the longer deadline would have been clipped back to 30s anyway. The only test asserting 120s exercised the bypassed file. Make an injected lifecycle deadline authoritative in both directions and demote operationTimeoutMs to the fallback default. Forward the deadline on the tool-call path, and share one deadline between discovery and the call so the handshake and the budget are paid once. Split the per-request timeout from the absolute bound and stop cancelling a provider that is still reporting progress, matching the calling harness instead of being stricter than it; the SDK only attaches a progressToken when an onprogress handler is present, so the flag alone was inert.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes from
devdevalready has Den-managed external MCP connections, shared and per-connection callback routes, connection editing, and non-destructive Disconnect. This PR makes these specific changes:@openwork/enterprise-mcp-clientfor remote MCP discovery, OAuth, refresh, tool listing, and tool calls. It removes the environment flag, organization engine setting, runtime toggle, and legacy runtime selection.New version-two OAuth transactions use the enterprise package. Version-one transactions already in flight can finish through their original verifier only for the existing ten-minute state lifetime.
Review map
ee/apps/den-api/src/capability-sources/external-mcp-client-runtime.tsee/apps/den-api/src/capability-sources/external-mcp-connections.tsandee/apps/den-api/src/routes/org/mcp-connections.tsee/apps/den-api/src/capability-sources/oauth-callback-page.tspackages/enterprise-mcp-client/src/oauth-discovery-binding.tspackages/enterprise-mcp-client/src/authorization-response.ts,oauth-provider.ts, andrequirements-discovery.tsee/apps/den-web/app/(den)/dashboard/_components/mcp-connections-screen.tsxpackages/docs/cloud/share-with-your-team/shared-mcp-connections.mdxCurrent
devsyncThe branch includes
upstream/devthrough480dcfbf(feat(den): support non-destructive MCP disconnect). Its admin/member Disconnect behavior, creator attribution, API changes, and tests are retained. At publication, the branch is 0 commits behindupstream/dev.Validation
@openwork/enterprise-mcp-client: 36 tests passed; package build passed.Scope
This changes only Den-managed OpenWork Connect. Local/direct engine MCP and the engine-to-Den meta-MCP are unchanged. The implementation and tests follow MCP/OAuth metadata contracts and contain no provider-specific runtime branch. Optional Vercel previews can report authorization-required because the fork cannot deploy to the upstream Different AI project; that is not a code-test failure.