The service that is used for managing the data plane provisioning of the Registry. v1
Package
@google-cloud/apigee-registryConstructors
(constructor)(opts, gaxInstance)
constructor(opts?: ClientOptions, gaxInstance?: typeof gax | typeof gax.fallback);
Construct an instance of ProvisioningClient.
Parameters | |
---|---|
Name | Description |
opts |
ClientOptions
|
gaxInstance |
typeof gax | typeof gax.fallback
: loaded instance of |
Properties
apiEndpoint
static get apiEndpoint(): string;
The DNS address for this API service - same as servicePath(), exists for compatibility reasons.
auth
auth: gax.GoogleAuth;
descriptors
descriptors: Descriptors;
iamClient
iamClient: IamClient;
innerApiCalls
innerApiCalls: {
[name: string]: Function;
};
locationsClient
locationsClient: LocationsClient;
operationsClient
operationsClient: gax.OperationsClient;
pathTemplates
pathTemplates: {
[name: string]: gax.PathTemplate;
};
port
static get port(): number;
The port for this API service.
provisioningStub
provisioningStub?: Promise<{
[name: string]: Function;
}>;
scopes
static get scopes(): string[];
The scopes needed to make gRPC calls for every method defined in this service.
servicePath
static get servicePath(): string;
The DNS address for this API service.
warn
warn: (code: string, message: string, warnType?: string) => void;
Methods
apiDeploymentPath(project, location, api, deployment)
apiDeploymentPath(project: string, location: string, api: string, deployment: string): string;
Return a fully-qualified apiDeployment resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
api |
string
|
deployment |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
apiPath(project, location, api)
apiPath(project: string, location: string, api: string): string;
Return a fully-qualified api resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
api |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
apiSpecPath(project, location, api, version, spec)
apiSpecPath(project: string, location: string, api: string, version: string, spec: string): string;
Return a fully-qualified apiSpec resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
api |
string
|
version |
string
|
spec |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
apiVersionPath(project, location, api, version)
apiVersionPath(project: string, location: string, api: string, version: string): string;
Return a fully-qualified apiVersion resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
api |
string
|
version |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
cancelOperation(request, options, callback)
cancelOperation(request: protos.google.longrunning.CancelOperationRequest, options?: gax.CallOptions | Callback<protos.google.protobuf.Empty, protos.google.longrunning.CancelOperationRequest, {} | undefined | null>, callback?: Callback<protos.google.longrunning.CancelOperationRequest, protos.google.protobuf.Empty, {} | undefined | null>): Promise<protos.google.protobuf.Empty>;
Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED
. Clients can use or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an value with a of 1, corresponding to Code.CANCELLED
.
Parameters | |
---|---|
Name | Description |
request |
protos.google.longrunning.CancelOperationRequest
The request object that will be sent. |
options |
gax.CallOptions | Callback<protos.google.protobuf.Empty, protos.google.longrunning.CancelOperationRequest, {} | undefined | null>
Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See [gax.CallOptions]https://googleapis.github.io/gax-nodejs/global.html#CallOptions for the details. |
callback |
Callback<protos.google.longrunning.CancelOperationRequest, protos.google.protobuf.Empty, {} | undefined | null>
The function which will be called with the result of the API call. {Promise} - The promise which resolves when API call finishes. The promise has a method named "cancel" which cancels the ongoing API call. |
Returns | |
---|---|
Type | Description |
Promise<protos.google.protobuf.Empty> |
const client = longrunning.operationsClient();
await client.cancelOperation({name: ''});
checkCreateInstanceProgress(name)
checkCreateInstanceProgress(name: string): Promise<LROperation<protos.google.cloud.apigeeregistry.v1.Instance, protos.google.cloud.apigeeregistry.v1.OperationMetadata>>;
Check the status of the long running operation returned by createInstance()
.
Parameter | |
---|---|
Name | Description |
name |
string
The operation name that will be passed. |
Returns | |
---|---|
Type | Description |
Promise<LROperation<protos.google.cloud.apigeeregistry.v1.Instance, protos.google.cloud.apigeeregistry.v1.OperationMetadata>> | {Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#long-running-operations) for more details and examples. |
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. Parent resource of the Instance, of the form: `projects/* /locations/*`
*/
// const parent = 'abc123'
/**
* Required. Identifier to assign to the Instance. Must be unique within scope of the
* parent resource.
*/
// const instanceId = 'abc123'
/**
* Required. The Instance.
*/
// const instance = {}
// Imports the Apigeeregistry library
const {ProvisioningClient} = require('@google-cloud/apigee-registry').v1;
// Instantiates a client
const apigeeregistryClient = new ProvisioningClient();
async function callCreateInstance() {
// Construct request
const request = {
parent,
instanceId,
instance,
};
// Run request
const [operation] = await apigeeregistryClient.createInstance(request);
const [response] = await operation.promise();
console.log(response);
}
callCreateInstance();
checkDeleteInstanceProgress(name)
checkDeleteInstanceProgress(name: string): Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.apigeeregistry.v1.OperationMetadata>>;
Check the status of the long running operation returned by deleteInstance()
.
Parameter | |
---|---|
Name | Description |
name |
string
The operation name that will be passed. |
Returns | |
---|---|
Type | Description |
Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.apigeeregistry.v1.OperationMetadata>> | {Promise} - The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#long-running-operations) for more details and examples. |
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the Instance to delete.
* Format: `projects/* /locations/* /instances/*`.
*/
// const name = 'abc123'
// Imports the Apigeeregistry library
const {ProvisioningClient} = require('@google-cloud/apigee-registry').v1;
// Instantiates a client
const apigeeregistryClient = new ProvisioningClient();
async function callDeleteInstance() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await apigeeregistryClient.deleteInstance(request);
const [response] = await operation.promise();
console.log(response);
}
callDeleteInstance();
close()
close(): Promise<void>;
Terminate the gRPC channel and close the client.
The client will no longer be usable and all future behavior is undefined.
Returns | |
---|---|
Type | Description |
Promise<void> | {Promise} A promise that resolves when the client is closed. |
createInstance(request, options)
createInstance(request?: protos.google.cloud.apigeeregistry.v1.ICreateInstanceRequest, options?: CallOptions): Promise<[
LROperation<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Provisions instance resources for the Registry.
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.ICreateInstanceRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Returns | |
---|---|
Type | Description |
Promise<[
LROperation<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]> | {Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its |
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. Parent resource of the Instance, of the form: `projects/* /locations/*`
*/
// const parent = 'abc123'
/**
* Required. Identifier to assign to the Instance. Must be unique within scope of the
* parent resource.
*/
// const instanceId = 'abc123'
/**
* Required. The Instance.
*/
// const instance = {}
// Imports the Apigeeregistry library
const {ProvisioningClient} = require('@google-cloud/apigee-registry').v1;
// Instantiates a client
const apigeeregistryClient = new ProvisioningClient();
async function callCreateInstance() {
// Construct request
const request = {
parent,
instanceId,
instance,
};
// Run request
const [operation] = await apigeeregistryClient.createInstance(request);
const [response] = await operation.promise();
console.log(response);
}
callCreateInstance();
createInstance(request, options, callback)
createInstance(request: protos.google.cloud.apigeeregistry.v1.ICreateInstanceRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.ICreateInstanceRequest
|
options |
CallOptions
|
callback |
Callback<LROperation<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
|
Returns | |
---|---|
Type | Description |
void |
createInstance(request, callback)
createInstance(request: protos.google.cloud.apigeeregistry.v1.ICreateInstanceRequest, callback: Callback<LROperation<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.ICreateInstanceRequest
|
callback |
Callback<LROperation<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
|
Returns | |
---|---|
Type | Description |
void |
deleteInstance(request, options)
deleteInstance(request?: protos.google.cloud.apigeeregistry.v1.IDeleteInstanceRequest, options?: CallOptions): Promise<[
LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]>;
Deletes the Registry instance.
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.IDeleteInstanceRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Returns | |
---|---|
Type | Description |
Promise<[
LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>,
protos.google.longrunning.IOperation | undefined,
{} | undefined
]> | {Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its |
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the Instance to delete.
* Format: `projects/* /locations/* /instances/*`.
*/
// const name = 'abc123'
// Imports the Apigeeregistry library
const {ProvisioningClient} = require('@google-cloud/apigee-registry').v1;
// Instantiates a client
const apigeeregistryClient = new ProvisioningClient();
async function callDeleteInstance() {
// Construct request
const request = {
name,
};
// Run request
const [operation] = await apigeeregistryClient.deleteInstance(request);
const [response] = await operation.promise();
console.log(response);
}
callDeleteInstance();
deleteInstance(request, options, callback)
deleteInstance(request: protos.google.cloud.apigeeregistry.v1.IDeleteInstanceRequest, options: CallOptions, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.IDeleteInstanceRequest
|
options |
CallOptions
|
callback |
Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
|
Returns | |
---|---|
Type | Description |
void |
deleteInstance(request, callback)
deleteInstance(request: protos.google.cloud.apigeeregistry.v1.IDeleteInstanceRequest, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.IDeleteInstanceRequest
|
callback |
Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.apigeeregistry.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
|
Returns | |
---|---|
Type | Description |
void |
deleteOperation(request, options, callback)
deleteOperation(request: protos.google.longrunning.DeleteOperationRequest, options?: gax.CallOptions | Callback<protos.google.protobuf.Empty, protos.google.longrunning.DeleteOperationRequest, {} | null | undefined>, callback?: Callback<protos.google.protobuf.Empty, protos.google.longrunning.DeleteOperationRequest, {} | null | undefined>): Promise<protos.google.protobuf.Empty>;
Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED
.
Parameters | |
---|---|
Name | Description |
request |
protos.google.longrunning.DeleteOperationRequest
The request object that will be sent. |
options |
gax.CallOptions | Callback<protos.google.protobuf.Empty, protos.google.longrunning.DeleteOperationRequest, {} | null | undefined>
Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See [gax.CallOptions]https://googleapis.github.io/gax-nodejs/global.html#CallOptions for the details. |
callback |
Callback<protos.google.protobuf.Empty, protos.google.longrunning.DeleteOperationRequest, {} | null | undefined>
The function which will be called with the result of the API call. {Promise} - The promise which resolves when API call finishes. The promise has a method named "cancel" which cancels the ongoing API call. |
Returns | |
---|---|
Type | Description |
Promise<protos.google.protobuf.Empty> |
const client = longrunning.operationsClient();
await client.deleteOperation({name: ''});
getIamPolicy(request, options, callback)
getIamPolicy(request: IamProtos.google.iam.v1.GetIamPolicyRequest, options?: gax.CallOptions | Callback<IamProtos.google.iam.v1.Policy, IamProtos.google.iam.v1.GetIamPolicyRequest | null | undefined, {} | null | undefined>, callback?: Callback<IamProtos.google.iam.v1.Policy, IamProtos.google.iam.v1.GetIamPolicyRequest | null | undefined, {} | null | undefined>): Promise<IamProtos.google.iam.v1.Policy>;
Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.
Parameters | |
---|---|
Name | Description |
request |
IamProtos.google.iam.v1.GetIamPolicyRequest
The request object that will be sent. |
options |
gax.CallOptions | Callback<IamProtos.google.iam.v1.Policy, IamProtos.google.iam.v1.GetIamPolicyRequest | null | undefined, {} | null | undefined>
Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See [gax.CallOptions]https://googleapis.github.io/gax-nodejs/interfaces/CallOptions.html for the details. |
callback |
Callback<IamProtos.google.iam.v1.Policy, IamProtos.google.iam.v1.GetIamPolicyRequest | null | undefined, {} | null | undefined>
The function which will be called with the result of the API call. The second parameter to the callback is an object representing [Policy]. |
Returns | |
---|---|
Type | Description |
Promise<IamProtos.google.iam.v1.Policy> | {Promise} - The promise which resolves to an array. The first element of the array is an object representing [Policy]. The promise has a method named "cancel" which cancels the ongoing API call. |
getInstance(request, options)
getInstance(request?: protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest, options?: CallOptions): Promise<[
protos.google.cloud.apigeeregistry.v1.IInstance,
protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest | undefined,
{} | undefined
]>;
Gets details of a single Instance.
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Returns | |
---|---|
Type | Description |
Promise<[
protos.google.cloud.apigeeregistry.v1.IInstance,
protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest | undefined,
{} | undefined
]> | {Promise} - The promise which resolves to an array. The first element of the array is an object representing [Instance]. Please see the [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) for more details and examples. |
/**
* This snippet has been automatically generated and should be regarded as a code template only.
* It will require modifications to work.
* It may require correct/in-range values for request initialization.
* TODO(developer): Uncomment these variables before running the sample.
*/
/**
* Required. The name of the Instance to retrieve.
* Format: `projects/* /locations/* /instances/*`.
*/
// const name = 'abc123'
// Imports the Apigeeregistry library
const {ProvisioningClient} = require('@google-cloud/apigee-registry').v1;
// Instantiates a client
const apigeeregistryClient = new ProvisioningClient();
async function callGetInstance() {
// Construct request
const request = {
name,
};
// Run request
const response = await apigeeregistryClient.getInstance(request);
console.log(response);
}
callGetInstance();
getInstance(request, options, callback)
getInstance(request: protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest, options: CallOptions, callback: Callback<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest | null | undefined, {} | null | undefined>): void;
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest
|
options |
CallOptions
|
callback |
Callback<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest | null | undefined, {} | null | undefined>
|
Returns | |
---|---|
Type | Description |
void |
getInstance(request, callback)
getInstance(request: protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest, callback: Callback<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest | null | undefined, {} | null | undefined>): void;
Parameters | |
---|---|
Name | Description |
request |
protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest
|
callback |
Callback<protos.google.cloud.apigeeregistry.v1.IInstance, protos.google.cloud.apigeeregistry.v1.IGetInstanceRequest | null | undefined, {} | null | undefined>
|
Returns | |
---|---|
Type | Description |
void |
getLocation(request, options, callback)
getLocation(request: LocationProtos.google.cloud.location.IGetLocationRequest, options?: gax.CallOptions | Callback<LocationProtos.google.cloud.location.ILocation, LocationProtos.google.cloud.location.IGetLocationRequest | null | undefined, {} | null | undefined>, callback?: Callback<LocationProtos.google.cloud.location.ILocation, LocationProtos.google.cloud.location.IGetLocationRequest | null | undefined, {} | null | undefined>): Promise<LocationProtos.google.cloud.location.ILocation>;
Gets information about a location.
Parameters | |
---|---|
Name | Description |
request |
LocationProtos.google.cloud.location.IGetLocationRequest
The request object that will be sent. |
options |
gax.CallOptions | Callback<LocationProtos.google.cloud.location.ILocation, LocationProtos.google.cloud.location.IGetLocationRequest | null | undefined, {} | null | undefined>
Call options. See CallOptions for more details. |
callback |
Callback<LocationProtos.google.cloud.location.ILocation, LocationProtos.google.cloud.location.IGetLocationRequest | null | undefined, {} | null | undefined>
|
Returns | |
---|---|
Type | Description |
Promise<LocationProtos.google.cloud.location.ILocation> | {Promise} - The promise which resolves to an array. The first element of the array is an object representing [Location]. Please see the [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#regular-methods) for more details and examples. |
const [response] = await client.getLocation(request);
getOperation(request, options, callback)
getOperation(request: protos.google.longrunning.GetOperationRequest, options?: gax.CallOptions | Callback<protos.google.longrunning.Operation, protos.google.longrunning.GetOperationRequest, {} | null | undefined>, callback?: Callback<protos.google.longrunning.Operation, protos.google.longrunning.GetOperationRequest, {} | null | undefined>): Promise<[protos.google.longrunning.Operation]>;
Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.
Parameters | |
---|---|
Name | Description |
request |
protos.google.longrunning.GetOperationRequest
The request object that will be sent. |
options |
gax.CallOptions | Callback<protos.google.longrunning.Operation, protos.google.longrunning.GetOperationRequest, {} | null | undefined>
Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See [gax.CallOptions]https://googleapis.github.io/gax-nodejs/global.html#CallOptions for the details. |
callback |
Callback<protos.google.longrunning.Operation, protos.google.longrunning.GetOperationRequest, {} | null | undefined>
The function which will be called with the result of the API call. The second parameter to the callback is an object representing [google.longrunning.Operation]. {Promise} - The promise which resolves to an array. The first element of the array is an object representing [google.longrunning.Operation]. The promise has a method named "cancel" which cancels the ongoing API call. |
Returns | |
---|---|
Type | Description |
Promise<[protos.google.longrunning.Operation]> |
const client = longrunning.operationsClient();
const name = '';
const [response] = await client.getOperation({name});
// doThingsWith(response)
getProjectId()
getProjectId(): Promise<string>;
Returns | |
---|---|
Type | Description |
Promise<string> |
getProjectId(callback)
getProjectId(callback: Callback<string, undefined, undefined>): void;
Parameter | |
---|---|
Name | Description |
callback |
Callback<string, undefined, undefined>
|
Returns | |
---|---|
Type | Description |
void |
initialize()
initialize(): Promise<{
[name: string]: Function;
}>;
Initialize the client. Performs asynchronous operations (such as authentication) and prepares the client. This function will be called automatically when any class method is called for the first time, but if you need to initialize it before calling an actual method, feel free to call initialize() directly.
You can await on this method if you want to make sure the client is initialized.
Returns | |
---|---|
Type | Description |
Promise<{
[name: string]: Function;
}> | {Promise} A promise that resolves to an authenticated service stub. |
instancePath(project, location, instance)
instancePath(project: string, location: string, instance: string): string;
Return a fully-qualified instance resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
instance |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
listLocationsAsync(request, options)
listLocationsAsync(request: LocationProtos.google.cloud.location.IListLocationsRequest, options?: CallOptions): AsyncIterable<LocationProtos.google.cloud.location.ILocation>;
Lists information about the supported locations for this service. Returns an iterable object.
for
-await
-of
syntax is used with the iterable to get response elements on-demand.
Parameters | |
---|---|
Name | Description |
request |
LocationProtos.google.cloud.location.IListLocationsRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Returns | |
---|---|
Type | Description |
AsyncIterable<LocationProtos.google.cloud.location.ILocation> | {Object} An iterable Object that allows [async iteration](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols). When you iterate the returned iterable, each element will be an object representing [Location]. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#auto-pagination) for more details and examples. |
const iterable = client.listLocationsAsync(request);
for await (const response of iterable) {
// process response
}
listOperationsAsync(request, options)
listOperationsAsync(request: protos.google.longrunning.ListOperationsRequest, options?: gax.CallOptions): AsyncIterable<protos.google.longrunning.ListOperationsResponse>;
Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns UNIMPLEMENTED
. Returns an iterable object.
For-await-of syntax is used with the iterable to recursively get response element on-demand.
Parameters | |
---|---|
Name | Description |
request |
protos.google.longrunning.ListOperationsRequest
The request object that will be sent. |
options |
gax.CallOptions
Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See [gax.CallOptions]https://googleapis.github.io/gax-nodejs/global.html#CallOptions for the details. |
Returns | |
---|---|
Type | Description |
AsyncIterable<protos.google.longrunning.ListOperationsResponse> | {Object} An iterable Object that conforms to https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols. |
const client = longrunning.operationsClient();
for await (const response of client.listOperationsAsync(request));
// doThingsWith(response)
locationPath(project, location)
locationPath(project: string, location: string): string;
Return a fully-qualified location resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
matchApiFromApiDeploymentName(apiDeploymentName)
matchApiFromApiDeploymentName(apiDeploymentName: string): string | number;
Parse the api from ApiDeployment resource.
Parameter | |
---|---|
Name | Description |
apiDeploymentName |
string
A fully-qualified path representing ApiDeployment resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the api. |
matchApiFromApiName(apiName)
matchApiFromApiName(apiName: string): string | number;
Parse the api from Api resource.
Parameter | |
---|---|
Name | Description |
apiName |
string
A fully-qualified path representing Api resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the api. |
matchApiFromApiSpecName(apiSpecName)
matchApiFromApiSpecName(apiSpecName: string): string | number;
Parse the api from ApiSpec resource.
Parameter | |
---|---|
Name | Description |
apiSpecName |
string
A fully-qualified path representing ApiSpec resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the api. |
matchApiFromApiVersionName(apiVersionName)
matchApiFromApiVersionName(apiVersionName: string): string | number;
Parse the api from ApiVersion resource.
Parameter | |
---|---|
Name | Description |
apiVersionName |
string
A fully-qualified path representing ApiVersion resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the api. |
matchApiFromProjectLocationApiArtifactName(projectLocationApiArtifactName)
matchApiFromProjectLocationApiArtifactName(projectLocationApiArtifactName: string): string | number;
Parse the api from ProjectLocationApiArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiArtifactName |
string
A fully-qualified path representing project_location_api_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the api. |
matchApiFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName)
matchApiFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName: string): string | number;
Parse the api from ProjectLocationApiDeploymentArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiDeploymentArtifactName |
string
A fully-qualified path representing project_location_api_deployment_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the api. |
matchApiFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName)
matchApiFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName: string): string | number;
Parse the api from ProjectLocationApiVersionArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionArtifactName |
string
A fully-qualified path representing project_location_api_version_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the api. |
matchApiFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName)
matchApiFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName: string): string | number;
Parse the api from ProjectLocationApiVersionSpecArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionSpecArtifactName |
string
A fully-qualified path representing project_location_api_version_spec_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the api. |
matchArtifactFromProjectLocationApiArtifactName(projectLocationApiArtifactName)
matchArtifactFromProjectLocationApiArtifactName(projectLocationApiArtifactName: string): string | number;
Parse the artifact from ProjectLocationApiArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiArtifactName |
string
A fully-qualified path representing project_location_api_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the artifact. |
matchArtifactFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName)
matchArtifactFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName: string): string | number;
Parse the artifact from ProjectLocationApiDeploymentArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiDeploymentArtifactName |
string
A fully-qualified path representing project_location_api_deployment_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the artifact. |
matchArtifactFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName)
matchArtifactFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName: string): string | number;
Parse the artifact from ProjectLocationApiVersionArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionArtifactName |
string
A fully-qualified path representing project_location_api_version_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the artifact. |
matchArtifactFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName)
matchArtifactFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName: string): string | number;
Parse the artifact from ProjectLocationApiVersionSpecArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionSpecArtifactName |
string
A fully-qualified path representing project_location_api_version_spec_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the artifact. |
matchArtifactFromProjectLocationArtifactName(projectLocationArtifactName)
matchArtifactFromProjectLocationArtifactName(projectLocationArtifactName: string): string | number;
Parse the artifact from ProjectLocationArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationArtifactName |
string
A fully-qualified path representing project_location_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the artifact. |
matchDeploymentFromApiDeploymentName(apiDeploymentName)
matchDeploymentFromApiDeploymentName(apiDeploymentName: string): string | number;
Parse the deployment from ApiDeployment resource.
Parameter | |
---|---|
Name | Description |
apiDeploymentName |
string
A fully-qualified path representing ApiDeployment resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the deployment. |
matchDeploymentFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName)
matchDeploymentFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName: string): string | number;
Parse the deployment from ProjectLocationApiDeploymentArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiDeploymentArtifactName |
string
A fully-qualified path representing project_location_api_deployment_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the deployment. |
matchInstanceFromInstanceName(instanceName)
matchInstanceFromInstanceName(instanceName: string): string | number;
Parse the instance from Instance resource.
Parameter | |
---|---|
Name | Description |
instanceName |
string
A fully-qualified path representing Instance resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the instance. |
matchLocationFromApiDeploymentName(apiDeploymentName)
matchLocationFromApiDeploymentName(apiDeploymentName: string): string | number;
Parse the location from ApiDeployment resource.
Parameter | |
---|---|
Name | Description |
apiDeploymentName |
string
A fully-qualified path representing ApiDeployment resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromApiName(apiName)
matchLocationFromApiName(apiName: string): string | number;
Parse the location from Api resource.
Parameter | |
---|---|
Name | Description |
apiName |
string
A fully-qualified path representing Api resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromApiSpecName(apiSpecName)
matchLocationFromApiSpecName(apiSpecName: string): string | number;
Parse the location from ApiSpec resource.
Parameter | |
---|---|
Name | Description |
apiSpecName |
string
A fully-qualified path representing ApiSpec resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromApiVersionName(apiVersionName)
matchLocationFromApiVersionName(apiVersionName: string): string | number;
Parse the location from ApiVersion resource.
Parameter | |
---|---|
Name | Description |
apiVersionName |
string
A fully-qualified path representing ApiVersion resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromInstanceName(instanceName)
matchLocationFromInstanceName(instanceName: string): string | number;
Parse the location from Instance resource.
Parameter | |
---|---|
Name | Description |
instanceName |
string
A fully-qualified path representing Instance resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromLocationName(locationName)
matchLocationFromLocationName(locationName: string): string | number;
Parse the location from Location resource.
Parameter | |
---|---|
Name | Description |
locationName |
string
A fully-qualified path representing Location resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromProjectLocationApiArtifactName(projectLocationApiArtifactName)
matchLocationFromProjectLocationApiArtifactName(projectLocationApiArtifactName: string): string | number;
Parse the location from ProjectLocationApiArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiArtifactName |
string
A fully-qualified path representing project_location_api_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName)
matchLocationFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName: string): string | number;
Parse the location from ProjectLocationApiDeploymentArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiDeploymentArtifactName |
string
A fully-qualified path representing project_location_api_deployment_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName)
matchLocationFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName: string): string | number;
Parse the location from ProjectLocationApiVersionArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionArtifactName |
string
A fully-qualified path representing project_location_api_version_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName)
matchLocationFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName: string): string | number;
Parse the location from ProjectLocationApiVersionSpecArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionSpecArtifactName |
string
A fully-qualified path representing project_location_api_version_spec_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchLocationFromProjectLocationArtifactName(projectLocationArtifactName)
matchLocationFromProjectLocationArtifactName(projectLocationArtifactName: string): string | number;
Parse the location from ProjectLocationArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationArtifactName |
string
A fully-qualified path representing project_location_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the location. |
matchProjectFromApiDeploymentName(apiDeploymentName)
matchProjectFromApiDeploymentName(apiDeploymentName: string): string | number;
Parse the project from ApiDeployment resource.
Parameter | |
---|---|
Name | Description |
apiDeploymentName |
string
A fully-qualified path representing ApiDeployment resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromApiName(apiName)
matchProjectFromApiName(apiName: string): string | number;
Parse the project from Api resource.
Parameter | |
---|---|
Name | Description |
apiName |
string
A fully-qualified path representing Api resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromApiSpecName(apiSpecName)
matchProjectFromApiSpecName(apiSpecName: string): string | number;
Parse the project from ApiSpec resource.
Parameter | |
---|---|
Name | Description |
apiSpecName |
string
A fully-qualified path representing ApiSpec resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromApiVersionName(apiVersionName)
matchProjectFromApiVersionName(apiVersionName: string): string | number;
Parse the project from ApiVersion resource.
Parameter | |
---|---|
Name | Description |
apiVersionName |
string
A fully-qualified path representing ApiVersion resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromInstanceName(instanceName)
matchProjectFromInstanceName(instanceName: string): string | number;
Parse the project from Instance resource.
Parameter | |
---|---|
Name | Description |
instanceName |
string
A fully-qualified path representing Instance resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromLocationName(locationName)
matchProjectFromLocationName(locationName: string): string | number;
Parse the project from Location resource.
Parameter | |
---|---|
Name | Description |
locationName |
string
A fully-qualified path representing Location resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromProjectLocationApiArtifactName(projectLocationApiArtifactName)
matchProjectFromProjectLocationApiArtifactName(projectLocationApiArtifactName: string): string | number;
Parse the project from ProjectLocationApiArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiArtifactName |
string
A fully-qualified path representing project_location_api_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName)
matchProjectFromProjectLocationApiDeploymentArtifactName(projectLocationApiDeploymentArtifactName: string): string | number;
Parse the project from ProjectLocationApiDeploymentArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiDeploymentArtifactName |
string
A fully-qualified path representing project_location_api_deployment_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName)
matchProjectFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName: string): string | number;
Parse the project from ProjectLocationApiVersionArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionArtifactName |
string
A fully-qualified path representing project_location_api_version_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName)
matchProjectFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName: string): string | number;
Parse the project from ProjectLocationApiVersionSpecArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionSpecArtifactName |
string
A fully-qualified path representing project_location_api_version_spec_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchProjectFromProjectLocationArtifactName(projectLocationArtifactName)
matchProjectFromProjectLocationArtifactName(projectLocationArtifactName: string): string | number;
Parse the project from ProjectLocationArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationArtifactName |
string
A fully-qualified path representing project_location_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the project. |
matchSpecFromApiSpecName(apiSpecName)
matchSpecFromApiSpecName(apiSpecName: string): string | number;
Parse the spec from ApiSpec resource.
Parameter | |
---|---|
Name | Description |
apiSpecName |
string
A fully-qualified path representing ApiSpec resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the spec. |
matchSpecFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName)
matchSpecFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName: string): string | number;
Parse the spec from ProjectLocationApiVersionSpecArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionSpecArtifactName |
string
A fully-qualified path representing project_location_api_version_spec_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the spec. |
matchVersionFromApiSpecName(apiSpecName)
matchVersionFromApiSpecName(apiSpecName: string): string | number;
Parse the version from ApiSpec resource.
Parameter | |
---|---|
Name | Description |
apiSpecName |
string
A fully-qualified path representing ApiSpec resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the version. |
matchVersionFromApiVersionName(apiVersionName)
matchVersionFromApiVersionName(apiVersionName: string): string | number;
Parse the version from ApiVersion resource.
Parameter | |
---|---|
Name | Description |
apiVersionName |
string
A fully-qualified path representing ApiVersion resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the version. |
matchVersionFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName)
matchVersionFromProjectLocationApiVersionArtifactName(projectLocationApiVersionArtifactName: string): string | number;
Parse the version from ProjectLocationApiVersionArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionArtifactName |
string
A fully-qualified path representing project_location_api_version_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the version. |
matchVersionFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName)
matchVersionFromProjectLocationApiVersionSpecArtifactName(projectLocationApiVersionSpecArtifactName: string): string | number;
Parse the version from ProjectLocationApiVersionSpecArtifact resource.
Parameter | |
---|---|
Name | Description |
projectLocationApiVersionSpecArtifactName |
string
A fully-qualified path representing project_location_api_version_spec_artifact resource. |
Returns | |
---|---|
Type | Description |
string | number | {string} A string representing the version. |
projectLocationApiArtifactPath(project, location, api, artifact)
projectLocationApiArtifactPath(project: string, location: string, api: string, artifact: string): string;
Return a fully-qualified projectLocationApiArtifact resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
api |
string
|
artifact |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
projectLocationApiDeploymentArtifactPath(project, location, api, deployment, artifact)
projectLocationApiDeploymentArtifactPath(project: string, location: string, api: string, deployment: string, artifact: string): string;
Return a fully-qualified projectLocationApiDeploymentArtifact resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
api |
string
|
deployment |
string
|
artifact |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
projectLocationApiVersionArtifactPath(project, location, api, version, artifact)
projectLocationApiVersionArtifactPath(project: string, location: string, api: string, version: string, artifact: string): string;
Return a fully-qualified projectLocationApiVersionArtifact resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
api |
string
|
version |
string
|
artifact |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
projectLocationApiVersionSpecArtifactPath(project, location, api, version, spec, artifact)
projectLocationApiVersionSpecArtifactPath(project: string, location: string, api: string, version: string, spec: string, artifact: string): string;
Return a fully-qualified projectLocationApiVersionSpecArtifact resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
api |
string
|
version |
string
|
spec |
string
|
artifact |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
projectLocationArtifactPath(project, location, artifact)
projectLocationArtifactPath(project: string, location: string, artifact: string): string;
Return a fully-qualified projectLocationArtifact resource name string.
Parameters | |
---|---|
Name | Description |
project |
string
|
location |
string
|
artifact |
string
|
Returns | |
---|---|
Type | Description |
string | {string} Resource name string. |
setIamPolicy(request, options, callback)
setIamPolicy(request: IamProtos.google.iam.v1.SetIamPolicyRequest, options?: gax.CallOptions | Callback<IamProtos.google.iam.v1.Policy, IamProtos.google.iam.v1.SetIamPolicyRequest | null | undefined, {} | null | undefined>, callback?: Callback<IamProtos.google.iam.v1.Policy, IamProtos.google.iam.v1.SetIamPolicyRequest | null | undefined, {} | null | undefined>): Promise<IamProtos.google.iam.v1.Policy>;
Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.
Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning.
Parameters | |
---|---|
Name | Description |
request |
IamProtos.google.iam.v1.SetIamPolicyRequest
The request object that will be sent. |
options |
gax.CallOptions | Callback<IamProtos.google.iam.v1.Policy, IamProtos.google.iam.v1.SetIamPolicyRequest | null | undefined, {} | null | undefined>
Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See [gax.CallOptions]https://googleapis.github.io/gax-nodejs/interfaces/CallOptions.html for the details. |
callback |
Callback<IamProtos.google.iam.v1.Policy, IamProtos.google.iam.v1.SetIamPolicyRequest | null | undefined, {} | null | undefined>
The function which will be called with the result of the API call. The second parameter to the callback is an object representing [TestIamPermissionsResponse]. |
Returns | |
---|---|
Type | Description |
Promise<IamProtos.google.iam.v1.Policy> | {Promise} - The promise which resolves to an array. The first element of the array is an object representing [TestIamPermissionsResponse]. The promise has a method named "cancel" which cancels the ongoing API call. |
testIamPermissions(request, options, callback)
testIamPermissions(request: IamProtos.google.iam.v1.TestIamPermissionsRequest, options?: gax.CallOptions | Callback<IamProtos.google.iam.v1.TestIamPermissionsResponse, IamProtos.google.iam.v1.TestIamPermissionsRequest | null | undefined, {} | null | undefined>, callback?: Callback<IamProtos.google.iam.v1.TestIamPermissionsResponse, IamProtos.google.iam.v1.TestIamPermissionsRequest | null | undefined, {} | null | undefined>): Promise<IamProtos.google.iam.v1.TestIamPermissionsResponse>;
Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.
Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning.
Parameters | |
---|---|
Name | Description |
request |
IamProtos.google.iam.v1.TestIamPermissionsRequest
The request object that will be sent. |
options |
gax.CallOptions | Callback<IamProtos.google.iam.v1.TestIamPermissionsResponse, IamProtos.google.iam.v1.TestIamPermissionsRequest | null | undefined, {} | null | undefined>
Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See [gax.CallOptions]https://googleapis.github.io/gax-nodejs/interfaces/CallOptions.html for the details. |
callback |
Callback<IamProtos.google.iam.v1.TestIamPermissionsResponse, IamProtos.google.iam.v1.TestIamPermissionsRequest | null | undefined, {} | null | undefined>
The function which will be called with the result of the API call. The second parameter to the callback is an object representing [TestIamPermissionsResponse]. |
Returns | |
---|---|
Type | Description |
Promise<IamProtos.google.iam.v1.TestIamPermissionsResponse> | {Promise} - The promise which resolves to an array. The first element of the array is an object representing [TestIamPermissionsResponse]. The promise has a method named "cancel" which cancels the ongoing API call. |