docs(api): document verification and files on the compare endpoint (#39440)

`GET /repos/{owner}/{repo}/compare/{basehead}` reads `verification` and
`files` (both default true), the same as the commit endpoints do:

```go
verification := ctx.FormString("verification") == "" || ctx.FormBool("verification")
files := ctx.FormString("files") == "" || ctx.FormBool("files")
```

The spec only lists `output`, so generated clients cannot turn either
off. This documents both with the wording the commit endpoints already
use and regenerates the spec.

Co-authored-by: bircni <bircni@icloud.com>
This commit is contained in:
Roshan Ramani
2026-09-26 21:59:02 +05:30
committed by GitHub
parent 4eebefbce5
commit 3fac5059de
3 changed files with 36 additions and 0 deletions
+8
View File
@@ -48,6 +48,14 @@ func CompareDiff(ctx *context.APIContext) {
// enum:
// - diff
// - patch
// - name: verification
// in: query
// description: include verification for every commit (disable for speedup, default 'true')
// type: boolean
// - name: files
// in: query
// description: include a list of affected files for every commit (disable for speedup, default 'true')
// type: boolean
// responses:
// "200":
// "$ref": "#/responses/Compare"