Vers repositories API
The repositories API from Vers — 6 operation(s) for repositories.
The repositories API from Vers — 6 operation(s) for repositories.
openapi: 3.1.0
info:
title: Orchestrator Control Plane commit_tags repositories API
description: ''
license:
name: ''
version: 0.1.0
tags:
- name: repositories
paths:
/api/v1/repositories:
get:
tags:
- repositories
operationId: list_repositories
responses:
'200':
description: List of repositories
content:
application/json:
schema:
$ref: '#/components/schemas/ListRepositoriesResponse'
'401':
description: Unauthorized
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
post:
tags:
- repositories
operationId: create_repository
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateRepositoryRequest'
required: true
responses:
'201':
description: Repository created
content:
application/json:
schema:
$ref: '#/components/schemas/CreateRepositoryResponse'
'400':
description: Invalid name
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'401':
description: Unauthorized
'409':
description: Repository already exists
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
/api/v1/repositories/fork:
post:
tags:
- repositories
operationId: fork_repository
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/ForkRepositoryRequest'
required: true
responses:
'201':
description: Repository forked successfully
content:
application/json:
schema:
$ref: '#/components/schemas/ForkRepositoryResponse'
'401':
description: Unauthorized
'404':
description: Source repository or tag not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'409':
description: Target repository already exists
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
/api/v1/repositories/{repo_name}:
get:
tags:
- repositories
operationId: get_repository
parameters:
- name: repo_name
in: path
description: Repository name
required: true
schema:
type: string
responses:
'200':
description: Repository details
content:
application/json:
schema:
$ref: '#/components/schemas/RepositoryInfo'
'401':
description: Unauthorized
'404':
description: Repository not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
delete:
tags:
- repositories
operationId: delete_repository
parameters:
- name: repo_name
in: path
description: Repository name
required: true
schema:
type: string
responses:
'204':
description: Repository deleted
'401':
description: Unauthorized
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'404':
description: Repository not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
/api/v1/repositories/{repo_name}/tags:
get:
tags:
- repositories
operationId: list_repo_tags
parameters:
- name: repo_name
in: path
description: Repository name
required: true
schema:
type: string
responses:
'200':
description: List of tags in repository
content:
application/json:
schema:
$ref: '#/components/schemas/ListRepoTagsResponse'
'401':
description: Unauthorized
'404':
description: Repository not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
post:
tags:
- repositories
operationId: create_repo_tag
parameters:
- name: repo_name
in: path
description: Repository name
required: true
schema:
type: string
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateRepoTagRequest'
required: true
responses:
'201':
description: Tag created
content:
application/json:
schema:
$ref: '#/components/schemas/CreateRepoTagResponse'
'400':
description: Invalid tag name
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'401':
description: Unauthorized
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'404':
description: Repository or commit not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'409':
description: Tag already exists
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
/api/v1/repositories/{repo_name}/tags/{tag_name}:
get:
tags:
- repositories
operationId: get_repo_tag
parameters:
- name: repo_name
in: path
description: Repository name
required: true
schema:
type: string
- name: tag_name
in: path
description: Tag name
required: true
schema:
type: string
responses:
'200':
description: Tag details
content:
application/json:
schema:
$ref: '#/components/schemas/RepoTagInfo'
'401':
description: Unauthorized
'404':
description: Repository or tag not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
delete:
tags:
- repositories
operationId: delete_repo_tag
parameters:
- name: repo_name
in: path
description: Repository name
required: true
schema:
type: string
- name: tag_name
in: path
description: Tag name
required: true
schema:
type: string
responses:
'204':
description: Tag deleted
'401':
description: Unauthorized
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'404':
description: Repository or tag not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
patch:
tags:
- repositories
operationId: update_repo_tag
parameters:
- name: repo_name
in: path
description: Repository name
required: true
schema:
type: string
- name: tag_name
in: path
description: Tag name
required: true
schema:
type: string
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateRepoTagRequest'
required: true
responses:
'204':
description: Tag updated
'400':
description: No updates provided
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'401':
description: Unauthorized
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'404':
description: Repository, tag, or commit not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
/api/v1/repositories/{repo_name}/visibility:
patch:
tags:
- repositories
operationId: set_repository_visibility
parameters:
- name: repo_name
in: path
description: Repository name
required: true
schema:
type: string
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/SetRepositoryVisibilityRequest'
required: true
responses:
'204':
description: Visibility updated
'401':
description: Unauthorized
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'404':
description: Repository not found
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
'500':
description: Internal server error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorResponse'
security:
- bearer_auth: []
components:
schemas:
ErrorResponse:
type: object
properties:
error:
type: string
description: Reason of error
success:
type: boolean
description: 'Is always: false'
RepositoryInfo:
type: object
description: Repository information returned in list and get operations
required:
- repo_id
- name
- is_public
- created_at
properties:
created_at:
type: string
format: date-time
description: When the repository was created
description:
type:
- string
- 'null'
description: Optional description
is_public:
type: boolean
description: Whether this repository is publicly visible
name:
type: string
description: The repository name
repo_id:
type: string
format: uuid
description: The repository's unique identifier
CreateRepositoryRequest:
type: object
description: Request body for POST /api/v1/repositories
required:
- name
properties:
description:
type:
- string
- 'null'
description: Optional description of the repository
name:
type: string
description: The name of the repository (alphanumeric, hyphens, underscores, dots, 1-64 chars)
UpdateRepoTagRequest:
type: object
description: Request body for PATCH /api/v1/repositories/{repo_name}/tags/{tag_name}
properties:
commit_id:
type:
- string
- 'null'
format: uuid
description: Optional new commit ID to move the tag to
description:
type:
- string
- 'null'
description: Optional new description for the tag. Send `null` to clear.
RepoTagInfo:
type: object
description: Tag information within a repository context
required:
- tag_id
- tag_name
- reference
- commit_id
- created_at
- updated_at
properties:
commit_id:
type: string
format: uuid
description: The commit ID this tag currently points to
created_at:
type: string
format: date-time
description: When the tag was created
description:
type:
- string
- 'null'
description: Optional description
reference:
type: string
description: Full reference in image_name:tag format
tag_id:
type: string
format: uuid
description: The tag's unique identifier
tag_name:
type: string
description: The tag name
updated_at:
type: string
format: date-time
description: When the tag was last updated
CreateRepoTagRequest:
type: object
description: 'Request body for creating a tag within a repository: POST /api/v1/repositories/{repo_name}/tags'
required:
- tag_name
- commit_id
properties:
commit_id:
type: string
format: uuid
description: The commit ID this tag should point to
description:
type:
- string
- 'null'
description: Optional description of what this tag represents
tag_name:
type: string
description: The tag name (e.g. "latest", "v1.0")
CreateRepoTagResponse:
type: object
description: Response body for POST /api/v1/repositories/{repo_name}/tags
required:
- tag_id
- reference
- commit_id
properties:
commit_id:
type: string
format: uuid
description: The commit ID this tag points to
reference:
type: string
description: Full reference in image_name:tag format
tag_id:
type: string
format: uuid
description: The ID of the newly created tag
ListRepositoriesResponse:
type: object
description: Response body for GET /api/v1/repositories
required:
- repositories
properties:
repositories:
type: array
items:
$ref: '#/components/schemas/RepositoryInfo'
description: List of all repositories in the user's organization
SetRepositoryVisibilityRequest:
type: object
description: Request body for PATCH /api/v1/repositories/{repo_name}/visibility
required:
- is_public
properties:
is_public:
type: boolean
description: Whether the repository should be publicly visible
ForkRepositoryRequest:
type: object
description: Request body for POST /api/v1/repositories/fork
required:
- source_org
- source_repo
- source_tag
properties:
repo_name:
type:
- string
- 'null'
description: Name for the new repository in your org (defaults to source_repo if omitted)
source_org:
type: string
description: The organization that owns the source public repository
source_repo:
type: string
description: The source repository name
source_tag:
type: string
description: The tag to fork (e.g. "latest", "v1.0")
tag_name:
type:
- string
- 'null'
description: Tag name in the new repo (defaults to source_tag if omitted)
ListRepoTagsResponse:
type: object
description: Response body for GET /api/v1/repositories/{repo_name}/tags
required:
- repository
- tags
properties:
repository:
type: string
description: The repository name
tags:
type: array
items:
$ref: '#/components/schemas/RepoTagInfo'
description: List of tags in this repository
CreateRepositoryResponse:
type: object
description: Response body for POST /api/v1/repositories
required:
- repo_id
- name
properties:
name:
type: string
description: The name of the repository
repo_id:
type: string
format: uuid
description: The ID of the newly created repository
ForkRepositoryResponse:
type: object
description: Response body for POST /api/v1/repositories/fork
required:
- vm_id
- commit_id
- repo_name
- tag_name
- reference
properties:
commit_id:
type: string
format: uuid
description: The new commit in your org (snapshot of the forked VM)
reference:
type: string
description: 'Full reference: repo_name:tag_name'
repo_name:
type: string
description: The new repository name in your org
tag_name:
type: string
description: The tag name pointing to the forked commit
vm_id:
type: string
description: The new VM that was created from the fork
securitySchemes:
bearer_auth:
type: http
scheme: bearer
bearerFormat: Token