Repository navigation
docs: describe the AI Gateway API operations and parameters - #31527
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 adds a description for the AI Gateway providers route and fuller text for the sessions limit parameter. 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.
Adds a
@DescriptiontoGET /api/v2/ai-gateway/providers, replaces the thinlimittext onGET /api/v2/ai-gateway/sessions, and backticks a path in the existingGET /api/v2/ai-gateway/sessions/{session_id}description.The REST API reference renders these routes from
swagger.json, and the providers route showed only a title.The other AI Gateway routes already have descriptions, so I left them alone.
The one edit to an existing description wraps
/api/v2/aibridge/sessions/{session_id}in backticks, because raw braces break the MDX renderer andcheck_routes.pyflags it.Merge notes
This PR doesn't touch the exemption lists in #31473.
If #31473 merges first,
TestEndpointsDocumentednames each route on this PR to remove from those lists.Verification
The
swagger.jsondiff againstorigin/mainchanges onlydescriptionvalues (3 changed, proven with a JSON walk that fails on any other change).Doc-check self-check
Ran the
doc-checkskill in author self-check mode on the branch diff, one persona at a time: Fact Checker, Continuity Editor, Copy Editor, then Skeptic on the survivors.No blocking findings. One finding rejected by the verifier, so there is no follow-up commit.
Skeptic rejected 1 finding.
Rejected: a Copy Editor note on the relative "which" in the providers description, because the pronoun rule covers
it,this,they, andthat, and the referent is clear.Claims checked against the code
GET /api/v2/ai-gateway/providersenterprise/coderd/coderd.go:317-326(RequireFeatureMW(FeatureAIBridge))GET /api/v2/ai-gateway/providerscoderd/database/dbauthz/dbauthz.go:3115-3125,coderd/rbac/roles.go:421-432,499GET /api/v2/ai-gateway/providersenterprise/coderd/aibridge.go:654-675,coderd/database/dbauthz/dbauthz.go:3116-3118GET /api/v2/ai-gateway/sessionslimitdefaults to 100, maximum 1000enterprise/coderd/aibridge.go:36-39,185-193Writing rules applied
dbauthzandroles.go.RequireFeatureMW.limitdefault and maximum instead of the shared wording./api/v2paths and backticks around field names and literals.CI flakes unrelated to this change
test-go-pg (windows-2022)failed inTestAPISessionRecoveryWriteDeadline/message, which this PR doesn't touch: https://github.com/coder/coder/actions/runs/40925178654/job/123628850409Part of DOCS-1439.
Generated by Coder Agents on behalf of @nickvigilante.