Binary Authorization v1 API - Class BinauthzManagementServiceV1.BinauthzManagementServiceV1Client (2.2.0)

public class BinauthzManagementServiceV1.BinauthzManagementServiceV1Client : ClientBase<BinauthzManagementServiceV1.BinauthzManagementServiceV1Client>

Reference documentation and code samples for the Binary Authorization v1 API class BinauthzManagementServiceV1.BinauthzManagementServiceV1Client.

Client for BinauthzManagementServiceV1

Inheritance

object > ClientBase > ClientBaseBinauthzManagementServiceV1BinauthzManagementServiceV1Client > BinauthzManagementServiceV1.BinauthzManagementServiceV1Client

Namespace

Google.Cloud.BinaryAuthorization.V1

Assembly

Google.Cloud.BinaryAuthorization.V1.dll

Constructors

BinauthzManagementServiceV1Client()

protected BinauthzManagementServiceV1Client()

Protected parameterless constructor to allow creation of test doubles.

BinauthzManagementServiceV1Client(CallInvoker)

public BinauthzManagementServiceV1Client(CallInvoker callInvoker)

Creates a new client for BinauthzManagementServiceV1 that uses a custom CallInvoker.

Parameter
NameDescription
callInvokerCallInvoker

The callInvoker to use to make remote calls.

BinauthzManagementServiceV1Client(ChannelBase)

public BinauthzManagementServiceV1Client(ChannelBase channel)

Creates a new client for BinauthzManagementServiceV1

Parameter
NameDescription
channelChannelBase

The channel to use to make remote calls.

BinauthzManagementServiceV1Client(ClientBaseConfiguration)

protected BinauthzManagementServiceV1Client(ClientBase.ClientBaseConfiguration configuration)

Protected constructor to allow creation of configured clients.

Parameter
NameDescription
configurationClientBaseClientBaseConfiguration

The client configuration.

Methods

CreateAttestor(CreateAttestorRequest, CallOptions)

public virtual Attestor CreateAttestor(CreateAttestorRequest request, CallOptions options)

