{"openapi":"3.1.0","info":{"title":"Kvarm REST API","version":"1","description":"Every operation is also an MCP tool on /mcp (named by operationId) and a `kvarm` CLI command. Authenticate with a personal access token (kvarm_pat_…) or a repository-scoped agent token (kvarm_agt_…) as `Authorization: Bearer <token>`; see /auth.md. Errors are `{\"error\": \"...\", \"code\": \"...\"}`. Every response carries an x-kvarm-cost work counter."},"servers":[{"url":"https://kvarm.dev"}],"externalDocs":{"description":"Agent guide","url":"https://kvarm.dev/llms.txt"},"security":[{"bearer":[]},{}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"kvarm_pat_… personal access token or kvarm_agt_… agent token"}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"string"},"code":{"type":"string"}}}}},"paths":{"/api/v1/user":{"get":{"operationId":"get_user","summary":"Show the authenticated human account (login, email, admin flag). Agent tokens are refused.","tags":["user"],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm user get","x-mcp-tool":"get_user","x-read-only":true}},"/api/v1/repos":{"get":{"operationId":"list_repos","summary":"List the repositories owned by the authenticated user (same set as GET /api/v1/repos).","tags":["repos"],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm repo list","x-mcp-tool":"list_repos","x-read-only":true},"post":{"operationId":"create_repo","summary":"Create a repository owned by the authenticated user. Visibility defaults to private.","tags":["repos"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Repository name"},"description":{"type":"string","description":"Short description"},"visibility":{"type":"string","enum":["public","private"],"description":"public or private (default private)"},"defaultBranch":{"type":"string","description":"Default branch name (default main)"}},"required":["name"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm repo create","x-mcp-tool":"create_repo","x-read-only":false}},"/api/v1/repos/{owner}/{name}":{"get":{"operationId":"get_repo","summary":"Repository metadata (visibility, default branch, clone URL). Private repos you cannot read are not found.","tags":["repos"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm repo get","x-mcp-tool":"get_repo","x-read-only":true},"patch":{"operationId":"update_repo","summary":"Change a repository description or visibility. Needs the admin role on the repository.","tags":["repos"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"description":{"type":"string","description":"New description"},"visibility":{"type":"string","enum":["public","private"],"description":"public or private"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm repo update","x-mcp-tool":"update_repo","x-read-only":false},"delete":{"operationId":"delete_repo","summary":"Delete a repository with its git data, workspaces, changes and snapshots. Needs the admin role; agent tokens are refused.","tags":["repos"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm repo delete","x-mcp-tool":"delete_repo","x-read-only":false,"x-destructive":true}},"/api/v1/repos/{owner}/{name}/forks":{"post":{"operationId":"fork_repo","summary":"Fork a repository you can read into a new private repository owned by you. Agent tokens are refused.","tags":["repos"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Fork name (default <name>-fork)"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm repo fork","x-mcp-tool":"fork_repo","x-read-only":false}},"/api/v1/import":{"post":{"operationId":"import_repo","summary":"Import an HTTPS git remote into a new repository owned by you (status importing). Agent tokens are refused.","tags":["repos"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"url":{"type":"string","description":"HTTPS git remote to import"},"name":{"type":"string","description":"Repository name (default: the last segment of the URL)"},"branch":{"type":"string","description":"Branch to import (optional)"},"visibility":{"type":"string","enum":["public","private"],"description":"public or private (default private)"}},"required":["url"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm repo import","x-mcp-tool":"import_repo","x-read-only":false}},"/api/v1/repos/{owner}/{name}/tree":{"get":{"operationId":"get_tree","summary":"List the entries (name, type, mode, hash) of a directory at a ref, like git ls-tree <ref> [<dir>].","tags":["content"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"path","in":"query","required":false,"description":"Directory path (default: the repository root)","schema":{"type":"string"}},{"name":"ref","in":"query","required":false,"description":"Branch, tag or commit SHA (default: the default branch)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm tree get","x-mcp-tool":"get_tree","x-read-only":true}},"/api/v1/repos/{owner}/{name}/contents":{"get":{"operationId":"read_file","summary":"Read one file at a ref. Text comes back as utf-8, anything else as base64 (encoding field).","tags":["content"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"path","in":"query","required":true,"description":"File path","schema":{"type":"string"}},{"name":"ref","in":"query","required":false,"description":"Branch, tag or commit SHA (default: the default branch)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm file read","x-mcp-tool":"read_file","x-read-only":true}},"/api/v1/repos/{owner}/{name}/events":{"get":{"operationId":"list_events","summary":"Push events recorded for the repository, newest first, with the per-effect processing state.","tags":["content"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm event list","x-mcp-tool":"list_events","x-read-only":true}},"/api/v1/repos/{owner}/{name}/history":{"get":{"operationId":"get_path_history","summary":"Commits on the default branch that changed a path, newest first (first-parent history, like git log --first-parent -- <path>). The index is built on demand in bounded steps; index.complete says whether the list is the whole history, and repeating the call advances an incomplete index.","tags":["content"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"path","in":"query","required":true,"description":"File path","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm file history","x-mcp-tool":"get_path_history","x-read-only":true}},"/api/v1/repos/{owner}/{name}/snapshots/{ref}":{"get":{"operationId":"get_snapshot","summary":"Snapshot metadata for a ref (ready, building, absent or failed). Never starts a build.","tags":["content"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"ref","in":"path","required":true,"description":"Branch, tag or commit SHA","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm snapshot get","x-mcp-tool":"get_snapshot","x-read-only":true},"post":{"operationId":"request_snapshot","summary":"Demand a snapshot build for a ref; returns the metadata view plus started:true|false.","tags":["content"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"ref","in":"path","required":true,"description":"Branch, tag or commit SHA","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm snapshot request","x-mcp-tool":"request_snapshot","x-read-only":false}},"/api/v1/repos/{owner}/{name}/compare/{base}...{head}":{"get":{"operationId":"compare","summary":"Changed files between two commit-ishes (direct two-tree diff) with totals and a risk rating.","tags":["compare"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"base","in":"path","required":true,"description":"Base branch, tag, full ref or commit SHA","schema":{"type":"string"}},{"name":"head","in":"path","required":true,"description":"Head branch, tag, full ref or commit SHA","schema":{"type":"string"}},{"name":"order","in":"query","required":false,"description":"File order: path (default) or risk","schema":{"type":"string","enum":["path","risk"]}},{"name":"limit","in":"query","required":false,"description":"Page size (1-5000)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm compare get","x-mcp-tool":"compare","x-read-only":true}},"/api/v1/repos/{owner}/{name}/compare/{base}...{head}/file":{"get":{"operationId":"get_file_diff","summary":"Hunks of one changed file between two commit-ishes (git -U3 numbering).","tags":["compare"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"base","in":"path","required":true,"description":"Base branch, tag, full ref or commit SHA","schema":{"type":"string"}},{"name":"head","in":"path","required":true,"description":"Head branch, tag, full ref or commit SHA","schema":{"type":"string"}},{"name":"path","in":"query","required":true,"description":"Changed file path","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm compare file","x-mcp-tool":"get_file_diff","x-read-only":true}},"/api/v1/repos/{owner}/{name}/commits/{sha}/diff":{"get":{"operationId":"get_commit_diff","summary":"Changed files of one commit against its first parent (the empty tree for a root commit).","tags":["compare"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"sha","in":"path","required":true,"description":"Full 40-hex commit SHA","schema":{"type":"string"}},{"name":"order","in":"query","required":false,"description":"File order: path (default) or risk","schema":{"type":"string","enum":["path","risk"]}},{"name":"limit","in":"query","required":false,"description":"Page size (1-5000)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm commit diff","x-mcp-tool":"get_commit_diff","x-read-only":true}},"/api/v1/repos/{owner}/{name}/workspaces":{"post":{"operationId":"create_workspace","summary":"Create an agent workspace: a server-side ref refs/heads/agents/<id>/<slug> at the base head, with an optional intent declaration.","tags":["workspaces"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"task":{"type":"string","description":"What the workspace is for (1-500 characters)"},"agent":{"type":"string","description":"Agent display name (default: the token agent or your login)"},"base":{"type":"string","description":"Base branch (default: the default branch)"},"intent":{"description":"Optional intent declaration {paths: string[], prefixes?: string[], ttlSeconds?: number}"},"issue":{"type":"integer","description":"Open issue the workspace resolves: the change it opens closes the issue when it merges into the default branch"}},"required":["task"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm workspace create","x-mcp-tool":"create_workspace","x-read-only":false},"get":{"operationId":"list_workspaces","summary":"Workspaces of the repository, newest first.","tags":["workspaces"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"status","in":"query","required":false,"description":"active, merged, abandoned or all (default all)","schema":{"type":"string","enum":["active","merged","abandoned","all"]}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm workspace list","x-mcp-tool":"list_workspaces","x-read-only":true}},"/api/v1/repos/{owner}/{name}/workspaces/{workspace}":{"get":{"operationId":"get_workspace","summary":"One workspace with its live head.","tags":["workspaces"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm workspace get","x-mcp-tool":"get_workspace","x-read-only":true}},"/api/v1/repos/{owner}/{name}/workspaces/{workspace}/change-set":{"post":{"operationId":"create_change_set","summary":"Open the change set of a workspace (head = the workspace branch) with an explicit merge policy.","tags":["workspaces"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"title":{"type":"string","description":"Change title (1-256 characters)"},"body":{"type":"string","description":"Change description"},"base":{"type":"string","description":"Target branch (default: the default branch)"},"mergePolicy":{"type":"string","enum":["review","auto","draft"],"description":"review (default), auto or draft"}},"required":["title"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm workspace change-set","x-mcp-tool":"create_change_set","x-read-only":false}},"/api/v1/repos/{owner}/{name}/workspaces/{workspace}/abandon":{"post":{"operationId":"abandon_workspace","summary":"Abandon a workspace: closes its open change set and deletes its ref. Idempotent.","tags":["workspaces"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm workspace abandon","x-mcp-tool":"abandon_workspace","x-read-only":false,"x-destructive":true}},"/api/v1/repos/{owner}/{name}/workspaces/{workspace}/dependencies":{"post":{"operationId":"add_dependency","summary":"Pin a workspace to another live workspace of the same repository at its exact current revision. The dependent's change cannot merge until the pinned revision lands (an enqueued dependent waits in the train). Chains are limited to 4 workspaces and cycles are refused with the path.","tags":["dependencies"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"onWorkspace":{"type":"string","description":"Source workspace id (same repository)"},"revision":{"type":"string","description":"The source's current head commit (40 hex); refused 422 REVISION_NOT_CURRENT naming currentRevision otherwise"}},"required":["onWorkspace","revision"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm deps add","x-mcp-tool":"add_dependency","x-read-only":false},"get":{"operationId":"list_dependencies","summary":"A workspace's pins with their state (active, stale, broken or satisfied), reason, depth and the source's current head.","tags":["dependencies"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm deps list","x-mcp-tool":"list_dependencies","x-read-only":true}},"/api/v1/repos/{owner}/{name}/workspaces/{workspace}/dependencies/{dependency}/repin":{"post":{"operationId":"repin_dependency","summary":"Explicitly recover a stale or broken pin: move it to the current revision of the same source or of another live workspace. The platform never repins on its own; the dependent's ref and commits are untouched. Reports the previous pin.","tags":["dependencies"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}},{"name":"dependency","in":"path","required":true,"description":"Dependency id from list_dependencies","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"revision":{"type":"string","description":"The source's current head commit (40 hex)"},"onWorkspace":{"type":"string","description":"Another live source workspace (default: keep the source)"}},"required":["revision"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm deps repin","x-mcp-tool":"repin_dependency","x-read-only":false}},"/api/v1/repos/{owner}/{name}/workspaces/{workspace}/dependencies/{dependency}":{"delete":{"operationId":"detach_dependency","summary":"Remove a pin explicitly; the dependent then publishes without that constraint. The dependent's ref, base and change are untouched.","tags":["dependencies"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}},{"name":"dependency","in":"path","required":true,"description":"Dependency id from list_dependencies","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm deps detach","x-mcp-tool":"detach_dependency","x-read-only":false,"x-destructive":true}},"/api/v1/repos/{owner}/{name}/changes":{"post":{"operationId":"create_change","summary":"Open a change set from a head branch into a base branch.","tags":["changes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"title":{"type":"string","description":"Change title (1-256 characters)"},"base":{"type":"string","description":"Target branch"},"head":{"type":"string","description":"Source branch"},"body":{"type":"string","description":"Change description"},"mergePolicy":{"type":"string","enum":["review","auto","draft"],"description":"review (default), auto or draft"}},"required":["title","base","head"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm change create","x-mcp-tool":"create_change","x-read-only":false},"get":{"operationId":"list_changes","summary":"Change sets of the repository, newest number first.","tags":["changes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"state","in":"query","required":false,"description":"open (default), closed, merged, conflicted or all","schema":{"type":"string","enum":["open","closed","merged","conflicted","all"]}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm change list","x-mcp-tool":"list_changes","x-read-only":true}},"/api/v1/repos/{owner}/{name}/changes/{number}":{"get":{"operationId":"get_change","summary":"One change set with its risk rating, live mergeability, check runs and ordered remaining actions.","tags":["changes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm change get","x-mcp-tool":"get_change","x-read-only":true},"patch":{"operationId":"update_change","summary":"Edit a change set title, body, merge policy or open/closed state. Setting auto merges it when mergeable.","tags":["changes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"title":{"type":"string","description":"New title"},"body":{"type":"string","description":"New description"},"mergePolicy":{"type":"string","enum":["review","auto","draft"],"description":"review, auto or draft"},"state":{"type":"string","enum":["open","closed"],"description":"open or closed"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm change update","x-mcp-tool":"update_change","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/merge":{"post":{"operationId":"merge_change","summary":"Explicitly merge a change set into its base (fast-forward or a two-parent merge commit) under branch rules and required checks.","tags":["changes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"attribution":{"description":"Attribution note for a two-parent merge commit: {agent?, session?, promptHash?, model?}; omitted fields name the merging principal"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm change merge","x-mcp-tool":"merge_change","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/mergeability":{"get":{"operationId":"get_mergeability","summary":"Whether a change set merges cleanly now, including conflicts, required checks and its ordered remaining actions.","tags":["changes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm change mergeability","x-mcp-tool":"get_mergeability","x-read-only":true}},"/api/v1/repos/{owner}/{name}/changes/{number}/checks":{"get":{"operationId":"list_checks","summary":"Check runs of a change set, newest first.","tags":["changes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm change checks","x-mcp-tool":"list_checks","x-read-only":true}},"/api/v1/repos/{owner}/{name}/changes/{number}/enqueue":{"post":{"operationId":"enqueue_change","summary":"Enqueue a change set for the integration train. Enqueue approves the change's current head; the train merges it once the exact composed tree passes required checks. Drafts are refused (409); a full queue answers 429 with Retry-After.","tags":["queue"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"headSha":{"type":"string","description":"Expected head commit (40 hex); refused 409 HEAD_MOVED if the change has moved"},"mergePolicy":{"type":"string","enum":["review","auto","draft"],"description":"Expected merge policy; refused 409 POLICY_CHANGED if it differs"},"attribution":{"description":"Attribution note for a two-parent merge commit: {agent?, session?, promptHash?, model?}; omitted fields name the enqueuing principal"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm queue add","x-mcp-tool":"enqueue_change","x-read-only":false},"delete":{"operationId":"dequeue_change","summary":"Take a change set out of the merge queue (not while it is being published). The change itself stays open.","tags":["queue"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm queue remove","x-mcp-tool":"dequeue_change","x-read-only":false}},"/api/v1/repos/{owner}/{name}/queue":{"get":{"operationId":"get_queue","summary":"Active merge-queue entries in train order per target branch: position, state, approved head, exact composition identity and reason.","tags":["queue"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"base","in":"query","required":false,"description":"Only this target branch","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm queue list","x-mcp-tool":"get_queue","x-read-only":true}},"/api/v1/repos/{owner}/{name}/train":{"get":{"operationId":"get_train","summary":"Integration train status: active entries per target branch with their pins and, for an entry held back by an unresolved pin, a machine-readable waiting reason {code, message, dependencies}.","tags":["queue"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"base","in":"query","required":false,"description":"Only this target branch","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm train status","x-mcp-tool":"get_train","x-read-only":true}},"/api/v1/repos/{owner}/{name}/changes/{number}/reviews":{"get":{"operationId":"get_reviews","summary":"The review packet of a change: required and counted approvals of the current head, reviews with principal, model family and differentFamily, blockers and escalations.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review get","x-mcp-tool":"get_reviews","x-read-only":true},"post":{"operationId":"review_change","summary":"Review the change's current head as a human or agent principal other than the author. An approval may also enable auto-merge when all gates pass; a request-changes, or an approval next to one, escalates to a human.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"verdict":{"type":"string","enum":["approve","request-changes"],"description":"Review verdict"},"headSha":{"type":"string","description":"The reviewed head commit (40 hex); refused 409 HEAD_MOVED if the change has moved"},"body":{"type":"string","description":"Review comment"},"ship":{"type":"boolean","description":"Set merge policy to auto with this approval"}},"required":["verdict"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review submit","x-mcp-tool":"review_change","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/approve":{"post":{"operationId":"approve_change","summary":"Approve the change's current head. Set ship to enable auto-merge when all gates pass. The approval is bound to that exact head.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"headSha":{"type":"string","description":"The reviewed head commit (40 hex); refused 409 HEAD_MOVED if the change has moved"},"body":{"type":"string","description":"Review comment"},"ship":{"type":"boolean","description":"Set merge policy to auto with this approval"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review approve","x-mcp-tool":"approve_change","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/request-changes":{"post":{"operationId":"request_changes","summary":"Request changes on the change's current head. Publication is blocked and escalated to a human until one approves or resolves it.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"headSha":{"type":"string","description":"The reviewed head commit (40 hex); refused 409 HEAD_MOVED if the change has moved"},"body":{"type":"string","description":"Review comment"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review request-changes","x-mcp-tool":"request_changes","x-read-only":false}},"/api/v1/repos/{owner}/{name}/reviews/pending":{"get":{"operationId":"list_pending_reviews","summary":"Live changes still short of approvals or with an open escalation, including current-head checks readiness; optionally filter ready or not-ready changes.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}},{"name":"ready","in":"query","required":false,"description":"Filter readiness: true for ready changes, false for not ready","schema":{"type":"boolean"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review pending","x-mcp-tool":"list_pending_reviews","x-read-only":true}},"/api/v1/repos/{owner}/{name}/changes/{number}/reviewers/assign":{"post":{"operationId":"assign_reviewer","summary":"Pick a reviewer among the agents holding a live write token for the repository (or the given ones), preferring a different model family than the author; reports whether the preference was met.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"candidates":{"type":"array","items":{"type":"string"},"description":"Only consider these agent ids"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review assign","x-mcp-tool":"assign_reviewer","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/review-requests":{"post":{"operationId":"request_review","summary":"Persist a request for a human or agent with current write access to review an open change.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"principal":{"type":"string","description":"Reviewer principal, user:<id> or agent:<id>"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review request","x-mcp-tool":"request_review","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/review-requests/{principal}":{"delete":{"operationId":"withdraw_review_request","summary":"Withdraw a persisted reviewer request from an open change.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}},{"name":"principal","in":"path","required":true,"description":"Reviewer principal to remove","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review withdraw-request","x-mcp-tool":"withdraw_review_request","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/escalations/{id}/resolve":{"post":{"operationId":"resolve_escalation","summary":"Resolve an open escalation as a human with a required note recorded as the reason (agents are refused 403 HUMAN_REQUIRED). Approving the current head as a human independent of the author (not the human who minted an authoring agent) resolves every open escalation too.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}},{"name":"id","in":"path","required":true,"description":"Escalation id from get_reviews","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"note":{"type":"string","description":"Required note recorded with the resolution"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review resolve","x-mcp-tool":"resolve_escalation","x-read-only":false}},"/api/v1/repos/{owner}/{name}/review-policy":{"get":{"operationId":"get_review_policy","summary":"The repository review policy: approving reviews required per change from distinct principals other than the author.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review-policy get","x-mcp-tool":"get_review_policy","x-read-only":true},"put":{"operationId":"set_review_policy","summary":"Set how many approving reviews of the current head (humans or agents, distinct, not the author) a change needs (repo admins only).","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"requiredReviews":{"type":"integer","description":"Required approving reviews (0-10)"},"guideRequired":{"type":"boolean","description":"Require a guide for the current head"},"blockingFindings":{"type":"string","enum":["none","high-confirmed"],"description":"Which open findings block publication"},"dangerAckRequired":{"type":"boolean","description":"Require acknowledgements for scrutinize coverage before approval"},"nudgeAfterMinutes":{"type":"integer","description":"Delay before review reminders (15-10080 minutes); null disables reminders"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review-policy set","x-mcp-tool":"set_review_policy","x-read-only":false}},"/api/v1/repos/{owner}/{name}/review/analytics":{"get":{"operationId":"get_review_analytics","summary":"Finding outcomes grouped by filer model family and its evidence level (known agent families are declared), plus review timing and guide-coverage medians for recent changes.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"days","in":"query","required":false,"description":"Window of change updates to include (1-180 days; default 30)","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review analytics","x-mcp-tool":"get_review_analytics","x-read-only":true}},"/api/v1/repos/{owner}/{name}/changes/{number}/review-guide":{"get":{"operationId":"get_review_guide","summary":"Get deterministic change coverage, the guide and acknowledgements; include hunks only when requested.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}},{"name":"since","in":"query","required":false,"description":"Only include units added since this commit SHA, or use parent for the focused diff","schema":{"type":"string"}},{"name":"unacked","in":"query","required":false,"description":"Only return units not acknowledged by you","schema":{"type":"boolean"}},{"name":"include","in":"query","required":false,"description":"Include inline hunk details","schema":{"type":"string","enum":["hunks"]}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review guide","x-mcp-tool":"get_review_guide","x-read-only":true},"post":{"operationId":"submit_review_guide","summary":"Submit or replace a guide validated against the current coverage map.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"headSha":{"type":"string","description":"Current 40-character head SHA"},"guide":{"description":"Guide chapters, tiers and contracts"}},"required":["headSha","guide"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review submit-guide","x-mcp-tool":"submit_review_guide","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/review/impact":{"get":{"operationId":"get_review_impact","summary":"Show changed-file consumers, test consumers and import evidence for this change.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review impact","x-mcp-tool":"get_review_impact","x-read-only":true}},"/api/v1/repos/{owner}/{name}/changes/{number}/review-acks":{"post":{"operationId":"ack_review_units","summary":"Acknowledge or unacknowledge up to 500 coverage keys or one guide chapter.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"headSha":{"type":"string","description":"Current 40-character head SHA"},"keys":{"description":"Coverage unit keys to acknowledge"},"chapter":{"type":"string","description":"A chapter id to acknowledge"},"unack":{"type":"boolean","description":"Remove acknowledgements instead of adding them"}},"required":["headSha"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm review ack","x-mcp-tool":"ack_review_units","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/findings":{"post":{"operationId":"submit_findings","summary":"Submit up to 50 findings tied to the current head and coverage units.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"headSha":{"type":"string","description":"Current 40-character head SHA"},"findings":{"description":"Findings with path, line, category, severity, confidence and title"}},"required":["headSha","findings"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm finding submit","x-mcp-tool":"submit_findings","x-read-only":false},"get":{"operationId":"list_findings","summary":"List findings for a change, with outdated and blocking state.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}},{"name":"status","in":"query","required":false,"description":"Filter by finding status","schema":{"type":"string","enum":["all","open","resolved","irrelevant","wont-fix"]}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm finding list","x-mcp-tool":"list_findings","x-read-only":true}},"/api/v1/repos/{owner}/{name}/changes/{number}/findings/{id}":{"patch":{"operationId":"update_finding","summary":"Resolve, reopen, dismiss or mark a finding as wont-fix.","tags":["reviews"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}},{"name":"id","in":"path","required":true,"description":"Finding id","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"status":{"type":"string","enum":["open","resolved","irrelevant","wont-fix"],"description":"New finding status"},"note":{"type":"string","description":"Resolution note"}},"required":["status"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm finding update","x-mcp-tool":"update_finding","x-read-only":false}},"/api/v1/repos/{owner}/{name}/tasks":{"get":{"operationId":"list_tasks","summary":"Agent tasks of a repository, newest first: resolve-conflict tasks name the conflicted change, its head and base commits and the conflicting paths (lockfiles marked needsRegeneration); fix-issue tasks name the issue to fix.","tags":["tasks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"status","in":"query","required":false,"description":"Task status (default open)","schema":{"type":"string","enum":["open","claimed","completed","obsolete","all"]}},{"name":"kind","in":"query","required":false,"description":"Only tasks of this kind, e.g. resolve-conflict","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm task list","x-mcp-tool":"list_tasks","x-read-only":true}},"/api/v1/repos/{owner}/{name}/tasks/{task}":{"get":{"operationId":"get_task","summary":"One agent task with its claim lease (holder, generation, expiry), claim workspace and resolution.","tags":["tasks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"task","in":"path","required":true,"description":"Task id from list_tasks","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm task get","x-mcp-tool":"get_task","x-read-only":true}},"/api/v1/repos/{owner}/{name}/tasks/{task}/claim":{"post":{"operationId":"claim_task","summary":"Claim an open task under an expiring lease. Creates (or on a reclaim reuses) a workspace: for resolve-conflict at the conflicting change's head (push the resolution there), for fix-issue at the default branch, linked to the issue. A live claim by another agent is refused 409 CLAIMED; a lapsed lease is taken over under the next generation.","tags":["tasks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"task","in":"path","required":true,"description":"Task id from list_tasks","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"agent":{"type":"string","description":"Agent display name (default: the token agent or your login; an agent token always claims as its agent)"},"ttlSeconds":{"type":"integer","description":"Lease length in seconds (default 600, max 3600)"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm task claim","x-mcp-tool":"claim_task","x-read-only":false}},"/api/v1/repos/{owner}/{name}/tasks/{task}/heartbeat":{"post":{"operationId":"heartbeat_task","summary":"Extend the claim lease of a task you hold. Refused 409 STALE_GENERATION when the claim was taken over.","tags":["tasks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"task","in":"path","required":true,"description":"Task id from list_tasks","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"generation":{"type":"integer","description":"Lease generation returned by claim_task"},"agent":{"type":"string","description":"Agent display name used when claiming"},"ttlSeconds":{"type":"integer","description":"New lease length in seconds (default 600, max 3600)"}},"required":["generation"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm task heartbeat","x-mcp-tool":"heartbeat_task","x-read-only":false}},"/api/v1/repos/{owner}/{name}/tasks/{task}/complete":{"post":{"operationId":"complete_task","summary":"Complete a claimed task. resolve-conflict: the workspace head must descend from the change's head and merge with the base without conflicts; the change moves to the resolution, reopens and follows its merge policy (auto merges, review waits, draft stays draft). fix-issue: the claim workspace must have opened a change (create_change_set); that change closes the issue when it merges.","tags":["tasks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"task","in":"path","required":true,"description":"Task id from list_tasks","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"generation":{"type":"integer","description":"Lease generation returned by claim_task"},"sha":{"type":"string","description":"Expected resolution commit (40 hex); refused 409 if the workspace head differs"},"agent":{"type":"string","description":"Agent display name used when claiming"},"attribution":{"description":"Attribution note for the resolution commit: {agent?, session?, promptHash?, model?}"}},"required":["generation"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm task complete","x-mcp-tool":"complete_task","x-read-only":false}},"/api/v1/repos/{owner}/{name}/workspaces/{workspace}/intent":{"get":{"operationId":"get_intent","summary":"A workspace intent: declared paths, observed paths from pushes and what lies outside the declaration.","tags":["nexus"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm intent get","x-mcp-tool":"get_intent","x-read-only":true},"post":{"operationId":"set_intent","summary":"Replace a workspace intent declaration (advisory; nothing is locked).","tags":["nexus"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspace","in":"path","required":true,"description":"Workspace id (16 hex characters)","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"paths":{"type":"array","items":{"type":"string"},"description":"Declared paths; a trailing / marks a directory prefix"},"prefixes":{"type":"array","items":{"type":"string"},"description":"Directory prefixes (paths with / appended)"},"ttlSeconds":{"type":"integer","description":"Declaration lifetime in seconds (60-2592000)"}},"required":["paths"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm intent set","x-mcp-tool":"set_intent","x-read-only":false}},"/api/v1/repos/{owner}/{name}/forecast":{"get":{"operationId":"forecast","summary":"Advisory forecast: active workspaces whose declared or observed paths intersect the given paths, plus semantic dependency matches (imports, export changes, contract families).","tags":["nexus"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"paths","in":"query","required":true,"description":"Paths to forecast (at most 20; a trailing / marks a prefix)","style":"form","explode":true,"schema":{"type":"array","items":{"type":"string"}}},{"name":"base","in":"query","required":false,"description":"Only workspaces on this base branch","schema":{"type":"string"}},{"name":"exclude","in":"query","required":false,"description":"Workspace id to leave out (usually your own); its own import edges are also matched semantically","schema":{"type":"string"}},{"name":"semantic","in":"query","required":false,"description":"Include the advisory semantic dependency layer on the first page (default true)","schema":{"type":"boolean"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm nexus forecast","x-mcp-tool":"forecast","x-read-only":true}},"/api/v1/repos/{owner}/{name}/workspaces/overlap":{"get":{"operationId":"get_overlap","summary":"Pairs of active workspaces whose pushed changes touch the same paths, plus semantic dependency pairs (advisory, from the Nexus index).","tags":["nexus"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"base","in":"query","required":false,"description":"Base branch (default: the default branch)","schema":{"type":"string"}},{"name":"semantic","in":"query","required":false,"description":"Include advisory semantic dependency pairs on the first page (default true)","schema":{"type":"boolean"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm nexus overlap","x-mcp-tool":"get_overlap","x-read-only":true}},"/api/v1/repos/{owner}/{name}/candidates":{"get":{"operationId":"list_candidates","summary":"Compare 1-8 workspaces against a base: per-candidate summaries, pairwise diffs, overlap and a deterministic ranking.","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"workspaces","in":"query","required":true,"description":"Workspace ids (1-8)","style":"form","explode":false,"schema":{"type":"array","items":{"type":"string"}}},{"name":"base","in":"query","required":false,"description":"Base branch (default: the default branch)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm candidates get","x-mcp-tool":"list_candidates","x-read-only":true}},"/api/v1/repos/{owner}/{name}/candidates/compose":{"post":{"operationId":"compose_candidates","summary":"Compose selected workspace pieces onto the base into a new workspace and change set (refused on textual conflicts).","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"workspaces":{"description":"Workspace ids or {workspace, paths?} objects (2-8), in fold order"},"paths":{"description":"Optional {<workspace id>: [paths]} selection"},"base":{"type":"string","description":"Base branch (default: the default branch)"},"title":{"type":"string","description":"Title of the composed change set"},"mergePolicy":{"type":"string","enum":["review","auto","draft"],"description":"review (default), auto or draft"},"agent":{"type":"string","description":"Agent display name for the composed workspace"}},"required":["workspaces"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm candidates compose","x-mcp-tool":"compose_candidates","x-read-only":false}},"/api/v1/repos/{owner}/{name}/compositions":{"get":{"operationId":"list_compositions","summary":"Compositions of the repository, newest first.","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm composition list","x-mcp-tool":"list_compositions","x-read-only":true}},"/api/v1/repos/{owner}/{name}/compositions/{id}":{"get":{"operationId":"get_composition","summary":"One composition: sources, composed tree and commit, its workspace and change set, and the checks answer.","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Composition id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm composition get","x-mcp-tool":"get_composition","x-read-only":true}},"/api/v1/repos/{owner}/{name}/arenas":{"post":{"operationId":"create_arena","summary":"Create 2-8 sibling candidate workspaces from one brief at the base head. Nothing is spawned or selected automatically.","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"brief":{"type":"string","description":"Shared brief (1-500 characters)"},"candidates":{"type":"integer","description":"Number of candidate workspaces (2-8)"},"base":{"type":"string","description":"Base branch (default: the default branch)"},"agent":{"type":"string","description":"Agent display name for the workspaces"}},"required":["brief","candidates"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm arena create","x-mcp-tool":"create_arena","x-read-only":false},"get":{"operationId":"list_arenas","summary":"Arenas of the repository, newest first.","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm arena list","x-mcp-tool":"list_arenas","x-read-only":true}},"/api/v1/repos/{owner}/{name}/arenas/{id}":{"get":{"operationId":"get_arena","summary":"One arena with its candidate workspaces and recorded selection.","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Arena id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm arena get","x-mcp-tool":"get_arena","x-read-only":true}},"/api/v1/repos/{owner}/{name}/arenas/{id}/candidates":{"get":{"operationId":"rank_arena","summary":"Ranked candidates of an arena (same factors as list_candidates) plus the separate duplication report.","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Arena id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm arena rank","x-mcp-tool":"rank_arena","x-read-only":true}},"/api/v1/repos/{owner}/{name}/arenas/{id}/select":{"post":{"operationId":"select_arena_winner","summary":"Record the chosen arena candidate. Merges, closes and abandons nothing; the winner merges through its own change set.","tags":["candidates"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Arena id","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"workspace":{"type":"string","description":"Winning workspace id"}},"required":["workspace"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm arena select","x-mcp-tool":"select_arena_winner","x-read-only":false}},"/api/v1/orgs":{"post":{"operationId":"create_org","summary":"Create an organization; the caller becomes its owner.","tags":["orgs"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"login":{"type":"string","description":"Organization login"},"name":{"type":"string","description":"Display name"}},"required":["login"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm org create","x-mcp-tool":"create_org","x-read-only":false}},"/api/v1/orgs/{org}":{"get":{"operationId":"get_org","summary":"An organization and your role in it.","tags":["orgs"],"parameters":[{"name":"org","in":"path","required":true,"description":"Organization login","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm org get","x-mcp-tool":"get_org","x-read-only":true}},"/api/v1/user/orgs":{"get":{"operationId":"list_my_orgs","summary":"Organizations the authenticated user belongs to, with roles.","tags":["orgs"],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm org list","x-mcp-tool":"list_my_orgs","x-read-only":true}},"/api/v1/orgs/{org}/members":{"get":{"operationId":"list_org_members","summary":"Members of an organization (members only).","tags":["orgs"],"parameters":[{"name":"org","in":"path","required":true,"description":"Organization login","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-200)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm org members","x-mcp-tool":"list_org_members","x-read-only":true}},"/api/v1/orgs/{org}/members/{login}":{"put":{"operationId":"set_org_member","summary":"Add a member or change a role (org owners only). The last owner cannot be demoted.","tags":["orgs"],"parameters":[{"name":"org","in":"path","required":true,"description":"Organization login","schema":{"type":"string"}},{"name":"login","in":"path","required":true,"description":"User login","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"role":{"type":"string","enum":["owner","maintainer","member"],"description":"owner, maintainer or member"}},"required":["role"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm org member-set","x-mcp-tool":"set_org_member","x-read-only":false},"delete":{"operationId":"remove_org_member","summary":"Remove a member (org owners only); also deletes the user's grants on the org's repositories.","tags":["orgs"],"parameters":[{"name":"org","in":"path","required":true,"description":"Organization login","schema":{"type":"string"}},{"name":"login","in":"path","required":true,"description":"User login","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm org member-remove","x-mcp-tool":"remove_org_member","x-read-only":false,"x-destructive":true}},"/api/v1/orgs/{org}/repos":{"get":{"operationId":"list_org_repos","summary":"Repositories of an organization visible to you.","tags":["orgs"],"parameters":[{"name":"org","in":"path","required":true,"description":"Organization login","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm org repos","x-mcp-tool":"list_org_repos","x-read-only":true},"post":{"operationId":"create_org_repo","summary":"Create a repository owned by an organization (owners and maintainers).","tags":["orgs"],"parameters":[{"name":"org","in":"path","required":true,"description":"Organization login","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Repository name"},"description":{"type":"string","description":"Short description"},"visibility":{"type":"string","enum":["public","private"],"description":"public or private (default private)"},"defaultBranch":{"type":"string","description":"Default branch name (default main)"}},"required":["name"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm org repo-create","x-mcp-tool":"create_org_repo","x-read-only":false}},"/api/v1/repos/{owner}/{name}/grants":{"get":{"operationId":"list_grants","summary":"Explicit repository grants (repo admins only).","tags":["orgs"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm grant list","x-mcp-tool":"list_grants","x-read-only":true}},"/api/v1/repos/{owner}/{name}/grants/{login}":{"put":{"operationId":"set_grant","summary":"Grant a user read, write or admin on a repository (repo admins only).","tags":["orgs"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"login","in":"path","required":true,"description":"User login","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"role":{"type":"string","enum":["read","write","admin"],"description":"read, write or admin"}},"required":["role"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm grant set","x-mcp-tool":"set_grant","x-read-only":false},"delete":{"operationId":"revoke_grant","summary":"Revoke a user's explicit grant on a repository (repo admins only).","tags":["orgs"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"login","in":"path","required":true,"description":"User login","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm grant revoke","x-mcp-tool":"revoke_grant","x-read-only":false,"x-destructive":true}},"/api/v1/agents":{"post":{"operationId":"create_agent","summary":"Create an agent principal owned by you or by an organization you own.","tags":["agents"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Agent name (lowercase, unique per owner)"},"owner":{"type":"string","description":"Your login or an org login (default: you)"},"description":{"type":"string","description":"Description (at most 500 characters)"},"modelFamily":{"type":"string","description":"Model family of the agent (e.g. claude, gpt); reviewer assignment prefers a different family than the author"}},"required":["name"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm agent create","x-mcp-tool":"create_agent","x-read-only":false},"get":{"operationId":"list_agents","summary":"Agents of an account you manage, sorted by name (revoked included).","tags":["agents"],"parameters":[{"name":"owner","in":"query","required":false,"description":"Account login (default: you)","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-200)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm agent list","x-mcp-tool":"list_agents","x-read-only":true}},"/api/v1/agents/{id}":{"get":{"operationId":"get_agent","summary":"One agent you manage (status, owner, creator).","tags":["agents"],"parameters":[{"name":"id","in":"path","required":true,"description":"Agent id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm agent get","x-mcp-tool":"get_agent","x-read-only":true},"delete":{"operationId":"revoke_agent","summary":"Revoke an agent; all of its tokens stop working immediately.","tags":["agents"],"parameters":[{"name":"id","in":"path","required":true,"description":"Agent id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm agent revoke","x-mcp-tool":"revoke_agent","x-read-only":false,"x-destructive":true}},"/api/v1/agents/{id}/tokens":{"post":{"operationId":"create_agent_token","summary":"Mint an expiring agent token for one repository (read, or write with ref patterns). The token is shown once.","tags":["agents"],"parameters":[{"name":"id","in":"path","required":true,"description":"Agent id","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"repo":{"type":"string","description":"Repository as owner/name"},"role":{"type":"string","enum":["read","write"],"description":"read or write"},"refs":{"type":"array","items":{"type":"string"},"description":"Ref patterns a write token may update (1-16, e.g. refs/heads/agents/*)"},"expiresIn":{"type":"integer","description":"Lifetime in seconds (60-2592000, default 3600)"},"name":{"type":"string","description":"Token label"}},"required":["repo","role"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm agent token-create","x-mcp-tool":"create_agent_token","x-read-only":false},"get":{"operationId":"list_agent_tokens","summary":"Token metadata of an agent (prefix only, never the token).","tags":["agents"],"parameters":[{"name":"id","in":"path","required":true,"description":"Agent id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm agent tokens","x-mcp-tool":"list_agent_tokens","x-read-only":true}},"/api/v1/agents/{id}/tokens/{tokenId}":{"delete":{"operationId":"revoke_agent_token","summary":"Revoke one agent token.","tags":["agents"],"parameters":[{"name":"id","in":"path","required":true,"description":"Agent id","schema":{"type":"string"}},{"name":"tokenId","in":"path","required":true,"description":"Token id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm agent token-revoke","x-mcp-tool":"revoke_agent_token","x-read-only":false,"x-destructive":true}},"/api/v1/repos/{owner}/{name}/commits/{sha}/attribution":{"post":{"operationId":"set_attribution","summary":"Attach the attribution note {agent, session, promptHash, model?, actor, at} to a commit on refs/notes/kvarm-attribution (replaces an earlier note).","tags":["attribution"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"sha","in":"path","required":true,"description":"Full 40-character commit sha","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"agent":{"type":"string","description":"Agent identity, e.g. claude-code-1"},"session":{"type":"string","description":"Agent session id"},"promptHash":{"type":"string","description":"Hash of the prompt that produced the commit"},"model":{"type":"string","description":"Model name"},"evidence":{"description":"Signed execution evidence {keyId, runId, signature} from a trusted execution service; verified on write"}},"required":["agent","session","promptHash"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm attribution set","x-mcp-tool":"set_attribution","x-read-only":false},"get":{"operationId":"get_attribution","summary":"A commit's attribution note (agent, session, promptHash, model, actor, at) with its evidence level (declared, authenticated or verified); not found when it has none.","tags":["attribution"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"sha","in":"path","required":true,"description":"Full 40-character commit sha","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm attribution get","x-mcp-tool":"get_attribution","x-read-only":true}},"/api/v1/repos/{owner}/{name}/decisions":{"post":{"operationId":"record_decision","summary":"Record which candidate was chosen for a task and/or paths, the rejected candidates and why, for later agents to read with get_context.","tags":["attribution"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"task":{"type":"string","description":"Task id the decision belongs to (task and/or paths)"},"paths":{"type":"array","items":{"type":"string"},"description":"Repository paths the decision covers (at most 100)"},"chosen":{"type":"string","description":"Chosen candidate, workspace or change id"},"rejected":{"description":"Rejected candidates: ids or {id, reason} objects (at most 50)"},"reason":{"type":"string","description":"Why the chosen candidate won"}},"required":["chosen","rejected","reason"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm decision record","x-mcp-tool":"record_decision","x-read-only":false}},"/api/v1/repos/{owner}/{name}/context":{"get":{"operationId":"get_context","summary":"Prior decisions for a task and/or paths, newest first: chosen and rejected candidates with their reasons. Bounded pages with truncated/nextCursor.","tags":["attribution"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"task","in":"query","required":false,"description":"Task id","schema":{"type":"string"}},{"name":"path","in":"query","required":false,"description":"Repository paths (at most 20)","style":"form","explode":true,"schema":{"type":"array","items":{"type":"string"}}},{"name":"limit","in":"query","required":false,"description":"Page size (1-50)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm decision context","x-mcp-tool":"get_context","x-read-only":true}},"/api/v1/repos/{owner}/{name}/issues":{"post":{"operationId":"create_issue","summary":"File an issue, e.g. a bug found outside the current task. With a fingerprint, a repeat report while an issue with that fingerprint is open counts one more occurrence on it (200, created false) instead of filing a duplicate (201).","tags":["issues"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"title":{"type":"string","description":"Title (1-256 characters)"},"body":{"type":"string","description":"Description: what happens, how to reproduce it"},"paths":{"type":"array","items":{"type":"string"},"description":"Repository paths the issue is about (at most 100)"},"fingerprint":{"type":"string","description":"Stable identity of the problem (e.g. a failing test id) used to deduplicate reports"},"evidence":{"description":"Evidence {sha?, check?, runId?, workspace?, url?}"}},"required":["title"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm issue create","x-mcp-tool":"create_issue","x-read-only":false},"get":{"operationId":"list_issues","summary":"Issues of the repository, newest first, filtered by state (default open) and by source (human, agent, ci, flake, guard).","tags":["issues"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"state","in":"query","required":false,"description":"Issue state (default open)","schema":{"type":"string","enum":["open","closed","all"]}},{"name":"source","in":"query","required":false,"description":"Who filed it","schema":{"type":"string","enum":["human","agent","ci","flake","guard"]}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm issue list","x-mcp-tool":"list_issues","x-read-only":true}},"/api/v1/repos/{owner}/{name}/issues/{number}":{"get":{"operationId":"get_issue","summary":"One issue with its occurrences, evidence, how it was closed, its links to changes and workspaces, and its newest comments.","tags":["issues"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Issue number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm issue get","x-mcp-tool":"get_issue","x-read-only":true},"patch":{"operationId":"update_issue","summary":"Edit an issue, close it (closedReason completed, not_planned or duplicate) or reopen it.","tags":["issues"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Issue number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"title":{"type":"string","description":"New title"},"body":{"type":"string","description":"New description"},"paths":{"type":"array","items":{"type":"string"},"description":"Repository paths the issue is about (replaces the list)"},"state":{"type":"string","enum":["open","closed"],"description":"open or closed"},"closedReason":{"type":"string","enum":["completed","not_planned","duplicate"],"description":"Why it is closed (with state closed)"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm issue update","x-mcp-tool":"update_issue","x-read-only":false}},"/api/v1/repos/{owner}/{name}/issues/{number}/dispatch":{"post":{"operationId":"dispatch_issue","summary":"Hand an open issue to agents as a fix-issue task (one live task per issue; 201 created, 200 the live one). An agent claims it with claim_task, gets a workspace at the default branch that declares the issue's paths as its intent, opens a change from it (create_change_set) and completes the task; the change closes the issue when it merges.","tags":["issues"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Issue number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm issue dispatch","x-mcp-tool":"dispatch_issue","x-read-only":false}},"/api/v1/repos/{owner}/{name}/issues/{number}/comments":{"post":{"operationId":"comment_issue","summary":"Comment on an issue (people and agents alike, closed issues included); get_issue returns the newest 50 comments.","tags":["issues"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Issue number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"body":{"type":"string","description":"The comment (Markdown)"}},"required":["body"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm issue comment","x-mcp-tool":"comment_issue","x-read-only":false}},"/api/v1/repos/{owner}/{name}/changes/{number}/issues":{"get":{"operationId":"list_change_issues","summary":"Issues linked to a change: closing keywords in its title or body (confirmed), an issue number in its branch name (proposed), its workspace's issue, and manual links; willClose tells which close when it merges into the default branch.","tags":["issues"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm issue linked","x-mcp-tool":"list_change_issues","x-read-only":true},"post":{"operationId":"link_issue","summary":"Confirm or reject a link between a change and an issue, e.g. accept a proposed link from the branch name. A confirmed closes link closes the issue when the change merges into the default branch; a manual decision is never recomputed away.","tags":["issues"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"number","in":"path","required":true,"description":"Change set number within the repository","schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"issue":{"type":"integer","description":"Issue number"},"kind":{"type":"string","enum":["closes","refs"],"description":"closes (default) or refs"},"state":{"type":"string","enum":["confirmed","rejected"],"description":"confirmed (default) or rejected"}},"required":["issue"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm issue link","x-mcp-tool":"link_issue","x-read-only":false}},"/api/v1/repos/{owner}/{name}/audit":{"get":{"operationId":"get_audit","summary":"Audit export (repo admins): one record per commit with agent, session, promptHash, model, evidence level, token prefix, pushes and merges, in first-recorded order. Bounded pages with nextCursor.","tags":["provenance"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"since","in":"query","required":false,"description":"Earliest first-seen time, ISO 8601 (inclusive)","schema":{"type":"string"}},{"name":"until","in":"query","required":false,"description":"Latest first-seen time, ISO 8601 (exclusive)","schema":{"type":"string"}},{"name":"format","in":"query","required":false,"description":"json (default) or ndjson: one record per line, then a {page} line","schema":{"type":"string","enum":["json","ndjson"]}},{"name":"limit","in":"query","required":false,"description":"Page size (1-200)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm audit export","x-mcp-tool":"get_audit","x-read-only":true}},"/api/v1/repos/{owner}/{name}/provenance-keys":{"get":{"operationId":"list_provenance_keys","summary":"Trusted execution-service public keys for verified attribution: the repository keys and the instance keys (repo admins).","tags":["provenance"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm provenance-key list","x-mcp-tool":"list_provenance_keys","x-read-only":true},"post":{"operationId":"add_provenance_key","summary":"Trust an execution service: add its raw Ed25519 public key (base64url); its id is the key fingerprint (repo admins).","tags":["provenance"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Label of the execution service"},"publicKey":{"type":"string","description":"Raw 32-byte Ed25519 public key, base64url"}},"required":["name","publicKey"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm provenance-key add","x-mcp-tool":"add_provenance_key","x-read-only":false}},"/api/v1/repos/{owner}/{name}/provenance-keys/{id}":{"delete":{"operationId":"revoke_provenance_key","summary":"Stop trusting a provenance key for new attribution writes; levels already recorded stay as they were (repo admins).","tags":["provenance"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Key id (fingerprint) from list_provenance_keys","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm provenance-key revoke","x-mcp-tool":"revoke_provenance_key","x-read-only":false,"x-destructive":true}},"/api/v1/repos/{owner}/{name}/branch-rules":{"get":{"operationId":"list_branch_rules","summary":"Branch protection rules of the repository.","tags":["branch-rules"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm branch-rule list","x-mcp-tool":"list_branch_rules","x-read-only":true},"post":{"operationId":"create_branch_rule","summary":"Protect matching refs from direct pushes and set required checks/approvals and guard completeness (repo admins only).","tags":["branch-rules"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"pattern":{"type":"string","description":"Branch name or ref pattern (main, release/*, refs/tags/*)"},"requiredChecks":{"type":"array","items":{"type":"string"},"description":"Required check names"},"requiredApprovals":{"type":"integer","description":"Required distinct human approvals (0-10)"},"guardCompleteness":{"type":"string","enum":["advisory","required"],"description":"advisory (default): an incomplete kvarm/guard scan is reported only; required: it blocks publication (GUARD_INCOMPLETE)"},"agentApprovals":{"type":"string","enum":["never","low-risk"],"description":"never (default): agent approvals do not satisfy protected-branch approval requirements; low-risk: different-family agents may approve heads without scrutinize files"}},"required":["pattern"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm branch-rule create","x-mcp-tool":"create_branch_rule","x-read-only":false}},"/api/v1/repos/{owner}/{name}/branch-rules/{id}":{"get":{"operationId":"get_branch_rule","summary":"One branch rule with its required checks and approvals.","tags":["branch-rules"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Rule id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm branch-rule get","x-mcp-tool":"get_branch_rule","x-read-only":true},"patch":{"operationId":"update_branch_rule","summary":"Change a branch rule's required checks, approvals or guard completeness (the pattern is immutable).","tags":["branch-rules"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Rule id","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"requiredChecks":{"type":"array","items":{"type":"string"},"description":"Required check names"},"requiredApprovals":{"type":"integer","description":"Required distinct human approvals (0-10)"},"guardCompleteness":{"type":"string","enum":["advisory","required"],"description":"advisory (default): an incomplete kvarm/guard scan is reported only; required: it blocks publication (GUARD_INCOMPLETE)"},"agentApprovals":{"type":"string","enum":["never","low-risk"],"description":"never (default): agent approvals do not satisfy protected-branch approval requirements; low-risk: different-family agents may approve heads without scrutinize files"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm branch-rule update","x-mcp-tool":"update_branch_rule","x-read-only":false},"delete":{"operationId":"delete_branch_rule","summary":"Delete a branch rule (repo admins only).","tags":["branch-rules"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Rule id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm branch-rule delete","x-mcp-tool":"delete_branch_rule","x-read-only":false,"x-destructive":true}},"/api/v1/repos/{owner}/{name}/branch-policy":{"get":{"operationId":"get_branch_policy","summary":"The effective policy for one ref: protected, direct push, required checks, approvals and guard completeness.","tags":["branch-rules"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"ref","in":"query","required":true,"description":"Branch name or full ref","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm branch-rule policy","x-mcp-tool":"get_branch_policy","x-read-only":true}},"/api/v1/repos/{owner}/{name}/environments":{"get":{"operationId":"list_environments","summary":"List reusable Linux build environments for a repository.","tags":["environments"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm environment list","x-mcp-tool":"list_environments","x-read-only":true},"post":{"operationId":"create_environment","summary":"Create a Linux build environment; requires repository admin and queues its initial build.","tags":["environments"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"name":{"type":"string","description":"Environment name"},"os":{"type":"string","description":"Only linux is currently available"},"baseRef":{"type":"string","description":"Base branch (defaults to the repository default)"},"instance":{"type":"string","description":"Container instance type"},"setupScript":{"type":"string","description":"Setup script"},"validateScript":{"type":"string","description":"Validation script"},"envVars":{"description":"Non-secret build environment variables"}},"required":["name"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm environment create","x-mcp-tool":"create_environment","x-read-only":false}},"/api/v1/repos/{owner}/{name}/environments/{environment}/rebuild":{"post":{"operationId":"rebuild_environment","summary":"Request a new environment build without changing its configuration (repository admin only).","tags":["environments"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"environment","in":"path","required":true,"description":"Environment id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm environment rebuild","x-mcp-tool":"rebuild_environment","x-read-only":false}},"/api/v1/repos/{owner}/{name}/sandboxes":{"post":{"operationId":"start_sandbox","summary":"Resume the caller principal’s running or sleeping sandbox for this environment, or start one. Set fresh=true to force a separate sandbox.","tags":["sandboxes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"environment":{"type":"string","description":"Environment id"},"workspace":{"type":"string","description":"Workspace id to reuse or resume"},"task":{"type":"string","description":"Workspace task"},"ttlHours":{"type":"integer","description":"Run-window duration (1-168 hours)"},"fresh":{"type":"boolean","description":"Always create a new sandbox"}},"required":["environment"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm sandbox start","x-mcp-tool":"start_sandbox","x-read-only":false},"get":{"operationId":"list_sandboxes","summary":"List repository sandboxes, including sleeping snapshots.","tags":["sandboxes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm sandbox list","x-mcp-tool":"list_sandboxes","x-read-only":true}},"/api/v1/sandboxes/mine":{"get":{"operationId":"list_my_sandboxes","summary":"List human-owned sandboxes across the owner’s agents; agent credentials see only their own repository and agent.","tags":["sandboxes"],"parameters":[{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm sandbox mine","x-mcp-tool":"list_my_sandboxes","x-read-only":true}},"/api/v1/repos/{owner}/{name}/sandboxes/{sandbox}/exec":{"post":{"operationId":"exec_sandbox","summary":"Run an audited command in the caller-owned sandbox; deny rules precede single-use human approval.","tags":["sandboxes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"sandbox","in":"path","required":true,"description":"Sandbox id","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"command":{"type":"string","description":"Command string"},"cwd":{"type":"string","description":"Working directory within the workspace"},"timeoutSeconds":{"type":"integer","description":"Timeout from 1 to 600 seconds"},"approvalId":{"type":"string","description":"Previously approved exact-command approval id"}},"required":["command"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm sandbox exec","x-mcp-tool":"exec_sandbox","x-read-only":false}},"/api/v1/repos/{owner}/{name}/sandboxes/{sandbox}/stop":{"post":{"operationId":"stop_sandbox","summary":"Sleep the caller-owned sandbox by default; discard=true destroys its resumable snapshot.","tags":["sandboxes"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"sandbox","in":"path","required":true,"description":"Sandbox id","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"discard":{"type":"boolean","description":"Discard rather than sleep"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm sandbox stop","x-mcp-tool":"stop_sandbox","x-read-only":false}},"/api/v1/repos/{owner}/{name}/ci/jobs":{"get":{"operationId":"list_ci_jobs","summary":"The repository CI job queue, newest first: queued, running and finished runner jobs with claims, leases and the change they belong to.","tags":["ci"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm ci jobs","x-mcp-tool":"list_ci_jobs","x-read-only":true}},"/api/v1/repos/{owner}/{name}/ci/flakes":{"get":{"operationId":"list_ci_flakes","summary":"Flaky-check registry: required runner checks that failed once and passed on the automatic retry, plus the checks currently quarantined for the repository.","tags":["ci"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"description":"Page size (1-100)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm ci flakes","x-mcp-tool":"list_ci_flakes","x-read-only":true}},"/api/v1/repos/{owner}/{name}/ci/flakes/{check}/quarantine":{"post":{"operationId":"quarantine_ci_check","summary":"Quarantine a check name (repo admins only). The check still runs but its runs never satisfy or block a required-checks gate, and its failures never retry.","tags":["ci"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"check","in":"path","required":true,"description":"Check name to quarantine","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm ci quarantine","x-mcp-tool":"quarantine_ci_check","x-read-only":false}},"/api/v1/repos/{owner}/{name}/ci/flakes/{check}/restore":{"post":{"operationId":"restore_ci_check","summary":"Restore a quarantined check name to normal handling (repo admins only); its recorded runs count again.","tags":["ci"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"check","in":"path","required":true,"description":"Check name to restore","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm ci restore","x-mcp-tool":"restore_ci_check","x-read-only":false}},"/api/v1/repos/{owner}/{name}/ci/hosted":{"get":{"operationId":"get_ci_hosted","summary":"Hosted CI status: the enabled flag, claimable and running jobs, the live drain state and the last drain report of the platform container runner.","tags":["ci"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm ci hosted","x-mcp-tool":"get_ci_hosted","x-read-only":true}},"/api/v1/repos/{owner}/{name}/ci/hosted/enable":{"post":{"operationId":"enable_ci_hosted","summary":"Enable hosted CI execution for the repository (repo admins only): the platform container runner drains queued jobs, starting with any backlog; the user-owned runner keeps racing on the same queue.","tags":["ci"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm ci enable","x-mcp-tool":"enable_ci_hosted","x-read-only":false}},"/api/v1/repos/{owner}/{name}/ci/hosted/disable":{"post":{"operationId":"disable_ci_hosted","summary":"Disable hosted CI execution for the repository (repo admins only). Queued jobs stay claimable by user-owned runners.","tags":["ci"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm ci disable","x-mcp-tool":"disable_ci_hosted","x-read-only":false}},"/api/v1/repos/{owner}/{name}/webhooks":{"get":{"operationId":"list_webhooks","summary":"Outbound webhooks of the repository with their subscribed events, state and failure count (never the secret).","tags":["webhooks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm webhook list","x-mcp-tool":"list_webhooks","x-read-only":true},"post":{"operationId":"create_webhook","summary":"Create an outbound webhook (https only, no private or internal hosts). The signing secret is in this reply only; deliveries are signed CloudEvents.","tags":["webhooks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"url":{"type":"string","description":"https URL that receives the events"},"events":{"type":"array","items":{"type":"string"},"description":"Event types to deliver, e.g. kvarm.change.merged, kvarm.check_run.completed (list_webhooks returns the accepted set as eventTypes)"}},"required":["url","events"]}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm webhook create","x-mcp-tool":"create_webhook","x-read-only":false}},"/api/v1/repos/{owner}/{name}/webhooks/{id}":{"get":{"operationId":"get_webhook","summary":"One webhook: URL, events, active, consecutive failures, last delivery and status.","tags":["webhooks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm webhook get","x-mcp-tool":"get_webhook","x-read-only":true},"patch":{"operationId":"update_webhook","summary":"Change a webhook's URL or events, or disable/re-enable it (re-enabling clears the failure count).","tags":["webhooks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook id","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"url":{"type":"string","description":"New https URL"},"events":{"type":"array","items":{"type":"string"},"description":"New list of event types"},"active":{"type":"boolean","description":"false disables the webhook; true re-enables it"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm webhook update","x-mcp-tool":"update_webhook","x-read-only":false},"delete":{"operationId":"delete_webhook","summary":"Delete a webhook; its pending deliveries are cancelled.","tags":["webhooks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm webhook delete","x-mcp-tool":"delete_webhook","x-read-only":false,"x-destructive":true}},"/api/v1/repos/{owner}/{name}/webhooks/{id}/rotate-secret":{"post":{"operationId":"rotate_webhook_secret","summary":"Replace the signing secret of a webhook; the new secret is in this reply only.","tags":["webhooks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm webhook rotate-secret","x-mcp-tool":"rotate_webhook_secret","x-read-only":false}},"/api/v1/repos/{owner}/{name}/webhooks/{id}/ping":{"post":{"operationId":"ping_webhook","summary":"Send a signed kvarm.webhook.ping to one webhook through the delivery queue; returns the pending delivery.","tags":["webhooks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook id","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm webhook ping","x-mcp-tool":"ping_webhook","x-read-only":false}},"/api/v1/repos/{owner}/{name}/webhooks/{id}/deliveries":{"get":{"operationId":"list_webhook_deliveries","summary":"Delivery log of a webhook, newest first: state, attempts, response status, latency, error and a truncated response.","tags":["webhooks"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook id","schema":{"type":"string"}},{"name":"state","in":"query","required":false,"description":"Only deliveries in this state","schema":{"type":"string","enum":["pending","delivered","failed","cancelled"]}},{"name":"limit","in":"query","required":false,"description":"Page size (1-50)","schema":{"type":"integer"}},{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from the previous page (nextCursor)","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm webhook deliveries","x-mcp-tool":"list_webhook_deliveries","x-read-only":true}},"/api/v1/repos/{owner}/{name}/reverts":{"post":{"operationId":"create_revert","summary":"Revert a commit or a merged change set: builds the revert commit (git revert; merges relative to their first parent) on a kvarm-revert/ branch and opens a change set of kind revert (draft by default) that runs guard, CI and the merge queue like any change. 404 unknown commit; 409 REVERT_CONFLICT with the conflicting paths, nothing written.","tags":["reverts"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"sha":{"type":"string","description":"Commit to revert (40 hex); or pass changeNumber"},"changeNumber":{"type":"integer","description":"Merged change set to revert, relative to the target it landed on; or pass sha"},"reason":{"type":"string","description":"Why: added to the revert commit message and the change body"},"base":{"type":"string","description":"Branch the revert applies to (default: the reverted change set base, else the default branch)"},"title":{"type":"string","description":"Change title (default: Revert \"<subject>\")"},"mergePolicy":{"type":"string","enum":["review","auto","draft"],"description":"draft (default), review or auto"}}}}}},"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm revert create","x-mcp-tool":"create_revert","x-read-only":false}},"/api/v1/repos/{owner}/{name}/incidents/webhook":{"get":{"operationId":"get_incident_webhook","summary":"Incident webhook status for the repository (repo admins): whether a secret exists, its generation and fingerprint, and the signature headers. The secret itself is never shown again.","tags":["reverts"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm incident webhook","x-mcp-tool":"get_incident_webhook","x-read-only":true},"delete":{"operationId":"delete_incident_webhook","summary":"Remove the incident webhook secret (repo admins); every later delivery is refused with 401.","tags":["reverts"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm incident delete","x-mcp-tool":"delete_incident_webhook","x-read-only":false,"x-destructive":true}},"/api/v1/repos/{owner}/{name}/incidents/webhook/rotate":{"post":{"operationId":"rotate_incident_secret","summary":"Create or rotate the incident webhook secret (repo admins). The reply shows the new secret once; the previous secret stops verifying immediately. Deliveries sign \"<x-kvarm-timestamp>.<raw body>\" with HMAC-SHA256.","tags":["reverts"],"parameters":[{"name":"owner","in":"path","required":true,"description":"Repository owner (user or organization login)","schema":{"type":"string"}},{"name":"name","in":"path","required":true,"description":"Repository name","schema":{"type":"string"}}],"responses":{"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"}}}},"2XX":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}}},"x-kvarm-cli":"kvarm incident rotate","x-mcp-tool":"rotate_incident_secret","x-read-only":false}}}}