public abstract class CertificateAuthorityServiceClient
Reference documentation and code samples for the Certificate Authority v1beta1 API class CertificateAuthorityServiceClient.
CertificateAuthorityService client wrapper, for convenient use.
Derived Types
Namespace
Google.Cloud.Security.PrivateCA.V1Beta1Assembly
Google.Cloud.Security.PrivateCA.V1Beta1.dll
Remarks
[Certificate Authority Service][google.cloud.security.privateca.v1beta1.CertificateAuthorityService] manages private certificate authorities and issued certificates.
Properties
ActivateCertificateAuthorityOperationsClient
public virtual OperationsClient ActivateCertificateAuthorityOperationsClient { get; }
The long-running operations client for ActivateCertificateAuthority
.
Property Value | |
---|---|
Type | Description |
OperationsClient |
CreateCertificateAuthorityOperationsClient
public virtual OperationsClient CreateCertificateAuthorityOperationsClient { get; }
The long-running operations client for CreateCertificateAuthority
.
Property Value | |
---|---|
Type | Description |
OperationsClient |
DefaultEndpoint
public static string DefaultEndpoint { get; }
The default endpoint for the CertificateAuthorityService service, which is a host of "privateca.googleapis.com" and a port of 443.
Property Value | |
---|---|
Type | Description |
String |
DefaultScopes
public static IReadOnlyList<string> DefaultScopes { get; }
The default CertificateAuthorityService scopes.
Property Value | |
---|---|
Type | Description |
IReadOnlyList<String> |
The default CertificateAuthorityService scopes are:
DisableCertificateAuthorityOperationsClient
public virtual OperationsClient DisableCertificateAuthorityOperationsClient { get; }
The long-running operations client for DisableCertificateAuthority
.
Property Value | |
---|---|
Type | Description |
OperationsClient |
EnableCertificateAuthorityOperationsClient
public virtual OperationsClient EnableCertificateAuthorityOperationsClient { get; }
The long-running operations client for EnableCertificateAuthority
.
Property Value | |
---|---|
Type | Description |
OperationsClient |
GrpcClient
public virtual CertificateAuthorityService.CertificateAuthorityServiceClient GrpcClient { get; }
The underlying gRPC CertificateAuthorityService client
Property Value | |
---|---|
Type | Description |
CertificateAuthorityService.CertificateAuthorityServiceClient |
RestoreCertificateAuthorityOperationsClient
public virtual OperationsClient RestoreCertificateAuthorityOperationsClient { get; }
The long-running operations client for RestoreCertificateAuthority
.
Property Value | |
---|---|
Type | Description |
OperationsClient |
ScheduleDeleteCertificateAuthorityOperationsClient
public virtual OperationsClient ScheduleDeleteCertificateAuthorityOperationsClient { get; }
The long-running operations client for ScheduleDeleteCertificateAuthority
.
Property Value | |
---|---|
Type | Description |
OperationsClient |
ServiceMetadata
public static ServiceMetadata ServiceMetadata { get; }
The service metadata associated with this client type.
Property Value | |
---|---|
Type | Description |
ServiceMetadata |
UpdateCertificateAuthorityOperationsClient
public virtual OperationsClient UpdateCertificateAuthorityOperationsClient { get; }
The long-running operations client for UpdateCertificateAuthority
.
Property Value | |
---|---|
Type | Description |
OperationsClient |
UpdateCertificateRevocationListOperationsClient
public virtual OperationsClient UpdateCertificateRevocationListOperationsClient { get; }
The long-running operations client for UpdateCertificateRevocationList
.
Property Value | |
---|---|
Type | Description |
OperationsClient |
Methods
ActivateCertificateAuthority(ActivateCertificateAuthorityRequest, CallSettings)
public virtual Operation<CertificateAuthority, OperationMetadata> ActivateCertificateAuthority(ActivateCertificateAuthorityRequest request, CallSettings callSettings = null)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
request | ActivateCertificateAuthorityRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Operation<CertificateAuthority, OperationMetadata> | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
ActivateCertificateAuthorityRequest request = new ActivateCertificateAuthorityRequest
{
CertificateAuthorityName = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]"),
PemCaCertificate = "",
SubordinateConfig = new SubordinateConfig(),
RequestId = "",
};
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = certificateAuthorityServiceClient.ActivateCertificateAuthority(request);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = certificateAuthorityServiceClient.PollOnceActivateCertificateAuthority(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
ActivateCertificateAuthority(CertificateAuthorityName, CallSettings)
public virtual Operation<CertificateAuthority, OperationMetadata> ActivateCertificateAuthority(CertificateAuthorityName name, CallSettings callSettings = null)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
name | CertificateAuthorityName Required. The resource name for this [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in the
format |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Operation<CertificateAuthority, OperationMetadata> | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
CertificateAuthorityName name = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]");
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = certificateAuthorityServiceClient.ActivateCertificateAuthority(name);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = certificateAuthorityServiceClient.PollOnceActivateCertificateAuthority(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
ActivateCertificateAuthority(String, CallSettings)
public virtual Operation<CertificateAuthority, OperationMetadata> ActivateCertificateAuthority(string name, CallSettings callSettings = null)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
name | String Required. The resource name for this [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in the
format |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Operation<CertificateAuthority, OperationMetadata> | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/certificateAuthorities/[CERTIFICATE_AUTHORITY]";
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = certificateAuthorityServiceClient.ActivateCertificateAuthority(name);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = certificateAuthorityServiceClient.PollOnceActivateCertificateAuthority(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
ActivateCertificateAuthorityAsync(ActivateCertificateAuthorityRequest, CallSettings)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> ActivateCertificateAuthorityAsync(ActivateCertificateAuthorityRequest request, CallSettings callSettings = null)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
request | ActivateCertificateAuthorityRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
ActivateCertificateAuthorityRequest request = new ActivateCertificateAuthorityRequest
{
CertificateAuthorityName = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]"),
PemCaCertificate = "",
SubordinateConfig = new SubordinateConfig(),
RequestId = "",
};
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.ActivateCertificateAuthorityAsync(request);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceActivateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
ActivateCertificateAuthorityAsync(ActivateCertificateAuthorityRequest, CancellationToken)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> ActivateCertificateAuthorityAsync(ActivateCertificateAuthorityRequest request, CancellationToken cancellationToken)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
request | ActivateCertificateAuthorityRequest The request object containing all of the parameters for the API call. |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
ActivateCertificateAuthorityRequest request = new ActivateCertificateAuthorityRequest
{
CertificateAuthorityName = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]"),
PemCaCertificate = "",
SubordinateConfig = new SubordinateConfig(),
RequestId = "",
};
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.ActivateCertificateAuthorityAsync(request);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceActivateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
ActivateCertificateAuthorityAsync(CertificateAuthorityName, CallSettings)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> ActivateCertificateAuthorityAsync(CertificateAuthorityName name, CallSettings callSettings = null)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
name | CertificateAuthorityName Required. The resource name for this [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in the
format |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
CertificateAuthorityName name = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]");
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.ActivateCertificateAuthorityAsync(name);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceActivateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
ActivateCertificateAuthorityAsync(CertificateAuthorityName, CancellationToken)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> ActivateCertificateAuthorityAsync(CertificateAuthorityName name, CancellationToken cancellationToken)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
name | CertificateAuthorityName Required. The resource name for this [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in the
format |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
CertificateAuthorityName name = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]");
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.ActivateCertificateAuthorityAsync(name);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceActivateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
ActivateCertificateAuthorityAsync(String, CallSettings)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> ActivateCertificateAuthorityAsync(string name, CallSettings callSettings = null)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
name | String Required. The resource name for this [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in the
format |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/certificateAuthorities/[CERTIFICATE_AUTHORITY]";
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.ActivateCertificateAuthorityAsync(name);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceActivateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
ActivateCertificateAuthorityAsync(String, CancellationToken)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> ActivateCertificateAuthorityAsync(string name, CancellationToken cancellationToken)
Activate a [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] that is in state [PENDING_ACTIVATION][google.cloud.security.privateca.v1beta1.CertificateAuthority.State.PENDING_ACTIVATION] and is of type [SUBORDINATE][google.cloud.security.privateca.v1beta1.CertificateAuthority.Type.SUBORDINATE]. After the parent Certificate Authority signs a certificate signing request from [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1beta1.CertificateAuthorityService.FetchCertificateAuthorityCsr], this method can complete the activation process.
Parameters | |
---|---|
Name | Description |
name | String Required. The resource name for this [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in the
format |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/certificateAuthorities/[CERTIFICATE_AUTHORITY]";
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.ActivateCertificateAuthorityAsync(name);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceActivateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
Create()
public static CertificateAuthorityServiceClient Create()
Synchronously creates a CertificateAuthorityServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use CertificateAuthorityServiceClientBuilder.
Returns | |
---|---|
Type | Description |
CertificateAuthorityServiceClient | The created CertificateAuthorityServiceClient. |
CreateAsync(CancellationToken)
public static Task<CertificateAuthorityServiceClient> CreateAsync(CancellationToken cancellationToken = default(CancellationToken))
Asynchronously creates a CertificateAuthorityServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use CertificateAuthorityServiceClientBuilder.
Parameter | |
---|---|
Name | Description |
cancellationToken | CancellationToken The CancellationToken to use while creating the client. |
Returns | |
---|---|
Type | Description |
Task<CertificateAuthorityServiceClient> | The task representing the created CertificateAuthorityServiceClient. |
CreateCertificate(CertificateAuthorityName, Certificate, String, CallSettings)
public virtual Certificate CreateCertificate(CertificateAuthorityName parent, Certificate certificate, string certificateId, CallSettings callSettings = null)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
parent | CertificateAuthorityName Required. The resource name of the location and [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority]
associated with the [Certificate][google.cloud.security.privateca.v1beta1.Certificate], in the format
|
certificate | Certificate Required. A [Certificate][google.cloud.security.privateca.v1beta1.Certificate] with initial field values. |
certificateId | String Optional. It must be unique within a location and match the regular
expression |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Certificate | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
CertificateAuthorityName parent = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]");
Certificate certificate = new Certificate();
string certificateId = "";
// Make the request
Certificate response = certificateAuthorityServiceClient.CreateCertificate(parent, certificate, certificateId);
CreateCertificate(CreateCertificateRequest, CallSettings)
public virtual Certificate CreateCertificate(CreateCertificateRequest request, CallSettings callSettings = null)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
request | CreateCertificateRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Certificate | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
CreateCertificateRequest request = new CreateCertificateRequest
{
ParentAsCertificateAuthorityName = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]"),
CertificateId = "",
Certificate = new Certificate(),
RequestId = "",
};
// Make the request
Certificate response = certificateAuthorityServiceClient.CreateCertificate(request);
CreateCertificate(String, Certificate, String, CallSettings)
public virtual Certificate CreateCertificate(string parent, Certificate certificate, string certificateId, CallSettings callSettings = null)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
parent | String Required. The resource name of the location and [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority]
associated with the [Certificate][google.cloud.security.privateca.v1beta1.Certificate], in the format
|
certificate | Certificate Required. A [Certificate][google.cloud.security.privateca.v1beta1.Certificate] with initial field values. |
certificateId | String Optional. It must be unique within a location and match the regular
expression |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Certificate | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/certificateAuthorities/[CERTIFICATE_AUTHORITY]";
Certificate certificate = new Certificate();
string certificateId = "";
// Make the request
Certificate response = certificateAuthorityServiceClient.CreateCertificate(parent, certificate, certificateId);
CreateCertificateAsync(CertificateAuthorityName, Certificate, String, CallSettings)
public virtual Task<Certificate> CreateCertificateAsync(CertificateAuthorityName parent, Certificate certificate, string certificateId, CallSettings callSettings = null)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
parent | CertificateAuthorityName Required. The resource name of the location and [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority]
associated with the [Certificate][google.cloud.security.privateca.v1beta1.Certificate], in the format
|
certificate | Certificate Required. A [Certificate][google.cloud.security.privateca.v1beta1.Certificate] with initial field values. |
certificateId | String Optional. It must be unique within a location and match the regular
expression |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Certificate> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
CertificateAuthorityName parent = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]");
Certificate certificate = new Certificate();
string certificateId = "";
// Make the request
Certificate response = await certificateAuthorityServiceClient.CreateCertificateAsync(parent, certificate, certificateId);
CreateCertificateAsync(CertificateAuthorityName, Certificate, String, CancellationToken)
public virtual Task<Certificate> CreateCertificateAsync(CertificateAuthorityName parent, Certificate certificate, string certificateId, CancellationToken cancellationToken)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
parent | CertificateAuthorityName Required. The resource name of the location and [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority]
associated with the [Certificate][google.cloud.security.privateca.v1beta1.Certificate], in the format
|
certificate | Certificate Required. A [Certificate][google.cloud.security.privateca.v1beta1.Certificate] with initial field values. |
certificateId | String Optional. It must be unique within a location and match the regular
expression |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Certificate> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
CertificateAuthorityName parent = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]");
Certificate certificate = new Certificate();
string certificateId = "";
// Make the request
Certificate response = await certificateAuthorityServiceClient.CreateCertificateAsync(parent, certificate, certificateId);
CreateCertificateAsync(CreateCertificateRequest, CallSettings)
public virtual Task<Certificate> CreateCertificateAsync(CreateCertificateRequest request, CallSettings callSettings = null)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
request | CreateCertificateRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Certificate> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
CreateCertificateRequest request = new CreateCertificateRequest
{
ParentAsCertificateAuthorityName = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]"),
CertificateId = "",
Certificate = new Certificate(),
RequestId = "",
};
// Make the request
Certificate response = await certificateAuthorityServiceClient.CreateCertificateAsync(request);
CreateCertificateAsync(CreateCertificateRequest, CancellationToken)
public virtual Task<Certificate> CreateCertificateAsync(CreateCertificateRequest request, CancellationToken cancellationToken)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
request | CreateCertificateRequest The request object containing all of the parameters for the API call. |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Certificate> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
CreateCertificateRequest request = new CreateCertificateRequest
{
ParentAsCertificateAuthorityName = CertificateAuthorityName.FromProjectLocationCertificateAuthority("[PROJECT]", "[LOCATION]", "[CERTIFICATE_AUTHORITY]"),
CertificateId = "",
Certificate = new Certificate(),
RequestId = "",
};
// Make the request
Certificate response = await certificateAuthorityServiceClient.CreateCertificateAsync(request);
CreateCertificateAsync(String, Certificate, String, CallSettings)
public virtual Task<Certificate> CreateCertificateAsync(string parent, Certificate certificate, string certificateId, CallSettings callSettings = null)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
parent | String Required. The resource name of the location and [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority]
associated with the [Certificate][google.cloud.security.privateca.v1beta1.Certificate], in the format
|
certificate | Certificate Required. A [Certificate][google.cloud.security.privateca.v1beta1.Certificate] with initial field values. |
certificateId | String Optional. It must be unique within a location and match the regular
expression |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Certificate> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/certificateAuthorities/[CERTIFICATE_AUTHORITY]";
Certificate certificate = new Certificate();
string certificateId = "";
// Make the request
Certificate response = await certificateAuthorityServiceClient.CreateCertificateAsync(parent, certificate, certificateId);
CreateCertificateAsync(String, Certificate, String, CancellationToken)
public virtual Task<Certificate> CreateCertificateAsync(string parent, Certificate certificate, string certificateId, CancellationToken cancellationToken)
Create a new [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in a given Project, Location from a particular [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
Parameters | |
---|---|
Name | Description |
parent | String Required. The resource name of the location and [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority]
associated with the [Certificate][google.cloud.security.privateca.v1beta1.Certificate], in the format
|
certificate | Certificate Required. A [Certificate][google.cloud.security.privateca.v1beta1.Certificate] with initial field values. |
certificateId | String Optional. It must be unique within a location and match the regular
expression |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Certificate> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/certificateAuthorities/[CERTIFICATE_AUTHORITY]";
Certificate certificate = new Certificate();
string certificateId = "";
// Make the request
Certificate response = await certificateAuthorityServiceClient.CreateCertificateAsync(parent, certificate, certificateId);
CreateCertificateAuthority(LocationName, CertificateAuthority, String, CallSettings)
public virtual Operation<CertificateAuthority, OperationMetadata> CreateCertificateAuthority(LocationName parent, CertificateAuthority certificateAuthority, string certificateAuthorityId, CallSettings callSettings = null)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
parent | LocationName Required. The resource name of the location associated with the
[CertificateAuthorities][google.cloud.security.privateca.v1beta1.CertificateAuthority], in the format
|
certificateAuthority | CertificateAuthority Required. A [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] with initial field values. |
certificateAuthorityId | String Required. It must be unique within a location and match the regular
expression |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Operation<CertificateAuthority, OperationMetadata> | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
CertificateAuthority certificateAuthority = new CertificateAuthority();
string certificateAuthorityId = "";
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = certificateAuthorityServiceClient.CreateCertificateAuthority(parent, certificateAuthority, certificateAuthorityId);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = certificateAuthorityServiceClient.PollOnceCreateCertificateAuthority(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
CreateCertificateAuthority(CreateCertificateAuthorityRequest, CallSettings)
public virtual Operation<CertificateAuthority, OperationMetadata> CreateCertificateAuthority(CreateCertificateAuthorityRequest request, CallSettings callSettings = null)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
request | CreateCertificateAuthorityRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Operation<CertificateAuthority, OperationMetadata> | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
CreateCertificateAuthorityRequest request = new CreateCertificateAuthorityRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
CertificateAuthorityId = "",
CertificateAuthority = new CertificateAuthority(),
RequestId = "",
};
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = certificateAuthorityServiceClient.CreateCertificateAuthority(request);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = certificateAuthorityServiceClient.PollOnceCreateCertificateAuthority(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
CreateCertificateAuthority(String, CertificateAuthority, String, CallSettings)
public virtual Operation<CertificateAuthority, OperationMetadata> CreateCertificateAuthority(string parent, CertificateAuthority certificateAuthority, string certificateAuthorityId, CallSettings callSettings = null)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
parent | String Required. The resource name of the location associated with the
[CertificateAuthorities][google.cloud.security.privateca.v1beta1.CertificateAuthority], in the format
|
certificateAuthority | CertificateAuthority Required. A [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] with initial field values. |
certificateAuthorityId | String Required. It must be unique within a location and match the regular
expression |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Operation<CertificateAuthority, OperationMetadata> | The RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = CertificateAuthorityServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
CertificateAuthority certificateAuthority = new CertificateAuthority();
string certificateAuthorityId = "";
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = certificateAuthorityServiceClient.CreateCertificateAuthority(parent, certificateAuthority, certificateAuthorityId);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = certificateAuthorityServiceClient.PollOnceCreateCertificateAuthority(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
CreateCertificateAuthorityAsync(LocationName, CertificateAuthority, String, CallSettings)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> CreateCertificateAuthorityAsync(LocationName parent, CertificateAuthority certificateAuthority, string certificateAuthorityId, CallSettings callSettings = null)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
parent | LocationName Required. The resource name of the location associated with the
[CertificateAuthorities][google.cloud.security.privateca.v1beta1.CertificateAuthority], in the format
|
certificateAuthority | CertificateAuthority Required. A [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] with initial field values. |
certificateAuthorityId | String Required. It must be unique within a location and match the regular
expression |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
CertificateAuthority certificateAuthority = new CertificateAuthority();
string certificateAuthorityId = "";
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.CreateCertificateAuthorityAsync(parent, certificateAuthority, certificateAuthorityId);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceCreateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
CreateCertificateAuthorityAsync(LocationName, CertificateAuthority, String, CancellationToken)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> CreateCertificateAuthorityAsync(LocationName parent, CertificateAuthority certificateAuthority, string certificateAuthorityId, CancellationToken cancellationToken)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
parent | LocationName Required. The resource name of the location associated with the
[CertificateAuthorities][google.cloud.security.privateca.v1beta1.CertificateAuthority], in the format
|
certificateAuthority | CertificateAuthority Required. A [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] with initial field values. |
certificateAuthorityId | String Required. It must be unique within a location and match the regular
expression |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
CertificateAuthority certificateAuthority = new CertificateAuthority();
string certificateAuthorityId = "";
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.CreateCertificateAuthorityAsync(parent, certificateAuthority, certificateAuthorityId);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceCreateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
CreateCertificateAuthorityAsync(CreateCertificateAuthorityRequest, CallSettings)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> CreateCertificateAuthorityAsync(CreateCertificateAuthorityRequest request, CallSettings callSettings = null)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
request | CreateCertificateAuthorityRequest The request object containing all of the parameters for the API call. |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
CreateCertificateAuthorityRequest request = new CreateCertificateAuthorityRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
CertificateAuthorityId = "",
CertificateAuthority = new CertificateAuthority(),
RequestId = "",
};
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.CreateCertificateAuthorityAsync(request);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceCreateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
CreateCertificateAuthorityAsync(CreateCertificateAuthorityRequest, CancellationToken)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> CreateCertificateAuthorityAsync(CreateCertificateAuthorityRequest request, CancellationToken cancellationToken)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
request | CreateCertificateAuthorityRequest The request object containing all of the parameters for the API call. |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
CreateCertificateAuthorityRequest request = new CreateCertificateAuthorityRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
CertificateAuthorityId = "",
CertificateAuthority = new CertificateAuthority(),
RequestId = "",
};
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.CreateCertificateAuthorityAsync(request);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceCreateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
CreateCertificateAuthorityAsync(String, CertificateAuthority, String, CallSettings)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> CreateCertificateAuthorityAsync(string parent, CertificateAuthority certificateAuthority, string certificateAuthorityId, CallSettings callSettings = null)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
parent | String Required. The resource name of the location associated with the
[CertificateAuthorities][google.cloud.security.privateca.v1beta1.CertificateAuthority], in the format
|
certificateAuthority | CertificateAuthority Required. A [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] with initial field values. |
certificateAuthorityId | String Required. It must be unique within a location and match the regular
expression |
callSettings | CallSettings If not null, applies overrides to this RPC call. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |
// Create client
CertificateAuthorityServiceClient certificateAuthorityServiceClient = await CertificateAuthorityServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
CertificateAuthority certificateAuthority = new CertificateAuthority();
string certificateAuthorityId = "";
// Make the request
Operation<CertificateAuthority, OperationMetadata> response = await certificateAuthorityServiceClient.CreateCertificateAuthorityAsync(parent, certificateAuthority, certificateAuthorityId);
// Poll until the returned long-running operation is complete
Operation<CertificateAuthority, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
CertificateAuthority result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<CertificateAuthority, OperationMetadata> retrievedResponse = await certificateAuthorityServiceClient.PollOnceCreateCertificateAuthorityAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
CertificateAuthority retrievedResult = retrievedResponse.Result;
}
CreateCertificateAuthorityAsync(String, CertificateAuthority, String, CancellationToken)
public virtual Task<Operation<CertificateAuthority, OperationMetadata>> CreateCertificateAuthorityAsync(string parent, CertificateAuthority certificateAuthority, string certificateAuthorityId, CancellationToken cancellationToken)
Create a new [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] in a given Project and Location.
Parameters | |
---|---|
Name | Description |
parent | String Required. The resource name of the location associated with the
[CertificateAuthorities][google.cloud.security.privateca.v1beta1.CertificateAuthority], in the format
|
certificateAuthority | CertificateAuthority Required. A [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority] with initial field values. |
certificateAuthorityId | String Required. It must be unique within a location and match the regular
expression |
cancellationToken | CancellationToken A CancellationToken to use for this RPC. |
Returns | |
---|---|
Type | Description |
Task<Operation<CertificateAuthority, OperationMetadata>> | A Task containing the RPC response. |