repositories
Creates, updates, deletes, gets or lists a repositories
resource.
Overview
Name | repositories |
Type | Resource |
Id | google.securesourcemanager.repositories |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Optional. A unique identifier for a repository. The name should be of the format: projects/{project}/locations/{location_id}/repositories/{repository_id} |
createTime | string (google-datetime) | Output only. Create timestamp. |
description | string | Optional. Description of the repository, which cannot exceed 500 characters. |
etag | string | Optional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding. |
initialConfig | object | Input only. Initial configurations for the repository. (id: InitialConfig) |
instance | string | Optional. The name of the instance in which the repository is hosted, formatted as projects/{project_number}/locations/{location_id}/instances/{instance_id} When creating repository via securesourcemanager.googleapis.com, this field is used as input. When creating repository via *.sourcemanager.dev, this field is output only. |
uid | string | Output only. Unique identifier of the repository. |
updateTime | string (google-datetime) | Output only. Update timestamp. |
uris | object | Output only. URIs for the repository. (id: URIs) |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Optional. A unique identifier for a repository. The name should be of the format: projects/{project}/locations/{location_id}/repositories/{repository_id} |
createTime | string (google-datetime) | Output only. Create timestamp. |
description | string | Optional. Description of the repository, which cannot exceed 500 characters. |
etag | string | Optional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding. |
initialConfig | object | Input only. Initial configurations for the repository. (id: InitialConfig) |
instance | string | Optional. The name of the instance in which the repository is hosted, formatted as projects/{project_number}/locations/{location_id}/instances/{instance_id} When creating repository via securesourcemanager.googleapis.com, this field is used as input. When creating repository via *.sourcemanager.dev, this field is output only. |
uid | string | Output only. Unique identifier of the repository. |
updateTime | string (google-datetime) | Output only. Update timestamp. |
uris | object | Output only. URIs for the repository. (id: URIs) |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , locationsId , repositoriesId | Gets metadata of a repository. | |
list | select | projectsId , locationsId | pageSize , pageToken , filter , instance | Lists Repositories in a given project and location. The instance field is required in the query parameter for requests using the securesourcemanager.googleapis.com endpoint. |
create | insert | projectsId , locationsId | repositoryId | Creates a new repository in a given project and location. The Repository.Instance field is required in the request body for requests using the securesourcemanager.googleapis.com endpoint. |
patch | update | projectsId , locationsId , repositoriesId | updateMask , validateOnly | Updates the metadata of a repository. |
delete | delete | projectsId , locationsId , repositoriesId | allowMissing | Deletes a Repository. |
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 |
---|---|---|
locationsId | string | |
projectsId | string | |
repositoriesId | string | |
allowMissing | boolean | |
filter | string | |
instance | string | |
pageSize | integer (int32) | |
pageToken | string | |
repositoryId | string | |
updateMask | string (google-fieldmask) | |
validateOnly | boolean |
SELECT
examples
- get
- list
Gets metadata of a repository.
SELECT
name,
createTime,
description,
etag,
initialConfig,
instance,
uid,
updateTime,
uris
FROM google.securesourcemanager.repositories
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND repositoriesId = '{{ repositoriesId }}' -- required;
Lists Repositories in a given project and location. The instance field is required in the query parameter for requests using the securesourcemanager.googleapis.com endpoint.
SELECT
name,
createTime,
description,
etag,
initialConfig,
instance,
uid,
updateTime,
uris
FROM google.securesourcemanager.repositories
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND filter = '{{ filter }}'
AND instance = '{{ instance }}';
INSERT
examples
- create
- Manifest
Creates a new repository in a given project and location. The Repository.Instance field is required in the request body for requests using the securesourcemanager.googleapis.com endpoint.
INSERT INTO google.securesourcemanager.repositories (
data__name,
data__description,
data__instance,
data__etag,
data__initialConfig,
projectsId,
locationsId,
repositoryId
)
SELECT
'{{ name }}',
'{{ description }}',
'{{ instance }}',
'{{ etag }}',
'{{ initialConfig }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ repositoryId }}'
RETURNING
name,
done,
error,
metadata,
response
;
# Description fields are for documentation purposes
- name: repositories
props:
- name: projectsId
value: string
description: Required parameter for the repositories resource.
- name: locationsId
value: string
description: Required parameter for the repositories resource.
- name: name
value: string
description: >
Optional. A unique identifier for a repository. The name should be of the format: `projects/{project}/locations/{location_id}/repositories/{repository_id}`
- name: description
value: string
description: >
Optional. Description of the repository, which cannot exceed 500 characters.
- name: instance
value: string
description: >
Optional. The name of the instance in which the repository is hosted, formatted as `projects/{project_number}/locations/{location_id}/instances/{instance_id}` When creating repository via securesourcemanager.googleapis.com, this field is used as input. When creating repository via *.sourcemanager.dev, this field is output only.
- name: etag
value: string
description: >
Optional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.
- name: initialConfig
value: object
description: >
Input only. Initial configurations for the repository.
- name: repositoryId
value: string
UPDATE
examples
- patch
Updates the metadata of a repository.
UPDATE google.securesourcemanager.repositories
SET
data__name = '{{ name }}',
data__description = '{{ description }}',
data__instance = '{{ instance }}',
data__etag = '{{ etag }}',
data__initialConfig = '{{ initialConfig }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND repositoriesId = '{{ repositoriesId }}' --required
AND updateMask = '{{ updateMask}}'
AND validateOnly = {{ validateOnly}}
RETURNING
name,
done,
error,
metadata,
response;
DELETE
examples
- delete
Deletes a Repository.
DELETE FROM google.securesourcemanager.repositories
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND repositoriesId = '{{ repositoriesId }}' --required
AND allowMissing = '{{ allowMissing }}';