AzurePipelinesCredential Class
- java.
lang. Object - com.
azure. identity. AzurePipelinesCredential
- com.
Implements
public class AzurePipelinesCredential
implements TokenCredential
The AzurePipelinesCredential acquires a token using the Azure Pipelines service connection. To construct an instance of this credential, use the AzurePipelinesCredentialBuilder:
Java
// serviceConnectionId is retrieved from the portal.
// systemAccessToken is retrieved from the pipeline environment as shown.
// You may choose another name for this variable.
String systemAccessToken = System.getenv("SYSTEM_ACCESSTOKEN");
AzurePipelinesCredential credential = new AzurePipelinesCredentialBuilder().clientId(clientId)
.tenantId(tenantId)
.serviceConnectionId(serviceConnectionId)
.systemAccessToken(systemAccessToken)
.build();
Modifier and Type | Method and Description |
---|---|
Mono<Access |
get |
Access |
get |
Methods inherited from java.lang.Object
getToken
public Mono
Parameters:
request
getTokenSync
public AccessToken getTokenSync(TokenRequestContext request)
Parameters:
request
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.
Azure SDK for Java feedback
Azure SDK for Java is an open source project. Select a link to provide feedback: