Skip to main content

repositories

Creates, updates, deletes, gets or lists a repositories resource.

Overview

Namerepositories
TypeResource
Idvercel.vcr.repositories

Fields

The following fields are returned by SELECT queries:

A Vercel Container Registry repository.

NameDatatypeDescription
idstringUnique identifier of the repository. (example: repo_a1b2c3d4e5f6)
namestringName of the repository. (example: my-app)
project_idstringIdentifier of the project the repository belongs to. (example: prj_a1b2c3d4e5f6) (wire: projectId)
created_atstringISO 8601 timestamp of when the repository was created. (example: 2026-06-30T10:00:00.000Z) (wire: createdAt)
publicbooleanWhether the repository is public. Images in public repositories can be pulled by anyone. Defaults to false (private). (false, true)
updated_atstringISO 8601 timestamp of when the repository was last updated. (example: 2026-06-30T10:00:00.000Z) (wire: updatedAt)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectproject_id, id_or_nameteam_id, slugFetch a container registry repository for a project by ID or name.
listselectproject_idlimit, cursor, team_id, slugList container registry repositories for a project.
createinsertproject_id, nameteam_id, slugCreate a container registry repository for a project.
deletedeleteproject_id, id_or_nameteam_id, slugSchedule a repository for deletion. The repository is marked so it disappears from list/get immediately; subscriber-vcr reclaims every image (manifests, blobs, tags and rows) and finally deletes the repository row asynchronously via the VcrRepositoryRemoved event.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
id_or_namestring
project_idstringProject ID. Missing or empty values return HTTP 400. (wire: projectId)
cursorstringOpaque pagination cursor returned by a previous list response.
limitinteger
slugstringThe Team slug to perform the request on behalf of.
team_idstringThe Team identifier to perform the request on behalf of. (wire: teamId)

SELECT examples

Fetch a container registry repository for a project by ID or name.

SELECT
id,
name,
project_id,
created_at,
public,
updated_at
FROM vercel.vcr.repositories
WHERE project_id = '{{ project_id }}' -- required
AND id_or_name = '{{ id_or_name }}' -- required
AND team_id = '{{ team_id }}'
AND slug = '{{ slug }}'
;

INSERT examples

Create a container registry repository for a project.

INSERT INTO vercel.vcr.repositories (
project_id,
name,
team_id,
slug
)
SELECT
'{{ project_id }}' /* required */,
'{{ name }}' /* required */,
'{{ team_id }}',
'{{ slug }}'
RETURNING
repository
;

DELETE examples

Schedule a repository for deletion. The repository is marked so it disappears from list/get immediately; subscriber-vcr reclaims every image (manifests, blobs, tags and rows) and finally deletes the repository row asynchronously via the VcrRepositoryRemoved event.

DELETE FROM vercel.vcr.repositories
WHERE project_id = '{{ project_id }}' --required
AND id_or_name = '{{ id_or_name }}' --required
AND team_id = '{{ team_id }}'
AND slug = '{{ slug }}'
;