PrivateCatalog
allows catalog consumers to retrieve Catalog
, Product
and Version
resources under a target resource context.
Catalog
is computed based on the s linked to the target resource and its ancestors. Each association's is transformed into a Catalog
. If multiple associations have the same parent , they are de-duplicated into one Catalog
. Users must have cloudprivatecatalog.catalogTargets.get
IAM permission on the resource context in order to access catalogs. Catalog
contains the resource name and a subset of data of the original .
Product
is child resource of the catalog. A Product
contains the resource name and a subset of the data of the original .
Version
is child resource of the product. A Version
contains the resource name and a subset of the data of the original . v1beta1
Package
@google-cloud/private-catalog!Constructors
(constructor)(opts)
constructor(opts?: ClientOptions);
Construct an instance of PrivateCatalogClient.
Name | Description |
opts |
ClientOptions
|
Properties
apiEndpoint
static get apiEndpoint(): string;
The DNS address for this API service - same as servicePath(), exists for compatibility reasons.
Type | Description |
string |
auth
auth: gax.GoogleAuth;
Type | Description |
gax.GoogleAuth |
descriptors
descriptors: Descriptors;
Type | Description |
Descriptors |
innerApiCalls
innerApiCalls: {
[name: string]: Function;
};
Type | Description |
{ [name: string]: Function; } |
pathTemplates
pathTemplates: {
[name: string]: gax.PathTemplate;
};
Type | Description |
{ [name: string]: gax.PathTemplate; } |
port
static get port(): number;
The port for this API service.
Type | Description |
number |
privateCatalogStub
privateCatalogStub?: Promise<{
[name: string]: Function;
}>;
Type | Description |
Promise<{ [name: string]: Function; }> |
scopes
static get scopes(): string[];
The scopes needed to make gRPC calls for every method defined in this service.
Type | Description |
string[] |
servicePath
static get servicePath(): string;
The DNS address for this API service.
Type | Description |
string |
warn
warn: (code: string, message: string, warnType?: string) => void;
Type | Description |
(code: string, message: string, warnType?: string) => void |
Methods
catalogPath(catalog)
catalogPath(catalog: string): string;
Return a fully-qualified catalog resource name string.
Name | Description |
catalog |
string
|
Type | Description |
string | {string} Resource name string. |
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.
Type | Description |
Promise<void> | {Promise} A promise that resolves when the client is closed. |
getProjectId()
getProjectId(): Promise<string>;
Type | Description |
Promise<string> |
getProjectId(callback)
getProjectId(callback: Callback<string, undefined, undefined>): void;
Name | Description |
callback |
Callback<string, undefined, undefined>
|
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.
Type | Description |
Promise<{ [name: string]: Function; }> | {Promise} A promise that resolves to an authenticated service stub. |
matchCatalogFromCatalogName(catalogName)
matchCatalogFromCatalogName(catalogName: string): string | number;
Parse the catalog from Catalog resource.
Name | Description |
catalogName |
string
A fully-qualified path representing Catalog resource. |
Type | Description |
string | number | {string} A string representing the catalog. |
matchCatalogFromVersionName(versionName)
matchCatalogFromVersionName(versionName: string): string | number;
Parse the catalog from Version resource.
Name | Description |
versionName |
string
A fully-qualified path representing Version resource. |
Type | Description |
string | number | {string} A string representing the catalog. |
matchProductFromProductName(productName)
matchProductFromProductName(productName: string): string | number;
Parse the product from Product resource.
Name | Description |
productName |
string
A fully-qualified path representing Product resource. |
Type | Description |
string | number | {string} A string representing the product. |
matchProductFromVersionName(versionName)
matchProductFromVersionName(versionName: string): string | number;
Parse the product from Version resource.
Name | Description |
versionName |
string
A fully-qualified path representing Version resource. |
Type | Description |
string | number | {string} A string representing the product. |
matchVersionFromVersionName(versionName)
matchVersionFromVersionName(versionName: string): string | number;
Parse the version from Version resource.
Name | Description |
versionName |
string
A fully-qualified path representing Version resource. |
Type | Description |
string | number | {string} A string representing the version. |
productPath(product)
productPath(product: string): string;
Return a fully-qualified product resource name string.
Name | Description |
product |
string
|
Type | Description |
string | {string} Resource name string. |
searchCatalogs(request, options)
searchCatalogs(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, options?: CallOptions): Promise<[
protos.google.cloud.privatecatalog.v1beta1.ICatalog[],
protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest | null,
protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsResponse
]>;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest
|
options |
CallOptions
|
Type | Description |
Promise<[ protos.google.cloud.privatecatalog.v1beta1.ICatalog[], protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest | null, protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsResponse ]> |
searchCatalogs(request, options, callback)
searchCatalogs(request: protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, options: CallOptions, callback: PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.ICatalog>): void;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest
|
options |
CallOptions
|
callback |
PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.ICatalog>
|
Type | Description |
void |
searchCatalogs(request, callback)
searchCatalogs(request: protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, callback: PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.ICatalog>): void;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest
|
callback |
PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.ICatalog>
|
Type | Description |
void |
searchCatalogsAsync(request, options)
searchCatalogsAsync(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.privatecatalog.v1beta1.ICatalog>;
Equivalent to searchCatalogs
, but returns an iterable object.
for
-await
-of
syntax is used with the iterable to get response elements on-demand.
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Type | Description |
AsyncIterable<protos.google.cloud.privatecatalog.v1beta1.ICatalog> | {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 [Catalog]. 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. |
searchCatalogsStream(request, options)
searchCatalogsStream(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest, options?: CallOptions): Transform;
Equivalent to method.name.toCamelCase()
, but returns a NodeJS Stream object.
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchCatalogsRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Type | Description |
Transform | {Stream} An object stream which emits an object representing [Catalog] on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using |
searchProducts(request, options)
searchProducts(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, options?: CallOptions): Promise<[
protos.google.cloud.privatecatalog.v1beta1.IProduct[],
protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest | null,
protos.google.cloud.privatecatalog.v1beta1.ISearchProductsResponse
]>;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest
|
options |
CallOptions
|
Type | Description |
Promise<[ protos.google.cloud.privatecatalog.v1beta1.IProduct[], protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest | null, protos.google.cloud.privatecatalog.v1beta1.ISearchProductsResponse ]> |
searchProducts(request, options, callback)
searchProducts(request: protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, options: CallOptions, callback: PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchProductsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.IProduct>): void;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest
|
options |
CallOptions
|
callback |
PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchProductsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.IProduct>
|
Type | Description |
void |
searchProducts(request, callback)
searchProducts(request: protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, callback: PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchProductsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.IProduct>): void;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest
|
callback |
PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchProductsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.IProduct>
|
Type | Description |
void |
searchProductsAsync(request, options)
searchProductsAsync(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.privatecatalog.v1beta1.IProduct>;
Equivalent to searchProducts
, but returns an iterable object.
for
-await
-of
syntax is used with the iterable to get response elements on-demand.
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Type | Description |
AsyncIterable<protos.google.cloud.privatecatalog.v1beta1.IProduct> | {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 [Product]. 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. |
searchProductsStream(request, options)
searchProductsStream(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest, options?: CallOptions): Transform;
Equivalent to method.name.toCamelCase()
, but returns a NodeJS Stream object.
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchProductsRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Type | Description |
Transform | {Stream} An object stream which emits an object representing [Product] on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using |
searchVersions(request, options)
searchVersions(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, options?: CallOptions): Promise<[
protos.google.cloud.privatecatalog.v1beta1.IVersion[],
protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest | null,
protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsResponse
]>;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest
|
options |
CallOptions
|
Type | Description |
Promise<[ protos.google.cloud.privatecatalog.v1beta1.IVersion[], protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest | null, protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsResponse ]> |
searchVersions(request, options, callback)
searchVersions(request: protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, options: CallOptions, callback: PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.IVersion>): void;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest
|
options |
CallOptions
|
callback |
PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.IVersion>
|
Type | Description |
void |
searchVersions(request, callback)
searchVersions(request: protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, callback: PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.IVersion>): void;
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest
|
callback |
PaginationCallback<protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsResponse | null | undefined, protos.google.cloud.privatecatalog.v1beta1.IVersion>
|
Type | Description |
void |
searchVersionsAsync(request, options)
searchVersionsAsync(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.privatecatalog.v1beta1.IVersion>;
Equivalent to searchVersions
, but returns an iterable object.
for
-await
-of
syntax is used with the iterable to get response elements on-demand.
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Type | Description |
AsyncIterable<protos.google.cloud.privatecatalog.v1beta1.IVersion> | {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 [Version]. 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. |
searchVersionsStream(request, options)
searchVersionsStream(request?: protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest, options?: CallOptions): Transform;
Equivalent to method.name.toCamelCase()
, but returns a NodeJS Stream object.
Name | Description |
request |
protos.google.cloud.privatecatalog.v1beta1.ISearchVersionsRequest
The request object that will be sent. |
options |
CallOptions
Call options. See CallOptions for more details. |
Type | Description |
Transform | {Stream} An object stream which emits an object representing [Version] on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using |
versionPath(catalog, product, version)
versionPath(catalog: string, product: string, version: string): string;
Return a fully-qualified version resource name string.
Name | Description |
catalog |
string
|
product |
string
|
version |
string
|
Type | Description |
string | {string} Resource name string. |