@google-cloud/binary-authorization
Advanced tools
Comparing version 1.5.0 to 1.5.1
@@ -110,2 +110,26 @@ /// <reference types="node" /> | ||
getProjectId(callback: Callback<string, undefined, undefined>): void; | ||
/** | ||
* A {@link google.cloud.binaryauthorization.v1.Policy|policy} specifies the {@link google.cloud.binaryauthorization.v1.Attestor|attestors} 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 {@link google.cloud.binaryauthorization.v1.Policy|policy} for this project. Returns a default | ||
* {@link google.cloud.binaryauthorization.v1.Policy|policy} if the project does not have one. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The resource name of the {@link google.cloud.binaryauthorization.v1.Policy|policy} to retrieve, | ||
* in the format `projects/* /policy`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1/binauthz_management_service_v1.get_policy.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_BinauthzManagementServiceV1_GetPolicy_async | ||
*/ | ||
getPolicy(request?: protos.google.cloud.binaryauthorization.v1.IGetPolicyRequest, options?: CallOptions): Promise<[ | ||
@@ -118,2 +142,25 @@ protos.google.cloud.binaryauthorization.v1.IPolicy, | ||
getPolicy(request: protos.google.cloud.binaryauthorization.v1.IGetPolicyRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1.IPolicy, protos.google.cloud.binaryauthorization.v1.IGetPolicyRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Creates or updates a project's {@link google.cloud.binaryauthorization.v1.Policy|policy}, and returns a copy of the | ||
* new {@link google.cloud.binaryauthorization.v1.Policy|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. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {google.cloud.binaryauthorization.v1.Policy} request.policy | ||
* Required. A new or updated {@link google.cloud.binaryauthorization.v1.Policy|policy} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1.Policy.name|policy name} field with the resource name in | ||
* the request URL, in the format `projects/* /policy`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1/binauthz_management_service_v1.update_policy.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_BinauthzManagementServiceV1_UpdatePolicy_async | ||
*/ | ||
updatePolicy(request?: protos.google.cloud.binaryauthorization.v1.IUpdatePolicyRequest, options?: CallOptions): Promise<[ | ||
@@ -126,2 +173,28 @@ protos.google.cloud.binaryauthorization.v1.IPolicy, | ||
updatePolicy(request: protos.google.cloud.binaryauthorization.v1.IUpdatePolicyRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1.IPolicy, protos.google.cloud.binaryauthorization.v1.IUpdatePolicyRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Creates an {@link google.cloud.binaryauthorization.v1.Attestor|attestor}, and returns a copy of the new | ||
* {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. Returns NOT_FOUND if the project does not exist, | ||
* INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the | ||
* {@link google.cloud.binaryauthorization.v1.Attestor|attestor} already exists. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.parent | ||
* Required. The parent of this {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. | ||
* @param {string} request.attestorId | ||
* Required. The {@link google.cloud.binaryauthorization.v1.Attestor|attestors} ID. | ||
* @param {google.cloud.binaryauthorization.v1.Attestor} request.attestor | ||
* Required. The initial {@link google.cloud.binaryauthorization.v1.Attestor|attestor} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1.Attestor.name|attestor name} field with the resource name, | ||
* in the format `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1/binauthz_management_service_v1.create_attestor.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_BinauthzManagementServiceV1_CreateAttestor_async | ||
*/ | ||
createAttestor(request?: protos.google.cloud.binaryauthorization.v1.ICreateAttestorRequest, options?: CallOptions): Promise<[ | ||
@@ -134,2 +207,21 @@ protos.google.cloud.binaryauthorization.v1.IAttestor, | ||
createAttestor(request: protos.google.cloud.binaryauthorization.v1.ICreateAttestorRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1.IAttestor, protos.google.cloud.binaryauthorization.v1.ICreateAttestorRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Gets an {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. | ||
* Returns NOT_FOUND if the {@link google.cloud.binaryauthorization.v1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The name of the {@link google.cloud.binaryauthorization.v1.Attestor|attestor} to retrieve, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1/binauthz_management_service_v1.get_attestor.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_BinauthzManagementServiceV1_GetAttestor_async | ||
*/ | ||
getAttestor(request?: protos.google.cloud.binaryauthorization.v1.IGetAttestorRequest, options?: CallOptions): Promise<[ | ||
@@ -142,2 +234,22 @@ protos.google.cloud.binaryauthorization.v1.IAttestor, | ||
getAttestor(request: protos.google.cloud.binaryauthorization.v1.IGetAttestorRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1.IAttestor, protos.google.cloud.binaryauthorization.v1.IGetAttestorRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Updates an {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. | ||
* Returns NOT_FOUND if the {@link google.cloud.binaryauthorization.v1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {google.cloud.binaryauthorization.v1.Attestor} request.attestor | ||
* Required. The updated {@link google.cloud.binaryauthorization.v1.Attestor|attestor} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1.Attestor.name|attestor name} field with the resource name | ||
* in the request URL, in the format `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1/binauthz_management_service_v1.update_attestor.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_BinauthzManagementServiceV1_UpdateAttestor_async | ||
*/ | ||
updateAttestor(request?: protos.google.cloud.binaryauthorization.v1.IUpdateAttestorRequest, options?: CallOptions): Promise<[ | ||
@@ -150,2 +262,21 @@ protos.google.cloud.binaryauthorization.v1.IAttestor, | ||
updateAttestor(request: protos.google.cloud.binaryauthorization.v1.IUpdateAttestorRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1.IAttestor, protos.google.cloud.binaryauthorization.v1.IUpdateAttestorRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Deletes an {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. Returns NOT_FOUND if the | ||
* {@link google.cloud.binaryauthorization.v1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The name of the {@link google.cloud.binaryauthorization.v1.Attestor|attestors} to delete, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Empty]{@link google.protobuf.Empty}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1/binauthz_management_service_v1.delete_attestor.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_BinauthzManagementServiceV1_DeleteAttestor_async | ||
*/ | ||
deleteAttestor(request?: protos.google.cloud.binaryauthorization.v1.IDeleteAttestorRequest, options?: CallOptions): Promise<[ | ||
@@ -158,2 +289,31 @@ protos.google.protobuf.IEmpty, | ||
deleteAttestor(request: protos.google.cloud.binaryauthorization.v1.IDeleteAttestorRequest, callback: Callback<protos.google.protobuf.IEmpty, protos.google.cloud.binaryauthorization.v1.IDeleteAttestorRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Lists {@link google.cloud.binaryauthorization.v1.Attestor|attestors}. | ||
* Returns INVALID_ARGUMENT if the project does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.parent | ||
* Required. The resource name of the project associated with the | ||
* {@link google.cloud.binaryauthorization.v1.Attestor|attestors}, in the format `projects/*`. | ||
* @param {number} request.pageSize | ||
* Requested page size. The server may return fewer results than requested. If | ||
* unspecified, the server will pick an appropriate default. | ||
* @param {string} request.pageToken | ||
* A token identifying a page of results the server should return. Typically, | ||
* this is the value of {@link google.cloud.binaryauthorization.v1.ListAttestorsResponse.next_page_token|ListAttestorsResponse.next_page_token} returned | ||
* from the previous call to the `ListAttestors` method. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is Array of [Attestor]{@link google.cloud.binaryauthorization.v1.Attestor}. | ||
* The client library will perform auto-pagination by default: it will call the API as many | ||
* times as needed and will merge results from all the pages into this array. | ||
* Note that it can affect your quota. | ||
* We recommend using `listAttestorsAsync()` | ||
* method described below for async iteration which you can stop as needed. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination) | ||
* for more details and examples. | ||
*/ | ||
listAttestors(request?: protos.google.cloud.binaryauthorization.v1.IListAttestorsRequest, options?: CallOptions): Promise<[ | ||
@@ -219,7 +379,4 @@ protos.google.cloud.binaryauthorization.v1.IAttestor[], | ||
* for more details and examples. | ||
* @example | ||
* const iterable = client.listAttestorsAsync(request); | ||
* for await (const response of iterable) { | ||
* // process response | ||
* } | ||
* @example <caption>include:samples/generated/v1/binauthz_management_service_v1.list_attestors.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_BinauthzManagementServiceV1_ListAttestors_async | ||
*/ | ||
@@ -226,0 +383,0 @@ listAttestorsAsync(request?: protos.google.cloud.binaryauthorization.v1.IListAttestorsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.binaryauthorization.v1.IAttestor>; |
"use strict"; | ||
// Copyright 2021 Google LLC | ||
// Copyright 2022 Google LLC | ||
// | ||
@@ -249,26 +249,2 @@ // Licensed under the Apache License, Version 2.0 (the "License"); | ||
} | ||
/** | ||
* A {@link google.cloud.binaryauthorization.v1.Policy|policy} specifies the {@link google.cloud.binaryauthorization.v1.Attestor|attestors} 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 {@link google.cloud.binaryauthorization.v1.Policy|policy} for this project. Returns a default | ||
* {@link google.cloud.binaryauthorization.v1.Policy|policy} if the project does not have one. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The resource name of the {@link google.cloud.binaryauthorization.v1.Policy|policy} to retrieve, | ||
* in the format `projects/* /policy`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.getPolicy(request); | ||
*/ | ||
getPolicy(request, optionsOrCallback, callback) { | ||
@@ -294,25 +270,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Creates or updates a project's {@link google.cloud.binaryauthorization.v1.Policy|policy}, and returns a copy of the | ||
* new {@link google.cloud.binaryauthorization.v1.Policy|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. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {google.cloud.binaryauthorization.v1.Policy} request.policy | ||
* Required. A new or updated {@link google.cloud.binaryauthorization.v1.Policy|policy} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1.Policy.name|policy name} field with the resource name in | ||
* the request URL, in the format `projects/* /policy`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.updatePolicy(request); | ||
*/ | ||
updatePolicy(request, optionsOrCallback, callback) { | ||
@@ -338,28 +291,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Creates an {@link google.cloud.binaryauthorization.v1.Attestor|attestor}, and returns a copy of the new | ||
* {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. Returns NOT_FOUND if the project does not exist, | ||
* INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the | ||
* {@link google.cloud.binaryauthorization.v1.Attestor|attestor} already exists. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.parent | ||
* Required. The parent of this {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. | ||
* @param {string} request.attestorId | ||
* Required. The {@link google.cloud.binaryauthorization.v1.Attestor|attestors} ID. | ||
* @param {google.cloud.binaryauthorization.v1.Attestor} request.attestor | ||
* Required. The initial {@link google.cloud.binaryauthorization.v1.Attestor|attestor} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1.Attestor.name|attestor name} field with the resource name, | ||
* in the format `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.createAttestor(request); | ||
*/ | ||
createAttestor(request, optionsOrCallback, callback) { | ||
@@ -385,21 +312,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Gets an {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. | ||
* Returns NOT_FOUND if the {@link google.cloud.binaryauthorization.v1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The name of the {@link google.cloud.binaryauthorization.v1.Attestor|attestor} to retrieve, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.getAttestor(request); | ||
*/ | ||
getAttestor(request, optionsOrCallback, callback) { | ||
@@ -425,22 +333,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Updates an {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. | ||
* Returns NOT_FOUND if the {@link google.cloud.binaryauthorization.v1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {google.cloud.binaryauthorization.v1.Attestor} request.attestor | ||
* Required. The updated {@link google.cloud.binaryauthorization.v1.Attestor|attestor} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1.Attestor.name|attestor name} field with the resource name | ||
* in the request URL, in the format `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.updateAttestor(request); | ||
*/ | ||
updateAttestor(request, optionsOrCallback, callback) { | ||
@@ -466,21 +354,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Deletes an {@link google.cloud.binaryauthorization.v1.Attestor|attestor}. Returns NOT_FOUND if the | ||
* {@link google.cloud.binaryauthorization.v1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The name of the {@link google.cloud.binaryauthorization.v1.Attestor|attestors} to delete, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Empty]{@link google.protobuf.Empty}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.deleteAttestor(request); | ||
*/ | ||
deleteAttestor(request, optionsOrCallback, callback) { | ||
@@ -506,31 +375,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Lists {@link google.cloud.binaryauthorization.v1.Attestor|attestors}. | ||
* Returns INVALID_ARGUMENT if the project does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.parent | ||
* Required. The resource name of the project associated with the | ||
* {@link google.cloud.binaryauthorization.v1.Attestor|attestors}, in the format `projects/*`. | ||
* @param {number} request.pageSize | ||
* Requested page size. The server may return fewer results than requested. If | ||
* unspecified, the server will pick an appropriate default. | ||
* @param {string} request.pageToken | ||
* A token identifying a page of results the server should return. Typically, | ||
* this is the value of {@link google.cloud.binaryauthorization.v1.ListAttestorsResponse.next_page_token|ListAttestorsResponse.next_page_token} returned | ||
* from the previous call to the `ListAttestors` method. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is Array of [Attestor]{@link google.cloud.binaryauthorization.v1.Attestor}. | ||
* The client library will perform auto-pagination by default: it will call the API as many | ||
* times as needed and will merge results from all the pages into this array. | ||
* Note that it can affect your quota. | ||
* We recommend using `listAttestorsAsync()` | ||
* method described below for async iteration which you can stop as needed. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination) | ||
* for more details and examples. | ||
*/ | ||
listAttestors(request, optionsOrCallback, callback) { | ||
@@ -622,7 +462,4 @@ request = request || {}; | ||
* for more details and examples. | ||
* @example | ||
* const iterable = client.listAttestorsAsync(request); | ||
* for await (const response of iterable) { | ||
* // process response | ||
* } | ||
* @example <caption>include:samples/generated/v1/binauthz_management_service_v1.list_attestors.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_BinauthzManagementServiceV1_ListAttestors_async | ||
*/ | ||
@@ -638,3 +475,2 @@ listAttestorsAsync(request, options) { | ||
}); | ||
options = options || {}; | ||
const defaultCallSettings = this._defaults['listAttestors']; | ||
@@ -641,0 +477,0 @@ const callSettings = defaultCallSettings.merge(options); |
"use strict"; | ||
// Copyright 2021 Google LLC | ||
// Copyright 2022 Google LLC | ||
// | ||
@@ -4,0 +4,0 @@ // Licensed under the Apache License, Version 2.0 (the "License"); |
@@ -102,2 +102,20 @@ import * as gax from 'google-gax'; | ||
getProjectId(callback: Callback<string, undefined, undefined>): void; | ||
/** | ||
* Gets the current system policy in the specified location. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The resource name, in the format `locations/* /policy`. | ||
* Note that the system policy is not associated with a project. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1/system_policy_v1.get_system_policy.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_SystemPolicyV1_GetSystemPolicy_async | ||
*/ | ||
getSystemPolicy(request?: protos.google.cloud.binaryauthorization.v1.IGetSystemPolicyRequest, options?: CallOptions): Promise<[ | ||
@@ -104,0 +122,0 @@ protos.google.cloud.binaryauthorization.v1.IPolicy, |
"use strict"; | ||
// Copyright 2021 Google LLC | ||
// Copyright 2022 Google LLC | ||
// | ||
@@ -228,20 +228,2 @@ // Licensed under the Apache License, Version 2.0 (the "License"); | ||
} | ||
/** | ||
* Gets the current system policy in the specified location. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The resource name, in the format `locations/* /policy`. | ||
* Note that the system policy is not associated with a project. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.getSystemPolicy(request); | ||
*/ | ||
getSystemPolicy(request, optionsOrCallback, callback) { | ||
@@ -248,0 +230,0 @@ request = request || {}; |
@@ -102,2 +102,33 @@ import * as gax from 'google-gax'; | ||
getProjectId(callback: Callback<string, undefined, undefined>): void; | ||
/** | ||
* Returns whether the given Attestation for the given image URI | ||
* was signed by the given Attestor | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.attestor | ||
* Required. The resource name of the {@link google.cloud.binaryauthorization.v1.Attestor|Attestor} of the | ||
* {@link grafeas.v1.Occurrence|occurrence}, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {grafeas.v1.AttestationOccurrence} request.attestation | ||
* Required. An {@link grafeas.v1.AttestationOccurrence|AttestationOccurrence} to | ||
* be checked that it can be verified by the Attestor. It does not have to be | ||
* an existing entity in Container Analysis. It must otherwise be a valid | ||
* AttestationOccurrence. | ||
* @param {string} request.occurrenceNote | ||
* Required. The resource name of the {@link grafeas.v1.Note|Note} to which the | ||
* containing {@link grafeas.v1.Occurrence|Occurrence} is associated. | ||
* @param {string} request.occurrenceResourceUri | ||
* Required. The URI of the artifact (e.g. container image) that is the | ||
* subject of the containing {@link grafeas.v1.Occurrence|Occurrence}. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [ValidateAttestationOccurrenceResponse]{@link google.cloud.binaryauthorization.v1.ValidateAttestationOccurrenceResponse}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1/validation_helper_v1.validate_attestation_occurrence.js</caption> | ||
* region_tag:binaryauthorization_v1_generated_ValidationHelperV1_ValidateAttestationOccurrence_async | ||
*/ | ||
validateAttestationOccurrence(request?: protos.google.cloud.binaryauthorization.v1.IValidateAttestationOccurrenceRequest, options?: CallOptions): Promise<[ | ||
@@ -104,0 +135,0 @@ protos.google.cloud.binaryauthorization.v1.IValidateAttestationOccurrenceResponse, |
"use strict"; | ||
// Copyright 2021 Google LLC | ||
// Copyright 2022 Google LLC | ||
// | ||
@@ -228,33 +228,2 @@ // Licensed under the Apache License, Version 2.0 (the "License"); | ||
} | ||
/** | ||
* Returns whether the given Attestation for the given image URI | ||
* was signed by the given Attestor | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.attestor | ||
* Required. The resource name of the {@link google.cloud.binaryauthorization.v1.Attestor|Attestor} of the | ||
* {@link grafeas.v1.Occurrence|occurrence}, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {grafeas.v1.AttestationOccurrence} request.attestation | ||
* Required. An {@link grafeas.v1.AttestationOccurrence|AttestationOccurrence} to | ||
* be checked that it can be verified by the Attestor. It does not have to be | ||
* an existing entity in Container Analysis. It must otherwise be a valid | ||
* AttestationOccurrence. | ||
* @param {string} request.occurrenceNote | ||
* Required. The resource name of the {@link grafeas.v1.Note|Note} to which the | ||
* containing {@link grafeas.v1.Occurrence|Occurrence} is associated. | ||
* @param {string} request.occurrenceResourceUri | ||
* Required. The URI of the artifact (e.g. container image) that is the | ||
* subject of the containing {@link grafeas.v1.Occurrence|Occurrence}. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [ValidateAttestationOccurrenceResponse]{@link google.cloud.binaryauthorization.v1.ValidateAttestationOccurrenceResponse}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.validateAttestationOccurrence(request); | ||
*/ | ||
validateAttestationOccurrence(request, optionsOrCallback, callback) { | ||
@@ -261,0 +230,0 @@ request = request || {}; |
@@ -110,2 +110,26 @@ /// <reference types="node" /> | ||
getProjectId(callback: Callback<string, undefined, undefined>): void; | ||
/** | ||
* A {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} specifies the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors} 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 {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} for this project. Returns a default | ||
* {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} if the project does not have one. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The resource name of the {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} to retrieve, | ||
* in the format `projects/* /policy`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1beta1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1beta1/binauthz_management_service_v1_beta1.get_policy.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_BinauthzManagementServiceV1Beta1_GetPolicy_async | ||
*/ | ||
getPolicy(request?: protos.google.cloud.binaryauthorization.v1beta1.IGetPolicyRequest, options?: CallOptions): Promise<[ | ||
@@ -118,2 +142,25 @@ protos.google.cloud.binaryauthorization.v1beta1.IPolicy, | ||
getPolicy(request: protos.google.cloud.binaryauthorization.v1beta1.IGetPolicyRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1beta1.IPolicy, protos.google.cloud.binaryauthorization.v1beta1.IGetPolicyRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Creates or updates a project's {@link google.cloud.binaryauthorization.v1beta1.Policy|policy}, and returns a copy of the | ||
* new {@link google.cloud.binaryauthorization.v1beta1.Policy|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. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {google.cloud.binaryauthorization.v1beta1.Policy} request.policy | ||
* Required. A new or updated {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1beta1.Policy.name|policy name} field with the resource name in | ||
* the request URL, in the format `projects/* /policy`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1beta1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1beta1/binauthz_management_service_v1_beta1.update_policy.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_BinauthzManagementServiceV1Beta1_UpdatePolicy_async | ||
*/ | ||
updatePolicy(request?: protos.google.cloud.binaryauthorization.v1beta1.IUpdatePolicyRequest, options?: CallOptions): Promise<[ | ||
@@ -126,2 +173,28 @@ protos.google.cloud.binaryauthorization.v1beta1.IPolicy, | ||
updatePolicy(request: protos.google.cloud.binaryauthorization.v1beta1.IUpdatePolicyRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1beta1.IPolicy, protos.google.cloud.binaryauthorization.v1beta1.IUpdatePolicyRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Creates an {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}, and returns a copy of the new | ||
* {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. Returns NOT_FOUND if the project does not exist, | ||
* INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the | ||
* {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} already exists. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.parent | ||
* Required. The parent of this {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. | ||
* @param {string} request.attestorId | ||
* Required. The {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors} ID. | ||
* @param {google.cloud.binaryauthorization.v1beta1.Attestor} request.attestor | ||
* Required. The initial {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1beta1.Attestor.name|attestor name} field with the resource name, | ||
* in the format `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1beta1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1beta1/binauthz_management_service_v1_beta1.create_attestor.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_BinauthzManagementServiceV1Beta1_CreateAttestor_async | ||
*/ | ||
createAttestor(request?: protos.google.cloud.binaryauthorization.v1beta1.ICreateAttestorRequest, options?: CallOptions): Promise<[ | ||
@@ -134,2 +207,21 @@ protos.google.cloud.binaryauthorization.v1beta1.IAttestor, | ||
createAttestor(request: protos.google.cloud.binaryauthorization.v1beta1.ICreateAttestorRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1beta1.IAttestor, protos.google.cloud.binaryauthorization.v1beta1.ICreateAttestorRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Gets an {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. | ||
* Returns NOT_FOUND if the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The name of the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} to retrieve, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1beta1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1beta1/binauthz_management_service_v1_beta1.get_attestor.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_BinauthzManagementServiceV1Beta1_GetAttestor_async | ||
*/ | ||
getAttestor(request?: protos.google.cloud.binaryauthorization.v1beta1.IGetAttestorRequest, options?: CallOptions): Promise<[ | ||
@@ -142,2 +234,22 @@ protos.google.cloud.binaryauthorization.v1beta1.IAttestor, | ||
getAttestor(request: protos.google.cloud.binaryauthorization.v1beta1.IGetAttestorRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1beta1.IAttestor, protos.google.cloud.binaryauthorization.v1beta1.IGetAttestorRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Updates an {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. | ||
* Returns NOT_FOUND if the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {google.cloud.binaryauthorization.v1beta1.Attestor} request.attestor | ||
* Required. The updated {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1beta1.Attestor.name|attestor name} field with the resource name | ||
* in the request URL, in the format `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1beta1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1beta1/binauthz_management_service_v1_beta1.update_attestor.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_BinauthzManagementServiceV1Beta1_UpdateAttestor_async | ||
*/ | ||
updateAttestor(request?: protos.google.cloud.binaryauthorization.v1beta1.IUpdateAttestorRequest, options?: CallOptions): Promise<[ | ||
@@ -150,2 +262,21 @@ protos.google.cloud.binaryauthorization.v1beta1.IAttestor, | ||
updateAttestor(request: protos.google.cloud.binaryauthorization.v1beta1.IUpdateAttestorRequest, callback: Callback<protos.google.cloud.binaryauthorization.v1beta1.IAttestor, protos.google.cloud.binaryauthorization.v1beta1.IUpdateAttestorRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Deletes an {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. Returns NOT_FOUND if the | ||
* {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The name of the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors} to delete, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Empty]{@link google.protobuf.Empty}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1beta1/binauthz_management_service_v1_beta1.delete_attestor.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_BinauthzManagementServiceV1Beta1_DeleteAttestor_async | ||
*/ | ||
deleteAttestor(request?: protos.google.cloud.binaryauthorization.v1beta1.IDeleteAttestorRequest, options?: CallOptions): Promise<[ | ||
@@ -158,2 +289,31 @@ protos.google.protobuf.IEmpty, | ||
deleteAttestor(request: protos.google.cloud.binaryauthorization.v1beta1.IDeleteAttestorRequest, callback: Callback<protos.google.protobuf.IEmpty, protos.google.cloud.binaryauthorization.v1beta1.IDeleteAttestorRequest | null | undefined, {} | null | undefined>): void; | ||
/** | ||
* Lists {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors}. | ||
* Returns INVALID_ARGUMENT if the project does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.parent | ||
* Required. The resource name of the project associated with the | ||
* {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors}, in the format `projects/*`. | ||
* @param {number} request.pageSize | ||
* Requested page size. The server may return fewer results than requested. If | ||
* unspecified, the server will pick an appropriate default. | ||
* @param {string} request.pageToken | ||
* A token identifying a page of results the server should return. Typically, | ||
* this is the value of {@link google.cloud.binaryauthorization.v1beta1.ListAttestorsResponse.next_page_token|ListAttestorsResponse.next_page_token} returned | ||
* from the previous call to the `ListAttestors` method. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is Array of [Attestor]{@link google.cloud.binaryauthorization.v1beta1.Attestor}. | ||
* The client library will perform auto-pagination by default: it will call the API as many | ||
* times as needed and will merge results from all the pages into this array. | ||
* Note that it can affect your quota. | ||
* We recommend using `listAttestorsAsync()` | ||
* method described below for async iteration which you can stop as needed. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination) | ||
* for more details and examples. | ||
*/ | ||
listAttestors(request?: protos.google.cloud.binaryauthorization.v1beta1.IListAttestorsRequest, options?: CallOptions): Promise<[ | ||
@@ -219,7 +379,4 @@ protos.google.cloud.binaryauthorization.v1beta1.IAttestor[], | ||
* for more details and examples. | ||
* @example | ||
* const iterable = client.listAttestorsAsync(request); | ||
* for await (const response of iterable) { | ||
* // process response | ||
* } | ||
* @example <caption>include:samples/generated/v1beta1/binauthz_management_service_v1_beta1.list_attestors.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_BinauthzManagementServiceV1Beta1_ListAttestors_async | ||
*/ | ||
@@ -226,0 +383,0 @@ listAttestorsAsync(request?: protos.google.cloud.binaryauthorization.v1beta1.IListAttestorsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.binaryauthorization.v1beta1.IAttestor>; |
@@ -249,26 +249,2 @@ "use strict"; | ||
} | ||
/** | ||
* A {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} specifies the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors} 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 {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} for this project. Returns a default | ||
* {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} if the project does not have one. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The resource name of the {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} to retrieve, | ||
* in the format `projects/* /policy`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1beta1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.getPolicy(request); | ||
*/ | ||
getPolicy(request, optionsOrCallback, callback) { | ||
@@ -294,25 +270,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Creates or updates a project's {@link google.cloud.binaryauthorization.v1beta1.Policy|policy}, and returns a copy of the | ||
* new {@link google.cloud.binaryauthorization.v1beta1.Policy|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. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {google.cloud.binaryauthorization.v1beta1.Policy} request.policy | ||
* Required. A new or updated {@link google.cloud.binaryauthorization.v1beta1.Policy|policy} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1beta1.Policy.name|policy name} field with the resource name in | ||
* the request URL, in the format `projects/* /policy`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1beta1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.updatePolicy(request); | ||
*/ | ||
updatePolicy(request, optionsOrCallback, callback) { | ||
@@ -338,28 +291,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Creates an {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}, and returns a copy of the new | ||
* {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. Returns NOT_FOUND if the project does not exist, | ||
* INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the | ||
* {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} already exists. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.parent | ||
* Required. The parent of this {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. | ||
* @param {string} request.attestorId | ||
* Required. The {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors} ID. | ||
* @param {google.cloud.binaryauthorization.v1beta1.Attestor} request.attestor | ||
* Required. The initial {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1beta1.Attestor.name|attestor name} field with the resource name, | ||
* in the format `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1beta1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.createAttestor(request); | ||
*/ | ||
createAttestor(request, optionsOrCallback, callback) { | ||
@@ -385,21 +312,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Gets an {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. | ||
* Returns NOT_FOUND if the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The name of the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} to retrieve, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1beta1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.getAttestor(request); | ||
*/ | ||
getAttestor(request, optionsOrCallback, callback) { | ||
@@ -425,22 +333,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Updates an {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. | ||
* Returns NOT_FOUND if the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {google.cloud.binaryauthorization.v1beta1.Attestor} request.attestor | ||
* Required. The updated {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} value. The service will | ||
* overwrite the {@link google.cloud.binaryauthorization.v1beta1.Attestor.name|attestor name} field with the resource name | ||
* in the request URL, in the format `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Attestor]{@link google.cloud.binaryauthorization.v1beta1.Attestor}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.updateAttestor(request); | ||
*/ | ||
updateAttestor(request, optionsOrCallback, callback) { | ||
@@ -466,21 +354,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Deletes an {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor}. Returns NOT_FOUND if the | ||
* {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestor} does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The name of the {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors} to delete, in the format | ||
* `projects/* /attestors/*`. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Empty]{@link google.protobuf.Empty}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.deleteAttestor(request); | ||
*/ | ||
deleteAttestor(request, optionsOrCallback, callback) { | ||
@@ -506,31 +375,2 @@ request = request || {}; | ||
} | ||
/** | ||
* Lists {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors}. | ||
* Returns INVALID_ARGUMENT if the project does not exist. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.parent | ||
* Required. The resource name of the project associated with the | ||
* {@link google.cloud.binaryauthorization.v1beta1.Attestor|attestors}, in the format `projects/*`. | ||
* @param {number} request.pageSize | ||
* Requested page size. The server may return fewer results than requested. If | ||
* unspecified, the server will pick an appropriate default. | ||
* @param {string} request.pageToken | ||
* A token identifying a page of results the server should return. Typically, | ||
* this is the value of {@link google.cloud.binaryauthorization.v1beta1.ListAttestorsResponse.next_page_token|ListAttestorsResponse.next_page_token} returned | ||
* from the previous call to the `ListAttestors` method. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is Array of [Attestor]{@link google.cloud.binaryauthorization.v1beta1.Attestor}. | ||
* The client library will perform auto-pagination by default: it will call the API as many | ||
* times as needed and will merge results from all the pages into this array. | ||
* Note that it can affect your quota. | ||
* We recommend using `listAttestorsAsync()` | ||
* method described below for async iteration which you can stop as needed. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination) | ||
* for more details and examples. | ||
*/ | ||
listAttestors(request, optionsOrCallback, callback) { | ||
@@ -622,7 +462,4 @@ request = request || {}; | ||
* for more details and examples. | ||
* @example | ||
* const iterable = client.listAttestorsAsync(request); | ||
* for await (const response of iterable) { | ||
* // process response | ||
* } | ||
* @example <caption>include:samples/generated/v1beta1/binauthz_management_service_v1_beta1.list_attestors.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_BinauthzManagementServiceV1Beta1_ListAttestors_async | ||
*/ | ||
@@ -638,3 +475,2 @@ listAttestorsAsync(request, options) { | ||
}); | ||
options = options || {}; | ||
const defaultCallSettings = this._defaults['listAttestors']; | ||
@@ -641,0 +477,0 @@ const callSettings = defaultCallSettings.merge(options); |
@@ -102,2 +102,20 @@ import * as gax from 'google-gax'; | ||
getProjectId(callback: Callback<string, undefined, undefined>): void; | ||
/** | ||
* Gets the current system policy in the specified location. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The resource name, in the format `locations/* /policy`. | ||
* Note that the system policy is not associated with a project. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1beta1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example <caption>include:samples/generated/v1beta1/system_policy_v1_beta1.get_system_policy.js</caption> | ||
* region_tag:binaryauthorization_v1beta1_generated_SystemPolicyV1Beta1_GetSystemPolicy_async | ||
*/ | ||
getSystemPolicy(request?: protos.google.cloud.binaryauthorization.v1beta1.IGetSystemPolicyRequest, options?: CallOptions): Promise<[ | ||
@@ -104,0 +122,0 @@ protos.google.cloud.binaryauthorization.v1beta1.IPolicy, |
@@ -228,20 +228,2 @@ "use strict"; | ||
} | ||
/** | ||
* Gets the current system policy in the specified location. | ||
* | ||
* @param {Object} request | ||
* The request object that will be sent. | ||
* @param {string} request.name | ||
* Required. The resource name, in the format `locations/* /policy`. | ||
* Note that the system policy is not associated with a project. | ||
* @param {object} [options] | ||
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. | ||
* @returns {Promise} - The promise which resolves to an array. | ||
* The first element of the array is an object representing [Policy]{@link google.cloud.binaryauthorization.v1beta1.Policy}. | ||
* Please see the | ||
* [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) | ||
* for more details and examples. | ||
* @example | ||
* const [response] = await client.getSystemPolicy(request); | ||
*/ | ||
getSystemPolicy(request, optionsOrCallback, callback) { | ||
@@ -248,0 +230,0 @@ request = request || {}; |
# Changelog | ||
### [1.5.1](https://github.com/googleapis/nodejs-binary-authorization/compare/v1.5.0...v1.5.1) (2022-01-13) | ||
### Bug Fixes | ||
* Modify the bazel.BUILD file by hand to include the compliance protos which are not autogenerated ([#120](https://github.com/googleapis/nodejs-binary-authorization/issues/120)) ([4f30555](https://github.com/googleapis/nodejs-binary-authorization/commit/4f305551c6d9f97bd2e4ef8430fd7dc9cfc6f9c9)) | ||
## [1.5.0](https://www.github.com/googleapis/nodejs-binary-authorization/compare/v1.4.0...v1.5.0) (2021-11-08) | ||
@@ -4,0 +11,0 @@ |
{ | ||
"name": "@google-cloud/binary-authorization", | ||
"version": "1.5.0", | ||
"version": "1.5.1", | ||
"description": "Binaryauthorization client for Node.js", | ||
@@ -5,0 +5,0 @@ "repository": "googleapis/nodejs-binary-authorization", |
@@ -7,5 +7,4 @@ [//]: # "This README.md file is auto-generated, all changes to this file will be lost." | ||
[![release level](https://img.shields.io/badge/release%20level-beta-yellow.svg?style=flat)](https://cloud.google.com/terms/launch-stages) | ||
[![release level](https://img.shields.io/badge/release%20level-preview-yellow.svg?style=flat)](https://cloud.google.com/terms/launch-stages) | ||
[![npm version](https://img.shields.io/npm/v/@google-cloud/binary-authorization.svg)](https://www.npmjs.org/package/@google-cloud/binary-authorization) | ||
[![codecov](https://img.shields.io/codecov/c/github/googleapis/nodejs-binary-authorization/main.svg?style=flat)](https://codecov.io/gh/googleapis/nodejs-binary-authorization) | ||
@@ -125,6 +124,2 @@ | ||
This library is considered to be in **beta**. This means it is expected to be | ||
mostly stable while we work toward a general availability release; however, | ||
complete stability is not guaranteed. We will address issues and requests | ||
against beta libraries with a high priority. | ||
@@ -134,2 +129,7 @@ | ||
This library is considered to be in **preview**. This means it is still a | ||
work-in-progress and under active development. Any release is subject to | ||
backwards-incompatible changes at any time. | ||
More Information: [Google Cloud Platform Launch Stages][launch_stages] | ||
@@ -136,0 +136,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
2363965
59
35887