Stable OAuth Auto Verification With Custom IdP For Python - #18
Open
bettercallsaulj wants to merge 12 commits into
Open
Stable OAuth Auto Verification With Custom IdP For Python#18bettercallsaulj wants to merge 12 commits into
bettercallsaulj wants to merge 12 commits into
Conversation
added 12 commits
August 20, 2026 00:30
Summary: Add a reusable pytest helper for refresh-token exchanges against arbitrary OAuth token endpoints. Validate token responses and surface OAuth error codes without leaking fixture secrets. Cover successful refreshes, HTTP failures, OAuth errors, and malformed token responses.
Summary: Add a deterministic local OAuth/OIDC IdP test harness with metadata, JWKS, authorize, and token endpoints. Support fixed fixture credentials and deterministic token, invalid_client, invalid_grant, unsupported_grant_type, and invalid_request responses. Cover metadata, token exchange, error behavior, and cleanup with focused pytest tests.
Summary: Add a local protected MCP endpoint harness for direct server and gateway URL shapes. Return OAuth challenges for missing or wrong bearer tokens and expose protected-resource metadata pointing to the custom IdP issuer. Cover challenge behavior, metadata parity, authenticated access, and cleanup with focused pytest tests.
Summary: Add a stable direct MCP endpoint OAuth auto test through GopherAgent.create_with_url. Mock the native FFI boundary and assert the refreshed deterministic access_token reaches agent_create_by_url runtime options. Add custom IdP dynamic registration support required by the existing OAuth resolver path.
Summary: Extend the custom IdP OAuth auto test to cover the MCP gateway endpoint shape. Reuse the direct endpoint setup and assertions so gateway and server coverage stay parallel. Verify GopherAgent.create_with_url injects the deterministic access_token for gateway URLs.
Summary: Add deterministic failure-mode coverage for custom IdP OAuth auto verification. Cover invalid_grant, invalid_client, unsupported grant type, invalid protected-resource metadata, wrong bearer token rejection, and refresh fallback cleanup. Assert failure messages stay free of fixture secrets.
Summary: Add a focused script for the custom IdP OAuth auto pytest suite. Select python, python3, or PYTHON so the command works across local shells and CI. Keep the command limited to local deterministic tests without Gmail, hosted services, or secrets.
Summary: Add a dedicated OAuth verification workflow for pull requests and manual runs. Run the focused custom IdP pytest suite on Ubuntu and macOS. Keep the CI path independent from hosted Gopher endpoints, Gmail, and GitHub Secrets.
Summary: Document the deterministic custom IdP OAuth auto verification path. Explain direct server and gateway endpoint coverage with local fixture credentials. Clarify that Gmail and real Gopher endpoint checks remain optional smoke tests.
Summary: Document the proposed native end-to-end OAuth verification shape. Keep the native path separate from the stable pull-request gate until deterministic. Link the follow-up from the custom IdP OAuth verification guide.
Summary: Remove pull-request triggering from the live SDK example workflow. Keep live example verification available through schedule, branch push, and manual dispatch. Document that the custom IdP workflow is the stable pull-request OAuth gate.
Summary: Assert the OAuth verify workflow is the pull-request SDK OAuth gate. Assert the live example workflow remains optional for smoke verification. Include the branch push trigger for OAuth verification on the feature branch.
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.
No description provided.