Repository navigation
Surface redirect_uris and is_public in client list/get output - #23
Merged
Merged
Conversation
_format_client() projected only id/name/description/created_at/ permissions, so client list/get --json silently dropped redirect_uris and is_public — forcing admins off the CLI during redirect_uri registration surveys (campus will enforce exact-match redirect_uri validation at /authorize, RFC 6749 §3.1.2.2). Both fields are now projected (null redirect_uris coerced to []), and table mode prints each redirect URI plus a public-client flag line. Fixes #21
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.
Fixes #21
What
_format_client()projected onlyid,name,description,created_at,permissions, socampus client list --jsonandcampus client get --jsonsilently droppedredirect_urisandis_public. Both fields are now projected, and table mode shows them too."redirect_uris": client.redirect_uris or [](null coerced to[]) and"is_public": client.is_publicto the projection used byclient list/get/new/update --json.Redirect URIs:block (one URI per line,(none)when empty) and aPublic client: yes|noline — indented under each client inclient list, appended after Permissions inclient get/new/updatedetails. Existing lines are unchanged.Why
redirect_uri registration is now operational: campus will enforce exact-match
redirect_urivalidation at/authorize(RFC 6749 §3.1.2.2). An admin surveying "which clients have no redirect_uris registered?" was getting a wrong answer from the CLI and had to fall back to the Python API.Tests
redirect_uriscoerces to[].client get/list/update --jsonpayloads expose the fields; table mode renders the URI block and public flag.Mock(name=...)names the mock rather than setting the attribute, which broke JSON serialization onceclient get --jsongained a test..venv).