v1

latestOpenAPI 3.0.02026-07-249055687.1 KB
repos

Create repository

Create a repository.

Repos collect Full scans and Diff scans and are typically associated with a git repo.

This endpoint consumes 1 unit of your quota.

This endpoint requires the following org token scopes:

  • repo:create
post/orgs/{org_slug}/repos

Path parameters

org_slugstring required

The slug of the organization

Query parameters

on_duplicatestring

Set to "redirect" to receive a 302 redirect to the existing repo instead of a 409 error when a duplicate slug is detected.

Request body

namestring

The display name of the repository. When provided without a slug, the slug is automatically derived from the name. When omitted, the slug is used as the name. At least one of name or slug must be provided.

descriptionstring nullable

The description of the repository

homepagestring nullable

The homepage URL of the repository

visibility'public' | 'private'

The visibility of the repository

archivedboolean

Whether the repository is archived or not

default_branchstring nullable

The default branch of the repository

workspacestring

The workspace of the repository

slugstring

The slug of the repository. If provided, used directly instead of being derived from name. Must only contain ASCII letters, digits, and the characters ., -, and _.

Response

Lists repositories for the specified organization. The authenticated user must be a member of the organization.

idstring

The ID of the repository

created_atstring

The creation date of the repository

updated_atstring

The last update date of the repository

html_urlstring

The URL to the repository dashboard page

head_full_scan_idstring nullable

The ID of the head full scan of the repository

slugstring

The slug of the repository.

namestring

The name of the repository

descriptionstring nullable

The description of the repository

homepagestring nullable

The homepage URL of the repository

visibility'public' | 'private'

The visibility of the repository

archivedboolean

Whether the repository is archived or not

default_branchstring nullable

The default branch of the repository

workspacestring

The workspace of the repository