- HTTP request
- Path parameters
- Request body
- Response body
- Authorization scopes
- IAM Permissions
- Try it!
Fetches read token of a given repository.
HTTP request
POST https://cloudbuild.googleapis.com/v2/{repository=projects/*/locations/*/connections/*/repositories/*}:accessReadToken
The URL uses gRPC Transcoding syntax.
Path parameters
Parameters | |
---|---|
repository |
Required. The resource name of the repository in the format |
Request body
The request body must be empty.
Response body
Message for responding to get read token.
If successful, the response body contains data with the following structure:
JSON representation |
---|
{ "token": string, "expirationTime": string } |
Fields | |
---|---|
token |
The token content. |
expirationTime |
Expiration timestamp. Can be empty if unknown or non-expiring. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: |
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/cloud-platform
For more information, see the Authentication Overview.
IAM Permissions
Requires the following IAM permission on the repository
resource:
cloudbuild.repositories.accessReadToken
For more information, see the IAM documentation.