feat: add resolve_endpoint_auth() for decrypted endpoint credentials - #19
Merged
Conversation
The DataMaker API masks credentials (`*******`) on every endpoint read route, so get_endpoint()/get_endpoints() return masked auth. Add a first-class resolve_endpoint_auth(endpoint_id) method that calls POST /endpoints/auth-resolve to obtain an endpoint's real, decrypted credentials (Authorization header + Basic username/password) without reaching into private internals. - EndpointsClient.resolve_endpoint_auth() in routes/custom_types.py - DataMaker.resolve_endpoint_auth() facade in main.py - TestEndpointsClient unit test - documented in llms.txt Closes #18 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EXprocqPaRSLq223PN2FcH
RatulMaharaj
approved these changes
Jun 24, 2026
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.
Summary
Closes #18.
Adds a first-class
resolve_endpoint_auth(endpoint_id)method to the SDK so callers can obtain an endpoint's real, decrypted credentials without reaching into private internals (dm._endpoints._make_request(...)).The DataMaker API masks credentials (
*******) on every endpoint read route, soget_endpoint()/get_endpoints()return masked auth. This new method callsPOST /endpoints/auth-resolve(decryption stays server-side) and returns the real Authorization header (Basic decrypted / OAuth2 token exchanged) plus, for Basic auth, the decrypted username/password.Changes
src/datamaker/routes/custom_types.py—EndpointsClient.resolve_endpoint_auth()src/datamaker/main.py—DataMaker.resolve_endpoint_auth()facade methodtests/test_routes.py—TestEndpointsClientunit test asserting the request shape and response passthroughllms.txt— documented under the Endpoints sectionUsage
Response shape mirrors the API route:
{authType, authHeader, fetchCsrf, basic}(basicisnullfor non-Basic auth). The endpoint is gated by the same access check as the rest of the API (403 if the caller lacks access).Tests
pytest tests/test_routes.py tests/test_main.py -m "not integration"→ 62 passed.Follow-up
Once merged, bump the pinned commit in
datamaker-runner(pyproject.toml+uv.lock) as noted in the issue.🤖 Generated with Claude Code