permissions
Creates, updates, deletes, gets or lists a permissions resource.
Overview
| Name | permissions |
| Type | Resource |
| Id | vercel.vcr.permissions |
Fields
The following fields are returned by SELECT queries:
- list
A team's access grant to a Vercel Container Registry repository.
| Name | Datatype | Description |
|---|---|---|
repository_id | string | Identifier of the repository the permission grants access to. (example: repo_a1b2c3d4e5f6) (wire: repositoryId) |
team_id | string | Identifier of the team that is granted access to the repository. (example: team_a1b2c3d4e5f6) (wire: teamId) |
created_at | string | ISO 8601 timestamp of when the permission was created. (example: 2026-06-30T10:00:00.000Z) (wire: createdAt) |
team_slug | string | Slug of the team that is granted access to the repository. (example: my-team) (wire: teamSlug) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list | select | project_id, id_or_name | limit, cursor, team_id, slug | List the teams a VCR repository is shared with. |
create | insert | project_id, id_or_name | slug | Grant a team access to a VCR repository. Sharing applies to the whole repository. |
delete | delete | project_id, id_or_name | slug | Revoke a team's access to a VCR repository. |
clear | exec | projectId, id_or_name | teamId, slug | Revoke every team's access to a VCR repository. Clearing an unshared repository is a no-op. |
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.
| Name | Datatype | Description |
|---|---|---|
id_or_name | string | |
projectId | string | Project ID. Missing or empty values return HTTP 400. |
project_id | string | Project ID. Missing or empty values return HTTP 400. (wire: projectId) |
cursor | string | Opaque pagination cursor returned by a previous list response. |
limit | integer | |
slug | string | The Team slug to perform the request on behalf of. |
teamId | string | The Team identifier to perform the request on behalf of. |
team_id | string | The Team identifier to perform the request on behalf of. (wire: teamId) |
SELECT examples
- list
List the teams a VCR repository is shared with.
SELECT
repository_id,
team_id,
created_at,
team_slug
FROM vercel.vcr.permissions
WHERE project_id = '{{ project_id }}' -- required
AND id_or_name = '{{ id_or_name }}' -- required
AND limit = '{{ limit }}'
AND cursor = '{{ cursor }}'
AND team_id = '{{ team_id }}'
AND slug = '{{ slug }}'
;
INSERT examples
- create
- Manifest
Grant a team access to a VCR repository. Sharing applies to the whole repository.
INSERT INTO vercel.vcr.permissions (
team_id,
team_slug,
project_id,
id_or_name,
slug
)
SELECT
'{{ team_id }}',
'{{ team_slug }}',
'{{ project_id }}',
'{{ id_or_name }}',
'{{ slug }}'
RETURNING
permission
;
# Description fields are for documentation purposes
- name: permissions
props:
- name: project_id
value: "{{ project_id }}"
description: Required parameter for the permissions resource.
- name: id_or_name
value: "{{ id_or_name }}"
description: Required parameter for the permissions resource.
- name: team_id
value: "{{ team_id }}"
description: |
ID of a team that is granted access to a repository.
- name: team_slug
value: "{{ team_slug }}"
description: |
Slug of a team that is granted access to a repository.
- name: slug
value: "{{ slug }}"
description: The Team slug to perform the request on behalf of.
description: The Team slug to perform the request on behalf of.
DELETE examples
- delete
Revoke a team's access to a VCR repository.
DELETE FROM vercel.vcr.permissions
WHERE project_id = '{{ project_id }}' --required
AND id_or_name = '{{ id_or_name }}' --required
AND slug = '{{ slug }}'
;
Lifecycle Methods
EXEC variables use wire (API) names.
- clear
Revoke every team's access to a VCR repository. Clearing an unshared repository is a no-op.
EXEC vercel.vcr.permissions.clear
@projectId='{{ projectId }}' --required,
@id_or_name='{{ id_or_name }}' --required,
@teamId='{{ teamId }}',
@slug='{{ slug }}'
;