Repository navigation
feat(egress): Expose credentialed egress to plugin tools - #685
Merged
Merged
Conversation
Move the verified provider forwarding path out of the sandbox proxy tree so future host/plugin egress callers can share the same credentialed request engine. The sandbox proxy remains the only caller in this slice, preserving existing auth, permission, and response-hook behavior. Refs GH-660 Co-Authored-By: GPT-5 Codex <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Expose host-owned provider egress to plugin tools through ctx.egress.fetch and route those requests through the shared credentialed forwarding engine. Auth-required responses now reuse the existing plugin auth orchestration path instead of requiring sandbox-originated HTTP. Refs GH-660 Co-Authored-By: GPT-5 Codex <[email protected]>
Thread plugin egress operations into credential grant hooks and make plugin tool egress a required runtime context value instead of a throwing fallback. Preserve upstream permission-denied responses for plugin callers while keeping auth-required handling routed through plugin auth orchestration. Refs GH-660 Co-Authored-By: GPT-5 Codex <[email protected]>
Add an integration path where a registered plugin tool executes through the agent tool wrapper and calls ctx.egress.fetch with host-managed credentials. Refs GH-660 Co-Authored-By: GPT-5 Codex <[email protected]>
Keep the plugin egress unit coverage focused on auth-required and permission-denied failure paths now that the integration test covers the host plugin tool happy path. Refs GH-660 Co-Authored-By: GPT-5 Codex <[email protected]>
Keep plugin egress auth handling on a typed local port and reject non-HTTPS provider URLs before credential issuance. Refs GH-660 Co-Authored-By: GPT-5 Codex <[email protected]>
This branch was successfully deployed
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.
Plugin tool registration contexts now receive a host-owned
ctx.egress.fetch(...)capability for provider HTTP calls. The fetch path resolves the provider host, carries the declared operation into plugin grant and response hooks, selects the provider grant, injects credentials through the shared credentialed egress engine, and routes auth-required failures through the existing plugin auth pause orchestration.The sandbox proxy remains on the same forwarding path, but the credentialed executor now accepts caller-owned ports for lease cleanup and auth/permission handling. That lets host/plugin calls reuse the provider request engine without pretending to originate from sandbox network forwarding, while upstream permission-denied responses still return to plugin callers for normal response handling. Plugin egress also rejects non-HTTPS provider URLs before issuing credentials.
Focused coverage exercises plugin egress, plugin tool registration, and the sandbox proxy path, including operation propagation and upstream 403 pass-through. The integration suite now includes a fake host-registered plugin tool that executes through the agent tool wrapper, calls
ctx.egress.fetch(...), and proves the mocked provider receives host-injected credentials.Refs GH-660