- HTTP request
 - Path parameters
 - Request body
 - Response body
 - Authorization scopes
 - IAM Permissions
 - Try it!
 
Fetches read token of a given gitRepositoryLink.
HTTP request
POST https://developerconnect.googleapis.com/v1/{gitRepositoryLink=projects/*/locations/*/connections/*/gitRepositoryLinks/*}:fetchReadToken
The URL uses gRPC Transcoding syntax.
Path parameters
| Parameters | |
|---|---|
gitRepositoryLink | 
                
                   
 Required. The resource name of the gitRepositoryLink 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, "gitUsername": string }  | 
                  
| Fields | |
|---|---|
token | 
                    
                       
 The token content.  | 
                  
expirationTime | 
                    
                       
 Expiration timestamp. Can be empty if unknown or non-expiring. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples:   | 
                  
gitUsername | 
                    
                       
 The gitUsername to specify when making a git clone with the token. For example, for GitHub GitRepositoryLinks, this would be "x-access-token"  | 
                  
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 gitRepositoryLink resource:
developerconnect.gitRepositoryLinks.fetchReadToken
For more information, see the IAM documentation.