List repositories in the project
const url = 'https://zkao.io/api/v1/projects/example/repositories';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://zkao.io/api/v1/projects/example/repositories \ --header 'Authorization: Bearer <token>'Requires scope: read. Limited to the token’s repo allowlist when set.
Authorizations
Section titled “Authorizations”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”Responses
Section titled “ Responses ”OK
object
object
URL segment of the repository inside its project (/orgs/<org>/projects/<project>/repos/<slug>). Unique per project.
ACTIVE | MARKED_FOR_DELETION
Whether a scan can start on this repository. A newly added repository is analyzing until a one-time pass over it finishes; launching a scan meanwhile fails with repository_initializing. Poll this endpoint rather than retrying the launch blind.
Example
{ "repositories": [ { "readiness": "ready" } ]}Missing, malformed, expired, or revoked token
object
object
Budget_below_minimum only: the least the launch could have reserved, in credits. A diff scan’s first scan of a repository also builds its overview, so its minimum is higher.
Example
{ "error": { "code": "unauthorized" }}The token lacks the required scope
object
object
Budget_below_minimum only: the least the launch could have reserved, in credits. A diff scan’s first scan of a repository also builds its overview, so its minimum is higher.
Example
{ "error": { "code": "unauthorized" }}Resource not in this token’s project or repo allowlist
object
object
Budget_below_minimum only: the least the launch could have reserved, in credits. A diff scan’s first scan of a repository also builds its overview, so its minimum is higher.
Example
{ "error": { "code": "unauthorized" }}