@google-cloud/discoveryengine 1.4.1 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/README.md +2 -0
- package/build/protos/google/cloud/discoveryengine/v1alpha/rank_service.proto +115 -0
- package/build/protos/protos.d.ts +384 -0
- package/build/protos/protos.js +906 -0
- package/build/protos/protos.json +90 -1
- package/build/src/v1/completion_service_client.js +10 -7
- package/build/src/v1/conversational_search_service_client.js +10 -7
- package/build/src/v1/data_store_service_client.js +10 -7
- package/build/src/v1/document_service_client.js +10 -7
- package/build/src/v1/engine_service_client.js +10 -7
- package/build/src/v1/schema_service_client.js +10 -7
- package/build/src/v1/search_service_client.js +10 -7
- package/build/src/v1/site_search_engine_service_client.js +10 -7
- package/build/src/v1/user_event_service_client.js +10 -7
- package/build/src/v1alpha/acl_config_service_client.js +10 -7
- package/build/src/v1alpha/chunk_service_client.js +10 -7
- package/build/src/v1alpha/completion_service_client.js +10 -7
- package/build/src/v1alpha/conversational_search_service_client.js +10 -7
- package/build/src/v1alpha/data_store_service_client.js +10 -7
- package/build/src/v1alpha/document_service_client.js +10 -7
- package/build/src/v1alpha/engine_service_client.js +10 -7
- package/build/src/v1alpha/estimate_billing_service_client.js +10 -7
- package/build/src/v1alpha/index.d.ts +1 -0
- package/build/src/v1alpha/index.js +3 -1
- package/build/src/v1alpha/rank_service_client.d.ts +1254 -0
- package/build/src/v1alpha/rank_service_client.js +1796 -0
- package/build/src/v1alpha/rank_service_client_config.json +30 -0
- package/build/src/v1alpha/recommendation_service_client.js +10 -7
- package/build/src/v1alpha/schema_service_client.js +10 -7
- package/build/src/v1alpha/search_service_client.js +10 -7
- package/build/src/v1alpha/search_tuning_service_client.js +10 -7
- package/build/src/v1alpha/serving_config_service_client.js +10 -7
- package/build/src/v1alpha/site_search_engine_service_client.js +10 -7
- package/build/src/v1alpha/user_event_service_client.js +10 -7
- package/build/src/v1beta/completion_service_client.js +10 -7
- package/build/src/v1beta/conversational_search_service_client.js +10 -7
- package/build/src/v1beta/data_store_service_client.js +10 -7
- package/build/src/v1beta/document_service_client.js +10 -7
- package/build/src/v1beta/engine_service_client.js +10 -7
- package/build/src/v1beta/recommendation_service_client.js +10 -7
- package/build/src/v1beta/schema_service_client.js +10 -7
- package/build/src/v1beta/search_service_client.js +10 -7
- package/build/src/v1beta/search_tuning_service_client.js +10 -7
- package/build/src/v1beta/serving_config_service_client.js +10 -7
- package/build/src/v1beta/site_search_engine_service_client.js +10 -7
- package/build/src/v1beta/user_event_service_client.js +10 -7
- package/package.json +1 -1
@@ -74,7 +74,7 @@ class DocumentServiceClient {
|
|
74
74
|
* ```
|
75
75
|
*/
|
76
76
|
constructor(opts, gaxInstance) {
|
77
|
-
var _a, _b, _c, _d;
|
77
|
+
var _a, _b, _c, _d, _e;
|
78
78
|
this._terminated = false;
|
79
79
|
this.descriptors = {
|
80
80
|
page: {},
|
@@ -89,14 +89,17 @@ class DocumentServiceClient {
|
|
89
89
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
90
90
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
91
91
|
}
|
92
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
93
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
94
|
+
: undefined;
|
92
95
|
this._universeDomain =
|
93
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
96
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
94
97
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
95
98
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
96
99
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
97
100
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
98
|
-
const clientConfig = (
|
99
|
-
const fallback = (
|
101
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
102
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
100
103
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
101
104
|
// Request numeric enum values if REST transport is used.
|
102
105
|
opts.numericEnums = true;
|
@@ -127,7 +130,7 @@ class DocumentServiceClient {
|
|
127
130
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
128
131
|
// Determine the client header string.
|
129
132
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
130
|
-
if (typeof process
|
133
|
+
if (typeof process === 'object' && 'versions' in process) {
|
131
134
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
132
135
|
}
|
133
136
|
else {
|
@@ -349,7 +352,7 @@ class DocumentServiceClient {
|
|
349
352
|
* @returns {string} The DNS address for this service.
|
350
353
|
*/
|
351
354
|
static get servicePath() {
|
352
|
-
if (typeof process
|
355
|
+
if (typeof process === 'object' &&
|
353
356
|
typeof process.emitWarning === 'function') {
|
354
357
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
355
358
|
}
|
@@ -361,7 +364,7 @@ class DocumentServiceClient {
|
|
361
364
|
* @returns {string} The DNS address for this service.
|
362
365
|
*/
|
363
366
|
static get apiEndpoint() {
|
364
|
-
if (typeof process
|
367
|
+
if (typeof process === 'object' &&
|
365
368
|
typeof process.emitWarning === 'function') {
|
366
369
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
367
370
|
}
|
@@ -73,7 +73,7 @@ class EngineServiceClient {
|
|
73
73
|
* ```
|
74
74
|
*/
|
75
75
|
constructor(opts, gaxInstance) {
|
76
|
-
var _a, _b, _c, _d;
|
76
|
+
var _a, _b, _c, _d, _e;
|
77
77
|
this._terminated = false;
|
78
78
|
this.descriptors = {
|
79
79
|
page: {},
|
@@ -88,14 +88,17 @@ class EngineServiceClient {
|
|
88
88
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
89
89
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
90
90
|
}
|
91
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
92
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
93
|
+
: undefined;
|
91
94
|
this._universeDomain =
|
92
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
95
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
93
96
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
94
97
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
95
98
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
96
99
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
97
|
-
const clientConfig = (
|
98
|
-
const fallback = (
|
100
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
101
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
99
102
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
100
103
|
// Request numeric enum values if REST transport is used.
|
101
104
|
opts.numericEnums = true;
|
@@ -126,7 +129,7 @@ class EngineServiceClient {
|
|
126
129
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
127
130
|
// Determine the client header string.
|
128
131
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
129
|
-
if (typeof process
|
132
|
+
if (typeof process === 'object' && 'versions' in process) {
|
130
133
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
131
134
|
}
|
132
135
|
else {
|
@@ -345,7 +348,7 @@ class EngineServiceClient {
|
|
345
348
|
* @returns {string} The DNS address for this service.
|
346
349
|
*/
|
347
350
|
static get servicePath() {
|
348
|
-
if (typeof process
|
351
|
+
if (typeof process === 'object' &&
|
349
352
|
typeof process.emitWarning === 'function') {
|
350
353
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
351
354
|
}
|
@@ -357,7 +360,7 @@ class EngineServiceClient {
|
|
357
360
|
* @returns {string} The DNS address for this service.
|
358
361
|
*/
|
359
362
|
static get apiEndpoint() {
|
360
|
-
if (typeof process
|
363
|
+
if (typeof process === 'object' &&
|
361
364
|
typeof process.emitWarning === 'function') {
|
362
365
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
363
366
|
}
|
@@ -72,7 +72,7 @@ class RecommendationServiceClient {
|
|
72
72
|
* ```
|
73
73
|
*/
|
74
74
|
constructor(opts, gaxInstance) {
|
75
|
-
var _a, _b, _c, _d;
|
75
|
+
var _a, _b, _c, _d, _e;
|
76
76
|
this._terminated = false;
|
77
77
|
this.descriptors = {
|
78
78
|
page: {},
|
@@ -88,14 +88,17 @@ class RecommendationServiceClient {
|
|
88
88
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
89
89
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
90
90
|
}
|
91
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
92
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
93
|
+
: undefined;
|
91
94
|
this._universeDomain =
|
92
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
95
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
93
96
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
94
97
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
95
98
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
96
99
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
97
|
-
const clientConfig = (
|
98
|
-
const fallback = (
|
100
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
101
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
99
102
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
100
103
|
// Request numeric enum values if REST transport is used.
|
101
104
|
opts.numericEnums = true;
|
@@ -126,7 +129,7 @@ class RecommendationServiceClient {
|
|
126
129
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
127
130
|
// Determine the client header string.
|
128
131
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
129
|
-
if (typeof process
|
132
|
+
if (typeof process === 'object' && 'versions' in process) {
|
130
133
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
131
134
|
}
|
132
135
|
else {
|
@@ -224,7 +227,7 @@ class RecommendationServiceClient {
|
|
224
227
|
* @returns {string} The DNS address for this service.
|
225
228
|
*/
|
226
229
|
static get servicePath() {
|
227
|
-
if (typeof process
|
230
|
+
if (typeof process === 'object' &&
|
228
231
|
typeof process.emitWarning === 'function') {
|
229
232
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
230
233
|
}
|
@@ -236,7 +239,7 @@ class RecommendationServiceClient {
|
|
236
239
|
* @returns {string} The DNS address for this service.
|
237
240
|
*/
|
238
241
|
static get apiEndpoint() {
|
239
|
-
if (typeof process
|
242
|
+
if (typeof process === 'object' &&
|
240
243
|
typeof process.emitWarning === 'function') {
|
241
244
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
242
245
|
}
|
@@ -72,7 +72,7 @@ class SchemaServiceClient {
|
|
72
72
|
* ```
|
73
73
|
*/
|
74
74
|
constructor(opts, gaxInstance) {
|
75
|
-
var _a, _b, _c, _d;
|
75
|
+
var _a, _b, _c, _d, _e;
|
76
76
|
this._terminated = false;
|
77
77
|
this.descriptors = {
|
78
78
|
page: {},
|
@@ -87,14 +87,17 @@ class SchemaServiceClient {
|
|
87
87
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
88
88
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
89
89
|
}
|
90
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
91
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
92
|
+
: undefined;
|
90
93
|
this._universeDomain =
|
91
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
94
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
92
95
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
93
96
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
94
97
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
95
98
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
96
|
-
const clientConfig = (
|
97
|
-
const fallback = (
|
99
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
100
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
98
101
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
99
102
|
// Request numeric enum values if REST transport is used.
|
100
103
|
opts.numericEnums = true;
|
@@ -125,7 +128,7 @@ class SchemaServiceClient {
|
|
125
128
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
126
129
|
// Determine the client header string.
|
127
130
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
128
|
-
if (typeof process
|
131
|
+
if (typeof process === 'object' && 'versions' in process) {
|
129
132
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
130
133
|
}
|
131
134
|
else {
|
@@ -346,7 +349,7 @@ class SchemaServiceClient {
|
|
346
349
|
* @returns {string} The DNS address for this service.
|
347
350
|
*/
|
348
351
|
static get servicePath() {
|
349
|
-
if (typeof process
|
352
|
+
if (typeof process === 'object' &&
|
350
353
|
typeof process.emitWarning === 'function') {
|
351
354
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
352
355
|
}
|
@@ -358,7 +361,7 @@ class SchemaServiceClient {
|
|
358
361
|
* @returns {string} The DNS address for this service.
|
359
362
|
*/
|
360
363
|
static get apiEndpoint() {
|
361
|
-
if (typeof process
|
364
|
+
if (typeof process === 'object' &&
|
362
365
|
typeof process.emitWarning === 'function') {
|
363
366
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
364
367
|
}
|
@@ -72,7 +72,7 @@ class SearchServiceClient {
|
|
72
72
|
* ```
|
73
73
|
*/
|
74
74
|
constructor(opts, gaxInstance) {
|
75
|
-
var _a, _b, _c, _d;
|
75
|
+
var _a, _b, _c, _d, _e;
|
76
76
|
this._terminated = false;
|
77
77
|
this.descriptors = {
|
78
78
|
page: {},
|
@@ -87,14 +87,17 @@ class SearchServiceClient {
|
|
87
87
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
88
88
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
89
89
|
}
|
90
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
91
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
92
|
+
: undefined;
|
90
93
|
this._universeDomain =
|
91
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
94
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
92
95
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
93
96
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
94
97
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
95
98
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
96
|
-
const clientConfig = (
|
97
|
-
const fallback = (
|
99
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
100
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
98
101
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
99
102
|
// Request numeric enum values if REST transport is used.
|
100
103
|
opts.numericEnums = true;
|
@@ -125,7 +128,7 @@ class SearchServiceClient {
|
|
125
128
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
126
129
|
// Determine the client header string.
|
127
130
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
128
|
-
if (typeof process
|
131
|
+
if (typeof process === 'object' && 'versions' in process) {
|
129
132
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
130
133
|
}
|
131
134
|
else {
|
@@ -231,7 +234,7 @@ class SearchServiceClient {
|
|
231
234
|
* @returns {string} The DNS address for this service.
|
232
235
|
*/
|
233
236
|
static get servicePath() {
|
234
|
-
if (typeof process
|
237
|
+
if (typeof process === 'object' &&
|
235
238
|
typeof process.emitWarning === 'function') {
|
236
239
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
237
240
|
}
|
@@ -243,7 +246,7 @@ class SearchServiceClient {
|
|
243
246
|
* @returns {string} The DNS address for this service.
|
244
247
|
*/
|
245
248
|
static get apiEndpoint() {
|
246
|
-
if (typeof process
|
249
|
+
if (typeof process === 'object' &&
|
247
250
|
typeof process.emitWarning === 'function') {
|
248
251
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
249
252
|
}
|
@@ -72,7 +72,7 @@ class SearchTuningServiceClient {
|
|
72
72
|
* ```
|
73
73
|
*/
|
74
74
|
constructor(opts, gaxInstance) {
|
75
|
-
var _a, _b, _c, _d;
|
75
|
+
var _a, _b, _c, _d, _e;
|
76
76
|
this._terminated = false;
|
77
77
|
this.descriptors = {
|
78
78
|
page: {},
|
@@ -87,14 +87,17 @@ class SearchTuningServiceClient {
|
|
87
87
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
88
88
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
89
89
|
}
|
90
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
91
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
92
|
+
: undefined;
|
90
93
|
this._universeDomain =
|
91
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
94
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
92
95
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
93
96
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
94
97
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
95
98
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
96
|
-
const clientConfig = (
|
97
|
-
const fallback = (
|
99
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
100
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
98
101
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
99
102
|
// Request numeric enum values if REST transport is used.
|
100
103
|
opts.numericEnums = true;
|
@@ -125,7 +128,7 @@ class SearchTuningServiceClient {
|
|
125
128
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
126
129
|
// Determine the client header string.
|
127
130
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
128
|
-
if (typeof process
|
131
|
+
if (typeof process === 'object' && 'versions' in process) {
|
129
132
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
130
133
|
}
|
131
134
|
else {
|
@@ -326,7 +329,7 @@ class SearchTuningServiceClient {
|
|
326
329
|
* @returns {string} The DNS address for this service.
|
327
330
|
*/
|
328
331
|
static get servicePath() {
|
329
|
-
if (typeof process
|
332
|
+
if (typeof process === 'object' &&
|
330
333
|
typeof process.emitWarning === 'function') {
|
331
334
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
332
335
|
}
|
@@ -338,7 +341,7 @@ class SearchTuningServiceClient {
|
|
338
341
|
* @returns {string} The DNS address for this service.
|
339
342
|
*/
|
340
343
|
static get apiEndpoint() {
|
341
|
-
if (typeof process
|
344
|
+
if (typeof process === 'object' &&
|
342
345
|
typeof process.emitWarning === 'function') {
|
343
346
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
344
347
|
}
|
@@ -73,7 +73,7 @@ class ServingConfigServiceClient {
|
|
73
73
|
* ```
|
74
74
|
*/
|
75
75
|
constructor(opts, gaxInstance) {
|
76
|
-
var _a, _b, _c, _d;
|
76
|
+
var _a, _b, _c, _d, _e;
|
77
77
|
this._terminated = false;
|
78
78
|
this.descriptors = {
|
79
79
|
page: {},
|
@@ -88,14 +88,17 @@ class ServingConfigServiceClient {
|
|
88
88
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
89
89
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
90
90
|
}
|
91
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
92
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
93
|
+
: undefined;
|
91
94
|
this._universeDomain =
|
92
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
95
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
93
96
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
94
97
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
95
98
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
96
99
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
97
|
-
const clientConfig = (
|
98
|
-
const fallback = (
|
100
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
101
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
99
102
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
100
103
|
// Request numeric enum values if REST transport is used.
|
101
104
|
opts.numericEnums = true;
|
@@ -126,7 +129,7 @@ class ServingConfigServiceClient {
|
|
126
129
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
127
130
|
// Determine the client header string.
|
128
131
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
129
|
-
if (typeof process
|
132
|
+
if (typeof process === 'object' && 'versions' in process) {
|
130
133
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
131
134
|
}
|
132
135
|
else {
|
@@ -236,7 +239,7 @@ class ServingConfigServiceClient {
|
|
236
239
|
* @returns {string} The DNS address for this service.
|
237
240
|
*/
|
238
241
|
static get servicePath() {
|
239
|
-
if (typeof process
|
242
|
+
if (typeof process === 'object' &&
|
240
243
|
typeof process.emitWarning === 'function') {
|
241
244
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
242
245
|
}
|
@@ -248,7 +251,7 @@ class ServingConfigServiceClient {
|
|
248
251
|
* @returns {string} The DNS address for this service.
|
249
252
|
*/
|
250
253
|
static get apiEndpoint() {
|
251
|
-
if (typeof process
|
254
|
+
if (typeof process === 'object' &&
|
252
255
|
typeof process.emitWarning === 'function') {
|
253
256
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
254
257
|
}
|
@@ -72,7 +72,7 @@ class SiteSearchEngineServiceClient {
|
|
72
72
|
* ```
|
73
73
|
*/
|
74
74
|
constructor(opts, gaxInstance) {
|
75
|
-
var _a, _b, _c, _d;
|
75
|
+
var _a, _b, _c, _d, _e;
|
76
76
|
this._terminated = false;
|
77
77
|
this.descriptors = {
|
78
78
|
page: {},
|
@@ -88,14 +88,17 @@ class SiteSearchEngineServiceClient {
|
|
88
88
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
89
89
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
90
90
|
}
|
91
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
92
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
93
|
+
: undefined;
|
91
94
|
this._universeDomain =
|
92
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
95
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
93
96
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
94
97
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
95
98
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
96
99
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
97
|
-
const clientConfig = (
|
98
|
-
const fallback = (
|
100
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
101
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
99
102
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
100
103
|
// Request numeric enum values if REST transport is used.
|
101
104
|
opts.numericEnums = true;
|
@@ -126,7 +129,7 @@ class SiteSearchEngineServiceClient {
|
|
126
129
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
127
130
|
// Determine the client header string.
|
128
131
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
129
|
-
if (typeof process
|
132
|
+
if (typeof process === 'object' && 'versions' in process) {
|
130
133
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
131
134
|
}
|
132
135
|
else {
|
@@ -370,7 +373,7 @@ class SiteSearchEngineServiceClient {
|
|
370
373
|
* @returns {string} The DNS address for this service.
|
371
374
|
*/
|
372
375
|
static get servicePath() {
|
373
|
-
if (typeof process
|
376
|
+
if (typeof process === 'object' &&
|
374
377
|
typeof process.emitWarning === 'function') {
|
375
378
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
376
379
|
}
|
@@ -382,7 +385,7 @@ class SiteSearchEngineServiceClient {
|
|
382
385
|
* @returns {string} The DNS address for this service.
|
383
386
|
*/
|
384
387
|
static get apiEndpoint() {
|
385
|
-
if (typeof process
|
388
|
+
if (typeof process === 'object' &&
|
386
389
|
typeof process.emitWarning === 'function') {
|
387
390
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
388
391
|
}
|
@@ -72,7 +72,7 @@ class UserEventServiceClient {
|
|
72
72
|
* ```
|
73
73
|
*/
|
74
74
|
constructor(opts, gaxInstance) {
|
75
|
-
var _a, _b, _c, _d;
|
75
|
+
var _a, _b, _c, _d, _e;
|
76
76
|
this._terminated = false;
|
77
77
|
this.descriptors = {
|
78
78
|
page: {},
|
@@ -87,14 +87,17 @@ class UserEventServiceClient {
|
|
87
87
|
(opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== (opts === null || opts === void 0 ? void 0 : opts.universeDomain)) {
|
88
88
|
throw new Error('Please set either universe_domain or universeDomain, but not both.');
|
89
89
|
}
|
90
|
+
const universeDomainEnvVar = typeof process === 'object' && typeof process.env === 'object'
|
91
|
+
? process.env['GOOGLE_CLOUD_UNIVERSE_DOMAIN']
|
92
|
+
: undefined;
|
90
93
|
this._universeDomain =
|
91
|
-
(_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : 'googleapis.com';
|
94
|
+
(_c = (_b = (_a = opts === null || opts === void 0 ? void 0 : opts.universeDomain) !== null && _a !== void 0 ? _a : opts === null || opts === void 0 ? void 0 : opts.universe_domain) !== null && _b !== void 0 ? _b : universeDomainEnvVar) !== null && _c !== void 0 ? _c : 'googleapis.com';
|
92
95
|
this._servicePath = 'discoveryengine.' + this._universeDomain;
|
93
96
|
const servicePath = (opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint) || this._servicePath;
|
94
97
|
this._providedCustomServicePath = !!((opts === null || opts === void 0 ? void 0 : opts.servicePath) || (opts === null || opts === void 0 ? void 0 : opts.apiEndpoint));
|
95
98
|
const port = (opts === null || opts === void 0 ? void 0 : opts.port) || staticMembers.port;
|
96
|
-
const clientConfig = (
|
97
|
-
const fallback = (
|
99
|
+
const clientConfig = (_d = opts === null || opts === void 0 ? void 0 : opts.clientConfig) !== null && _d !== void 0 ? _d : {};
|
100
|
+
const fallback = (_e = opts === null || opts === void 0 ? void 0 : opts.fallback) !== null && _e !== void 0 ? _e : (typeof window !== 'undefined' && typeof (window === null || window === void 0 ? void 0 : window.fetch) === 'function');
|
98
101
|
opts = Object.assign({ servicePath, port, clientConfig, fallback }, opts);
|
99
102
|
// Request numeric enum values if REST transport is used.
|
100
103
|
opts.numericEnums = true;
|
@@ -125,7 +128,7 @@ class UserEventServiceClient {
|
|
125
128
|
this.locationsClient = new this._gaxModule.LocationsClient(this._gaxGrpc, opts);
|
126
129
|
// Determine the client header string.
|
127
130
|
const clientHeader = [`gax/${this._gaxModule.version}`, `gapic/${version}`];
|
128
|
-
if (typeof process
|
131
|
+
if (typeof process === 'object' && 'versions' in process) {
|
129
132
|
clientHeader.push(`gl-node/${process.versions.node}`);
|
130
133
|
}
|
131
134
|
else {
|
@@ -330,7 +333,7 @@ class UserEventServiceClient {
|
|
330
333
|
* @returns {string} The DNS address for this service.
|
331
334
|
*/
|
332
335
|
static get servicePath() {
|
333
|
-
if (typeof process
|
336
|
+
if (typeof process === 'object' &&
|
334
337
|
typeof process.emitWarning === 'function') {
|
335
338
|
process.emitWarning('Static servicePath is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
336
339
|
}
|
@@ -342,7 +345,7 @@ class UserEventServiceClient {
|
|
342
345
|
* @returns {string} The DNS address for this service.
|
343
346
|
*/
|
344
347
|
static get apiEndpoint() {
|
345
|
-
if (typeof process
|
348
|
+
if (typeof process === 'object' &&
|
346
349
|
typeof process.emitWarning === 'function') {
|
347
350
|
process.emitWarning('Static apiEndpoint is deprecated, please use the instance method instead.', 'DeprecationWarning');
|
348
351
|
}
|