Skip to main content
Every sourcegraph.api.* operation is listed below with parameter shapes and return types from the plugin Zod schemas.
New to Corsair? See API access, authentication, and error handling.

Repository

compareCommits

repository.compareCommits Compare two commits and list file diffs Risk: read
Input Output

getCommitDetails

repository.getCommitDetails Get details for a commit, branch, or tag Risk: read
Input Output

getFileContents

repository.getFileContents Fetch file contents on the default branch (HEAD) Risk: read
Input Output

list

repository.list List repositories on the Sourcegraph instance Risk: read
Input Output

listFiles

repository.listFiles List files and directories in a repository path Risk: read
Input Output

listLanguages

repository.listLanguages List languages used in a repository Risk: read
Input Output

Site

checkSettingsEditPermission

site.checkSettingsEditPermission Check whether the viewer can edit site settings through the GraphQL API Risk: read
Input: empty object Output

User

getCurrent

user.getCurrent Retrieve the currently authenticated Sourcegraph user Risk: read
Input: empty object Output