Repository navigation
docs: describe the groups and workspace quota API operations - #31544
Closed
nickvigilante wants to merge 1 commit into
Closed
nickvigilante wants to merge 1 commit into
nickvigilante wants to merge 1 commit into
Conversation
The REST API reference renders these routes from swagger.json, and they had no description. This describes the group and group member routes and the workspace quota routes, improves their parameter text, and corrects the group path parameter on the update and delete routes, which takes a group ID and not a name. Part of DOCS-1439. Assisted-by: AI
Collaborator
Author
|
Combined into #31562, where this PR's changes are the commit Generated by Coder Agents on behalf of @nickvigilante. |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This adds a
@Descriptionto the 11 group, group member, and workspace quota routes in the Enterprise tag that had none, and improves the text of their parameters.The REST API reference renders these routes from
swagger.json, so their pages showed only a title.I also fixed existing parameter text on routes in this list: the
grouppath parameter onPATCH /api/v2/groups/{group}andDELETE /api/v2/groups/{group}saidGroup name, but the route resolves a group ID withExtractGroupParam, so it now saysGroup ID.The
has_memberquery parameter saidUser ID or name, and the handler resolves a user ID or username, so it now says that.Merge notes
This PR doesn't touch #31473's exemption lists.
If #31473 merges first,
TestEndpointsDocumentednames each route on this PR to remove from those lists.Verification
A JSON diff of
swagger.jsonagainstorigin/mainshows 11 operation descriptions and 27 parameter descriptions changed, and nothing else.The four remaining thin parameters are
grouppath IDs that accept only a UUID, soGroup ID.is complete.Claims checked against the code
/api/v2/groupsand/api/v2/organizations/{organization}/groupsenterprise/coderd/coderd.go:533-537,650-653(templateRBACEnabledMW),enterprise/coderd/templates.go:348-367(RequireFeatureMW(FeatureTemplateRBAC))budgetis-1without the template RBAC entitlemententerprise/coderd/coderd.go:520-530,687-694,enterprise/coderd/workspacequota.go:225-242GET /api/v2/groups,GET /api/v2/organizations/{organization}/groupscoderd/database/dbauthz/dbauthz.go:4370-4380(fetchWithPostFilter)GET /api/v2/groupsorganizationis an ID or name,has_memberan ID or username,group_idsUUIDsenterprise/coderd/groups.go:714-745GET /api/v2/organizations/{organization}/groupsGET /api/v2/groupswithorganizationsetenterprise/coderd/groups.go:556-563coderd/database/dbauthz/dbauthz.go:4342-4348(fetchWithPostFilter)GET /api/v2/groups/{group},GET .../groups/{groupName}coderd/rbac/roles.go:281-283,489,522,543,630,660,687,coderd/database/dbauthz/dbauthz.go:4323-4329GET /api/v2/groups/{group}exclude_membersomitsmembers;total_member_countis still returnedenterprise/coderd/groups.go:436-452,codersdk/groups.go:34-37PATCH /api/v2/groups/{group}coderd/database/dbauthz/dbauthz.go:8282-8287,coderd/rbac/roles.go:422,543,587-610,660PATCH /api/v2/groups/{group}Everyonecan't be renamed, given a display name, or have members changedenterprise/coderd/groups.go:137-149,162-167PATCH /api/v2/groups/{group}add_usersandremove_usersmust be organization membersenterprise/coderd/groups.go:170-205DELETE /api/v2/groups/{group}Everyonecan't be deletedcoderd/database/dbauthz/dbauthz.go:2464-2466,enterprise/coderd/groups.go:373-378POST /api/v2/organizations/{organization}/groupscoderd/database/dbauthz/dbauthz.go:6672-6674,coderd/rbac/roles.go:422,543,587-610,660POST /api/v2/organizations/{organization}/groups409on a duplicate name;Everyone,new,createrejected; 255 characters at mostenterprise/coderd/groups.go:58-85,codersdk/name.go:124-137POST,PATCHgroupsquota_allowanceadds to each member's budgetcoderd/database/queries/quotas.sql:1-15GET .../membersroutesqbare term and keys;limit,offset,after_idfollowParsePagination,0means no limitcoderd/searchquery/search.go:206-232,coderd/pagination.go:14-24,coderd/database/queries/groupmembers.sql(GetGroupMembersByGroupIDPaginated)coderd/database/dbauthz/dbauthz.go:5034-5048,coderd/rbac/roles.go:463,488,521,539,594,650coderd/database/queries/quotas.sql:1-15,enterprise/coderd/workspacequota.go:225-242GET /api/v2/workspace-quota/{user}enterprise/coderd/workspacequota.go:186-205organizationanduserpath parametersdefault; ID, username, ormeenterprise/coderd/coderd.go:520-538,coderd/httpmw/organizationparam.go:69-84,coderd/httpmw/userparam.go:36-44doc-check self-check
Author self-check mode, run on the annotation text in the diff, with nothing posted to GitHub.
Personas that ran: Fact Checker, Consistency, Language, and Skeptic (verifier).
Personas skipped: Cartographer, Newcomer, Reader Advocate, and Architect, because no hand-written docs page or navigation changed, only annotation text and its generated output.
No blocking findings remain.
make lint/emdashpassed, and the generateddocs/reference/api/enterprise.mdwent through the markdownlint step ofmake gen.Writing rules applied
RequireFeatureMW, here throughtemplateRBACEnabledMW, and not on the workspace quota routes.roles.go.@Deprecatedand names the replacement by its full path.organization,user,limit,offset, andafter_idparameters where the handler matches it.CI flakes unrelated to this change
test-go-pg-17failed incoderd/x/chatdTestChatTurnStopsAtStepLimit/Default, a package this PR doesn't touch: https://github.com/coder/coder/actions/runs/40930616886/job/123647935215Part of DOCS-1439.
Generated by Coder Agents on behalf of @nickvigilante.