Creates an [attestor][google.cloud.binaryauthorization.v1.Attestor], and returns a copy of the new [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the [attestor][google.cloud.binaryauthorization.v1.Attestor] already exists.

Parameters
NameDescription
requestCreateAttestorRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Attestor

The response received from the server.

CreateAttestor(CreateAttestorRequest, Metadata, DateTime?, CancellationToken)

public virtual Attestor CreateAttestor(CreateAttestorRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Creates an [attestor][google.cloud.binaryauthorization.v1.Attestor], and returns a copy of the new [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the [attestor][google.cloud.binaryauthorization.v1.Attestor] already exists.

Parameters
NameDescription
requestCreateAttestorRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
Attestor

The response received from the server.

CreateAttestorAsync(CreateAttestorRequest, CallOptions)

public virtual AsyncUnaryCall<Attestor> CreateAttestorAsync(CreateAttestorRequest request, CallOptions options)

Creates an [attestor][google.cloud.binaryauthorization.v1.Attestor], and returns a copy of the new [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the [attestor][google.cloud.binaryauthorization.v1.Attestor] already exists.

Parameters
NameDescription
requestCreateAttestorRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallAttestor

The call object.

CreateAttestorAsync(CreateAttestorRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<Attestor> CreateAttestorAsync(CreateAttestorRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Creates an [attestor][google.cloud.binaryauthorization.v1.Attestor], and returns a copy of the new [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the [attestor][google.cloud.binaryauthorization.v1.Attestor] already exists.

Parameters
NameDescription
requestCreateAttestorRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
AsyncUnaryCallAttestor

The call object.

DeleteAttestor(DeleteAttestorRequest, CallOptions)

public virtual Empty DeleteAttestor(DeleteAttestorRequest request, CallOptions options)

Deletes an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestDeleteAttestorRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Empty

The response received from the server.

DeleteAttestor(DeleteAttestorRequest, Metadata, DateTime?, CancellationToken)

public virtual Empty DeleteAttestor(DeleteAttestorRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Deletes an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestDeleteAttestorRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
Empty

The response received from the server.

DeleteAttestorAsync(DeleteAttestorRequest, CallOptions)

public virtual AsyncUnaryCall<Empty> DeleteAttestorAsync(DeleteAttestorRequest request, CallOptions options)

Deletes an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestDeleteAttestorRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallEmpty

The call object.

DeleteAttestorAsync(DeleteAttestorRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<Empty> DeleteAttestorAsync(DeleteAttestorRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Deletes an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestDeleteAttestorRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
AsyncUnaryCallEmpty

The call object.

GetAttestor(GetAttestorRequest, CallOptions)

public virtual Attestor GetAttestor(GetAttestorRequest request, CallOptions options)

Gets an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestGetAttestorRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Attestor

The response received from the server.

GetAttestor(GetAttestorRequest, Metadata, DateTime?, CancellationToken)

public virtual Attestor GetAttestor(GetAttestorRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Gets an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestGetAttestorRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
Attestor

The response received from the server.

GetAttestorAsync(GetAttestorRequest, CallOptions)

public virtual AsyncUnaryCall<Attestor> GetAttestorAsync(GetAttestorRequest request, CallOptions options)

Gets an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestGetAttestorRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallAttestor

The call object.

GetAttestorAsync(GetAttestorRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<Attestor> GetAttestorAsync(GetAttestorRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Gets an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestGetAttestorRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
AsyncUnaryCallAttestor

The call object.

GetPolicy(GetPolicyRequest, CallOptions)

public virtual Policy GetPolicy(GetPolicyRequest request, CallOptions options)

A [policy][google.cloud.binaryauthorization.v1.Policy] specifies the [attestors][google.cloud.binaryauthorization.v1.Attestor] that must attest to a container image, before the project is allowed to deploy that image. There is at most one policy per project. All image admission requests are permitted if a project has no policy.

Gets the [policy][google.cloud.binaryauthorization.v1.Policy] for this project. Returns a default [policy][google.cloud.binaryauthorization.v1.Policy] if the project does not have one.

Parameters
NameDescription
requestGetPolicyRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Policy

The response received from the server.

GetPolicy(GetPolicyRequest, Metadata, DateTime?, CancellationToken)

public virtual Policy GetPolicy(GetPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

A [policy][google.cloud.binaryauthorization.v1.Policy] specifies the [attestors][google.cloud.binaryauthorization.v1.Attestor] that must attest to a container image, before the project is allowed to deploy that image. There is at most one policy per project. All image admission requests are permitted if a project has no policy.

Gets the [policy][google.cloud.binaryauthorization.v1.Policy] for this project. Returns a default [policy][google.cloud.binaryauthorization.v1.Policy] if the project does not have one.

Parameters
NameDescription
requestGetPolicyRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
Policy

The response received from the server.

GetPolicyAsync(GetPolicyRequest, CallOptions)

public virtual AsyncUnaryCall<Policy> GetPolicyAsync(GetPolicyRequest request, CallOptions options)

A [policy][google.cloud.binaryauthorization.v1.Policy] specifies the [attestors][google.cloud.binaryauthorization.v1.Attestor] that must attest to a container image, before the project is allowed to deploy that image. There is at most one policy per project. All image admission requests are permitted if a project has no policy.

Gets the [policy][google.cloud.binaryauthorization.v1.Policy] for this project. Returns a default [policy][google.cloud.binaryauthorization.v1.Policy] if the project does not have one.

Parameters
NameDescription
requestGetPolicyRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallPolicy

The call object.

GetPolicyAsync(GetPolicyRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<Policy> GetPolicyAsync(GetPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

A [policy][google.cloud.binaryauthorization.v1.Policy] specifies the [attestors][google.cloud.binaryauthorization.v1.Attestor] that must attest to a container image, before the project is allowed to deploy that image. There is at most one policy per project. All image admission requests are permitted if a project has no policy.

Gets the [policy][google.cloud.binaryauthorization.v1.Policy] for this project. Returns a default [policy][google.cloud.binaryauthorization.v1.Policy] if the project does not have one.

Parameters
NameDescription
requestGetPolicyRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
AsyncUnaryCallPolicy

The call object.

ListAttestors(ListAttestorsRequest, CallOptions)

public virtual ListAttestorsResponse ListAttestors(ListAttestorsRequest request, CallOptions options)

Lists [attestors][google.cloud.binaryauthorization.v1.Attestor]. Returns INVALID_ARGUMENT if the project does not exist.

Parameters
NameDescription
requestListAttestorsRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
ListAttestorsResponse

The response received from the server.

ListAttestors(ListAttestorsRequest, Metadata, DateTime?, CancellationToken)

public virtual ListAttestorsResponse ListAttestors(ListAttestorsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Lists [attestors][google.cloud.binaryauthorization.v1.Attestor]. Returns INVALID_ARGUMENT if the project does not exist.

Parameters
NameDescription
requestListAttestorsRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
ListAttestorsResponse

The response received from the server.

ListAttestorsAsync(ListAttestorsRequest, CallOptions)

public virtual AsyncUnaryCall<ListAttestorsResponse> ListAttestorsAsync(ListAttestorsRequest request, CallOptions options)

Lists [attestors][google.cloud.binaryauthorization.v1.Attestor]. Returns INVALID_ARGUMENT if the project does not exist.

Parameters
NameDescription
requestListAttestorsRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallListAttestorsResponse

The call object.

ListAttestorsAsync(ListAttestorsRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<ListAttestorsResponse> ListAttestorsAsync(ListAttestorsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Lists [attestors][google.cloud.binaryauthorization.v1.Attestor]. Returns INVALID_ARGUMENT if the project does not exist.

Parameters
NameDescription
requestListAttestorsRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
AsyncUnaryCallListAttestorsResponse

The call object.

NewInstance(ClientBaseConfiguration)

protected override BinauthzManagementServiceV1.BinauthzManagementServiceV1Client NewInstance(ClientBase.ClientBaseConfiguration configuration)

Creates a new instance of client from given ClientBaseConfiguration.

Parameter
NameDescription
configurationClientBaseClientBaseConfiguration
Returns
TypeDescription
BinauthzManagementServiceV1BinauthzManagementServiceV1Client
Overrides

UpdateAttestor(UpdateAttestorRequest, CallOptions)

public virtual Attestor UpdateAttestor(UpdateAttestorRequest request, CallOptions options)

Updates an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestUpdateAttestorRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Attestor

The response received from the server.

UpdateAttestor(UpdateAttestorRequest, Metadata, DateTime?, CancellationToken)

public virtual Attestor UpdateAttestor(UpdateAttestorRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Updates an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestUpdateAttestorRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
Attestor

The response received from the server.

UpdateAttestorAsync(UpdateAttestorRequest, CallOptions)

public virtual AsyncUnaryCall<Attestor> UpdateAttestorAsync(UpdateAttestorRequest request, CallOptions options)

Updates an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestUpdateAttestorRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallAttestor

The call object.

UpdateAttestorAsync(UpdateAttestorRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<Attestor> UpdateAttestorAsync(UpdateAttestorRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Updates an [attestor][google.cloud.binaryauthorization.v1.Attestor]. Returns NOT_FOUND if the [attestor][google.cloud.binaryauthorization.v1.Attestor] does not exist.

Parameters
NameDescription
requestUpdateAttestorRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
AsyncUnaryCallAttestor

The call object.

UpdatePolicy(UpdatePolicyRequest, CallOptions)

public virtual Policy UpdatePolicy(UpdatePolicyRequest request, CallOptions options)

Creates or updates a project's [policy][google.cloud.binaryauthorization.v1.Policy], and returns a copy of the new [policy][google.cloud.binaryauthorization.v1.Policy]. A policy is always updated as a whole, to avoid race conditions with concurrent policy enforcement (or management!) requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed.

Parameters
NameDescription
requestUpdatePolicyRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
Policy

The response received from the server.

UpdatePolicy(UpdatePolicyRequest, Metadata, DateTime?, CancellationToken)

public virtual Policy UpdatePolicy(UpdatePolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Creates or updates a project's [policy][google.cloud.binaryauthorization.v1.Policy], and returns a copy of the new [policy][google.cloud.binaryauthorization.v1.Policy]. A policy is always updated as a whole, to avoid race conditions with concurrent policy enforcement (or management!) requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed.

Parameters
NameDescription
requestUpdatePolicyRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
Policy

The response received from the server.

UpdatePolicyAsync(UpdatePolicyRequest, CallOptions)

public virtual AsyncUnaryCall<Policy> UpdatePolicyAsync(UpdatePolicyRequest request, CallOptions options)

Creates or updates a project's [policy][google.cloud.binaryauthorization.v1.Policy], and returns a copy of the new [policy][google.cloud.binaryauthorization.v1.Policy]. A policy is always updated as a whole, to avoid race conditions with concurrent policy enforcement (or management!) requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed.

Parameters
NameDescription
requestUpdatePolicyRequest

The request to send to the server.

optionsCallOptions

The options for the call.

Returns
TypeDescription
AsyncUnaryCallPolicy

The call object.

UpdatePolicyAsync(UpdatePolicyRequest, Metadata, DateTime?, CancellationToken)

public virtual AsyncUnaryCall<Policy> UpdatePolicyAsync(UpdatePolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Creates or updates a project's [policy][google.cloud.binaryauthorization.v1.Policy], and returns a copy of the new [policy][google.cloud.binaryauthorization.v1.Policy]. A policy is always updated as a whole, to avoid race conditions with concurrent policy enforcement (or management!) requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed.

Parameters
NameDescription
requestUpdatePolicyRequest

The request to send to the server.

headersMetadata

The initial metadata to send with the call. This parameter is optional.

deadlineDateTime

An optional deadline for the call. The call will be cancelled if deadline is hit.

cancellationTokenCancellationToken

An optional token for canceling the call.

Returns
TypeDescription
AsyncUnaryCallPolicy

The call object.