@googleapis/discoveryengine 26.1.0 → 27.0.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 +12 -0
- package/build/tsconfig.tsbuildinfo +1 -1
- package/build/v1.d.ts +1055 -8
- package/build/v1.js +326 -0
- package/build/v1.js.map +1 -1
- package/build/v1alpha.d.ts +3547 -113
- package/build/v1alpha.js +1040 -66
- package/build/v1alpha.js.map +1 -1
- package/build/v1beta.d.ts +514 -7
- package/build/v1beta.js +128 -0
- package/build/v1beta.js.map +1 -1
- package/package.json +1 -1
- package/v1.ts +2294 -373
- package/v1alpha.ts +24898 -18973
- package/v1beta.ts +857 -7
package/v1.ts
CHANGED
|
@@ -846,7 +846,7 @@ export namespace discoveryengine_v1 {
|
|
|
846
846
|
*/
|
|
847
847
|
userInfo?: Schema$GoogleCloudDiscoveryengineV1UserInfo;
|
|
848
848
|
/**
|
|
849
|
-
* A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128
|
|
849
|
+
* Optional. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128
|
|
850
850
|
*/
|
|
851
851
|
userPseudoId?: string | null;
|
|
852
852
|
}
|
|
@@ -2724,6 +2724,10 @@ export namespace discoveryengine_v1 {
|
|
|
2724
2724
|
* Optional. Configuration for configurable billing approach. See
|
|
2725
2725
|
*/
|
|
2726
2726
|
configurableBillingApproach?: string | null;
|
|
2727
|
+
/**
|
|
2728
|
+
* Output only. The timestamp when configurable_billing_approach was last updated.
|
|
2729
|
+
*/
|
|
2730
|
+
configurableBillingApproachUpdateTime?: string | null;
|
|
2727
2731
|
/**
|
|
2728
2732
|
* Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.
|
|
2729
2733
|
*/
|
|
@@ -2856,6 +2860,19 @@ export namespace discoveryengine_v1 {
|
|
|
2856
2860
|
*/
|
|
2857
2861
|
userTriggeredCrawlRate?: Schema$GoogleCloudDiscoveryengineV1alphaCrawlRateTimeSeries;
|
|
2858
2862
|
}
|
|
2863
|
+
/**
|
|
2864
|
+
* Metadata related to the progress of the AgentService.DeleteAgent operation. This will be returned by the google.longrunning.Operation.metadata field.
|
|
2865
|
+
*/
|
|
2866
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaDeleteAgentMetadata {
|
|
2867
|
+
/**
|
|
2868
|
+
* Operation create time.
|
|
2869
|
+
*/
|
|
2870
|
+
createTime?: string | null;
|
|
2871
|
+
/**
|
|
2872
|
+
* Operation last update time. If the operation is done, this is also the finish time.
|
|
2873
|
+
*/
|
|
2874
|
+
updateTime?: string | null;
|
|
2875
|
+
}
|
|
2859
2876
|
/**
|
|
2860
2877
|
* Metadata related to the progress of the CmekConfigService.DeleteCmekConfig operation. This will be returned by the google.longrunning.Operation.metadata field.
|
|
2861
2878
|
*/
|
|
@@ -2969,6 +2986,19 @@ export namespace discoveryengine_v1 {
|
|
|
2969
2986
|
*/
|
|
2970
2987
|
updateTime?: string | null;
|
|
2971
2988
|
}
|
|
2989
|
+
/**
|
|
2990
|
+
* Metadata related to the progress of the UserStoreService.DeleteUserStore operation. This will be returned by the google.longrunning.Operation.metadata field. Delete UserStore will delete all the end users under the user store, return the number of end users successfully deleted or failed to delete in the metadata.
|
|
2991
|
+
*/
|
|
2992
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaDeleteUserStoreMetadata {
|
|
2993
|
+
/**
|
|
2994
|
+
* The number of end users under the user store that failed to be deleted.
|
|
2995
|
+
*/
|
|
2996
|
+
failureCount?: string | null;
|
|
2997
|
+
/**
|
|
2998
|
+
* The number of end users under the user store that were successfully deleted.
|
|
2999
|
+
*/
|
|
3000
|
+
successCount?: string | null;
|
|
3001
|
+
}
|
|
2972
3002
|
/**
|
|
2973
3003
|
* Defines target endpoints used to connect to third-party sources.
|
|
2974
3004
|
*/
|
|
@@ -4009,6 +4039,10 @@ export namespace discoveryengine_v1 {
|
|
|
4009
4039
|
* Metadata and configurations for a Google Cloud project in the service.
|
|
4010
4040
|
*/
|
|
4011
4041
|
export interface Schema$GoogleCloudDiscoveryengineV1alphaProject {
|
|
4042
|
+
/**
|
|
4043
|
+
* Output only. The current status of the project's configurable billing.
|
|
4044
|
+
*/
|
|
4045
|
+
configurableBillingStatus?: Schema$GoogleCloudDiscoveryengineV1alphaProjectConfigurableBillingStatus;
|
|
4012
4046
|
/**
|
|
4013
4047
|
* Output only. The timestamp when this project is created.
|
|
4014
4048
|
*/
|
|
@@ -4034,6 +4068,23 @@ export namespace discoveryengine_v1 {
|
|
|
4034
4068
|
]: Schema$GoogleCloudDiscoveryengineV1alphaProjectServiceTerms;
|
|
4035
4069
|
} | null;
|
|
4036
4070
|
}
|
|
4071
|
+
/**
|
|
4072
|
+
* Represents the currently effective configurable billing parameters. These values are derived from the customer's subscription history stored internally and reflect the thresholds actively being used for billing purposes at the time of the GetProject call. This includes the start_time of the subscription and may differ from the values in `customer_provided_config` due to billing rules (e.g., scale-downs taking effect only at the start of a new month).
|
|
4073
|
+
*/
|
|
4074
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaProjectConfigurableBillingStatus {
|
|
4075
|
+
/**
|
|
4076
|
+
* Optional. The currently effective Indexing Core threshold. This is the threshold against which Indexing Core usage is compared for overage calculations.
|
|
4077
|
+
*/
|
|
4078
|
+
effectiveIndexingCoreThreshold?: string | null;
|
|
4079
|
+
/**
|
|
4080
|
+
* Optional. The currently effective Search QPM threshold in queries per minute. This is the threshold against which QPM usage is compared for overage calculations.
|
|
4081
|
+
*/
|
|
4082
|
+
effectiveSearchQpmThreshold?: string | null;
|
|
4083
|
+
/**
|
|
4084
|
+
* Optional. The start time of the currently active billing subscription.
|
|
4085
|
+
*/
|
|
4086
|
+
startTime?: string | null;
|
|
4087
|
+
}
|
|
4037
4088
|
/**
|
|
4038
4089
|
* Customer provided configurations.
|
|
4039
4090
|
*/
|
|
@@ -4051,6 +4102,10 @@ export namespace discoveryengine_v1 {
|
|
|
4051
4102
|
* Model Armor configuration to be used for sanitizing user prompts and LLM responses.
|
|
4052
4103
|
*/
|
|
4053
4104
|
modelArmorConfig?: Schema$GoogleCloudDiscoveryengineV1alphaProjectCustomerProvidedConfigNotebooklmConfigModelArmorConfig;
|
|
4105
|
+
/**
|
|
4106
|
+
* Optional. Whether to disable the notebook sharing feature for the project. Default to false if not specified.
|
|
4107
|
+
*/
|
|
4108
|
+
optOutNotebookSharing?: boolean | null;
|
|
4054
4109
|
}
|
|
4055
4110
|
/**
|
|
4056
4111
|
* Configuration for customer defined Model Armor templates to be used for sanitizing user prompts and LLM responses.
|
|
@@ -4623,7 +4678,7 @@ export namespace discoveryengine_v1 {
|
|
|
4623
4678
|
*/
|
|
4624
4679
|
userLabels?: {[key: string]: string} | null;
|
|
4625
4680
|
/**
|
|
4626
|
-
* A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
4681
|
+
* Optional. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
4627
4682
|
*/
|
|
4628
4683
|
userPseudoId?: string | null;
|
|
4629
4684
|
}
|
|
@@ -7276,6 +7331,10 @@ export namespace discoveryengine_v1 {
|
|
|
7276
7331
|
* Optional. Configuration for configurable billing approach. See
|
|
7277
7332
|
*/
|
|
7278
7333
|
configurableBillingApproach?: string | null;
|
|
7334
|
+
/**
|
|
7335
|
+
* Output only. The timestamp when configurable_billing_approach was last updated.
|
|
7336
|
+
*/
|
|
7337
|
+
configurableBillingApproachUpdateTime?: string | null;
|
|
7279
7338
|
/**
|
|
7280
7339
|
* Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.
|
|
7281
7340
|
*/
|
|
@@ -8282,6 +8341,10 @@ export namespace discoveryengine_v1 {
|
|
|
8282
8341
|
* Metadata and configurations for a Google Cloud project in the service.
|
|
8283
8342
|
*/
|
|
8284
8343
|
export interface Schema$GoogleCloudDiscoveryengineV1betaProject {
|
|
8344
|
+
/**
|
|
8345
|
+
* Output only. The current status of the project's configurable billing.
|
|
8346
|
+
*/
|
|
8347
|
+
configurableBillingStatus?: Schema$GoogleCloudDiscoveryengineV1betaProjectConfigurableBillingStatus;
|
|
8285
8348
|
/**
|
|
8286
8349
|
* Output only. The timestamp when this project is created.
|
|
8287
8350
|
*/
|
|
@@ -8305,6 +8368,23 @@ export namespace discoveryengine_v1 {
|
|
|
8305
8368
|
[key: string]: Schema$GoogleCloudDiscoveryengineV1betaProjectServiceTerms;
|
|
8306
8369
|
} | null;
|
|
8307
8370
|
}
|
|
8371
|
+
/**
|
|
8372
|
+
* Represents the currently effective configurable billing parameters. These values are derived from the customer's subscription history stored internally and reflect the thresholds actively being used for billing purposes at the time of the GetProject call. This includes the start_time of the subscription and may differ from the values in `customer_provided_config` due to billing rules (e.g., scale-downs taking effect only at the start of a new month).
|
|
8373
|
+
*/
|
|
8374
|
+
export interface Schema$GoogleCloudDiscoveryengineV1betaProjectConfigurableBillingStatus {
|
|
8375
|
+
/**
|
|
8376
|
+
* Optional. The currently effective Indexing Core threshold. This is the threshold against which Indexing Core usage is compared for overage calculations.
|
|
8377
|
+
*/
|
|
8378
|
+
effectiveIndexingCoreThreshold?: string | null;
|
|
8379
|
+
/**
|
|
8380
|
+
* Optional. The currently effective Search QPM threshold in queries per minute. This is the threshold against which QPM usage is compared for overage calculations.
|
|
8381
|
+
*/
|
|
8382
|
+
effectiveSearchQpmThreshold?: string | null;
|
|
8383
|
+
/**
|
|
8384
|
+
* Optional. The start time of the currently active billing subscription.
|
|
8385
|
+
*/
|
|
8386
|
+
startTime?: string | null;
|
|
8387
|
+
}
|
|
8308
8388
|
/**
|
|
8309
8389
|
* Customer provided configurations.
|
|
8310
8390
|
*/
|
|
@@ -8322,6 +8402,10 @@ export namespace discoveryengine_v1 {
|
|
|
8322
8402
|
* Model Armor configuration to be used for sanitizing user prompts and LLM responses.
|
|
8323
8403
|
*/
|
|
8324
8404
|
modelArmorConfig?: Schema$GoogleCloudDiscoveryengineV1betaProjectCustomerProvidedConfigNotebooklmConfigModelArmorConfig;
|
|
8405
|
+
/**
|
|
8406
|
+
* Optional. Whether to disable the notebook sharing feature for the project. Default to false if not specified.
|
|
8407
|
+
*/
|
|
8408
|
+
optOutNotebookSharing?: boolean | null;
|
|
8325
8409
|
}
|
|
8326
8410
|
/**
|
|
8327
8411
|
* Configuration for customer defined Model Armor templates to be used for sanitizing user prompts and LLM responses.
|
|
@@ -8692,7 +8776,7 @@ export namespace discoveryengine_v1 {
|
|
|
8692
8776
|
*/
|
|
8693
8777
|
userLabels?: {[key: string]: string} | null;
|
|
8694
8778
|
/**
|
|
8695
|
-
* A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
8779
|
+
* Optional. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
8696
8780
|
*/
|
|
8697
8781
|
userPseudoId?: string | null;
|
|
8698
8782
|
}
|
|
@@ -9382,6 +9466,31 @@ export namespace discoveryengine_v1 {
|
|
|
9382
9466
|
*/
|
|
9383
9467
|
userProfile?: string | null;
|
|
9384
9468
|
}
|
|
9469
|
+
/**
|
|
9470
|
+
* Configures metadata that is used for End User entities.
|
|
9471
|
+
*/
|
|
9472
|
+
export interface Schema$GoogleCloudDiscoveryengineV1betaUserStore {
|
|
9473
|
+
/**
|
|
9474
|
+
* Optional. The default subscription LicenseConfig for the UserStore, if UserStore.enable_license_auto_register is true, new users will automatically register under the default subscription. If default LicenseConfig doesn't have remaining license seats left, new users will not be assigned with license and will be blocked for Vertex AI Search features. This is used if `license_assignment_tier_rules` is not configured.
|
|
9475
|
+
*/
|
|
9476
|
+
defaultLicenseConfig?: string | null;
|
|
9477
|
+
/**
|
|
9478
|
+
* The display name of the User Store.
|
|
9479
|
+
*/
|
|
9480
|
+
displayName?: string | null;
|
|
9481
|
+
/**
|
|
9482
|
+
* Optional. Whether to enable license auto update for users in this User Store. If true, users with expired licenses will automatically be updated to use the default license config as long as the default license config has seats left.
|
|
9483
|
+
*/
|
|
9484
|
+
enableExpiredLicenseAutoUpdate?: boolean | null;
|
|
9485
|
+
/**
|
|
9486
|
+
* Optional. Whether to enable license auto register for users in this User Store. If true, new users will automatically register under the default license config as long as the default license config has seats left.
|
|
9487
|
+
*/
|
|
9488
|
+
enableLicenseAutoRegister?: boolean | null;
|
|
9489
|
+
/**
|
|
9490
|
+
* Immutable. The full resource name of the User Store, in the format of `projects/{project\}/locations/{location\}/userStores/{user_store\}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.
|
|
9491
|
+
*/
|
|
9492
|
+
name?: string | null;
|
|
9493
|
+
}
|
|
9385
9494
|
/**
|
|
9386
9495
|
* Config to store data store type configuration for workspace data
|
|
9387
9496
|
*/
|
|
@@ -10642,6 +10751,10 @@ export namespace discoveryengine_v1 {
|
|
|
10642
10751
|
* Optional. Configuration for configurable billing approach. See
|
|
10643
10752
|
*/
|
|
10644
10753
|
configurableBillingApproach?: string | null;
|
|
10754
|
+
/**
|
|
10755
|
+
* Output only. The timestamp when configurable_billing_approach was last updated.
|
|
10756
|
+
*/
|
|
10757
|
+
configurableBillingApproachUpdateTime?: string | null;
|
|
10645
10758
|
/**
|
|
10646
10759
|
* Immutable. The content config of the data store. If this field is unset, the server behavior defaults to ContentConfig.NO_CONTENT.
|
|
10647
10760
|
*/
|
|
@@ -12148,6 +12261,19 @@ export namespace discoveryengine_v1 {
|
|
|
12148
12261
|
*/
|
|
12149
12262
|
schemas?: Schema$GoogleCloudDiscoveryengineV1Schema[];
|
|
12150
12263
|
}
|
|
12264
|
+
/**
|
|
12265
|
+
* Response for ListServingConfigs method.
|
|
12266
|
+
*/
|
|
12267
|
+
export interface Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse {
|
|
12268
|
+
/**
|
|
12269
|
+
* Pagination token, if not returned indicates the last page.
|
|
12270
|
+
*/
|
|
12271
|
+
nextPageToken?: string | null;
|
|
12272
|
+
/**
|
|
12273
|
+
* All the ServingConfigs for a given dataStore.
|
|
12274
|
+
*/
|
|
12275
|
+
servingConfigs?: Schema$GoogleCloudDiscoveryengineV1ServingConfig[];
|
|
12276
|
+
}
|
|
12151
12277
|
/**
|
|
12152
12278
|
* Response for ListSessions method.
|
|
12153
12279
|
*/
|
|
@@ -12271,6 +12397,10 @@ export namespace discoveryengine_v1 {
|
|
|
12271
12397
|
* Metadata and configurations for a Google Cloud project in the service.
|
|
12272
12398
|
*/
|
|
12273
12399
|
export interface Schema$GoogleCloudDiscoveryengineV1Project {
|
|
12400
|
+
/**
|
|
12401
|
+
* Output only. The current status of the project's configurable billing.
|
|
12402
|
+
*/
|
|
12403
|
+
configurableBillingStatus?: Schema$GoogleCloudDiscoveryengineV1ProjectConfigurableBillingStatus;
|
|
12274
12404
|
/**
|
|
12275
12405
|
* Output only. The timestamp when this project is created.
|
|
12276
12406
|
*/
|
|
@@ -12294,6 +12424,23 @@ export namespace discoveryengine_v1 {
|
|
|
12294
12424
|
[key: string]: Schema$GoogleCloudDiscoveryengineV1ProjectServiceTerms;
|
|
12295
12425
|
} | null;
|
|
12296
12426
|
}
|
|
12427
|
+
/**
|
|
12428
|
+
* Represents the currently effective configurable billing parameters. These values are derived from the customer's subscription history stored internally and reflect the thresholds actively being used for billing purposes at the time of the GetProject call. This includes the start_time of the subscription and may differ from the values in `customer_provided_config` due to billing rules (e.g., scale-downs taking effect only at the start of a new month).
|
|
12429
|
+
*/
|
|
12430
|
+
export interface Schema$GoogleCloudDiscoveryengineV1ProjectConfigurableBillingStatus {
|
|
12431
|
+
/**
|
|
12432
|
+
* Optional. The currently effective Indexing Core threshold. This is the threshold against which Indexing Core usage is compared for overage calculations.
|
|
12433
|
+
*/
|
|
12434
|
+
effectiveIndexingCoreThreshold?: string | null;
|
|
12435
|
+
/**
|
|
12436
|
+
* Optional. The currently effective Search QPM threshold in queries per minute. This is the threshold against which QPM usage is compared for overage calculations.
|
|
12437
|
+
*/
|
|
12438
|
+
effectiveSearchQpmThreshold?: string | null;
|
|
12439
|
+
/**
|
|
12440
|
+
* Optional. The start time of the currently active billing subscription.
|
|
12441
|
+
*/
|
|
12442
|
+
startTime?: string | null;
|
|
12443
|
+
}
|
|
12297
12444
|
/**
|
|
12298
12445
|
* Customer provided configurations.
|
|
12299
12446
|
*/
|
|
@@ -12311,6 +12458,10 @@ export namespace discoveryengine_v1 {
|
|
|
12311
12458
|
* Model Armor configuration to be used for sanitizing user prompts and LLM responses.
|
|
12312
12459
|
*/
|
|
12313
12460
|
modelArmorConfig?: Schema$GoogleCloudDiscoveryengineV1ProjectCustomerProvidedConfigNotebooklmConfigModelArmorConfig;
|
|
12461
|
+
/**
|
|
12462
|
+
* Optional. Whether to disable the notebook sharing feature for the project. Default to false if not specified.
|
|
12463
|
+
*/
|
|
12464
|
+
optOutNotebookSharing?: boolean | null;
|
|
12314
12465
|
}
|
|
12315
12466
|
/**
|
|
12316
12467
|
* Configuration for customer defined Model Armor templates to be used for sanitizing user prompts and LLM responses.
|
|
@@ -12942,7 +13093,7 @@ export namespace discoveryengine_v1 {
|
|
|
12942
13093
|
*/
|
|
12943
13094
|
userLabels?: {[key: string]: string} | null;
|
|
12944
13095
|
/**
|
|
12945
|
-
* A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
13096
|
+
* Optional. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and CompleteQueryRequest.user_pseudo_id The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
12946
13097
|
*/
|
|
12947
13098
|
userPseudoId?: string | null;
|
|
12948
13099
|
}
|
|
@@ -14410,6 +14561,31 @@ export namespace discoveryengine_v1 {
|
|
|
14410
14561
|
*/
|
|
14411
14562
|
userProfile?: string | null;
|
|
14412
14563
|
}
|
|
14564
|
+
/**
|
|
14565
|
+
* Configures metadata that is used for End User entities.
|
|
14566
|
+
*/
|
|
14567
|
+
export interface Schema$GoogleCloudDiscoveryengineV1UserStore {
|
|
14568
|
+
/**
|
|
14569
|
+
* Optional. The default subscription LicenseConfig for the UserStore, if UserStore.enable_license_auto_register is true, new users will automatically register under the default subscription. If default LicenseConfig doesn't have remaining license seats left, new users will not be assigned with license and will be blocked for Vertex AI Search features. This is used if `license_assignment_tier_rules` is not configured.
|
|
14570
|
+
*/
|
|
14571
|
+
defaultLicenseConfig?: string | null;
|
|
14572
|
+
/**
|
|
14573
|
+
* The display name of the User Store.
|
|
14574
|
+
*/
|
|
14575
|
+
displayName?: string | null;
|
|
14576
|
+
/**
|
|
14577
|
+
* Optional. Whether to enable license auto update for users in this User Store. If true, users with expired licenses will automatically be updated to use the default license config as long as the default license config has seats left.
|
|
14578
|
+
*/
|
|
14579
|
+
enableExpiredLicenseAutoUpdate?: boolean | null;
|
|
14580
|
+
/**
|
|
14581
|
+
* Optional. Whether to enable license auto register for users in this User Store. If true, new users will automatically register under the default license config as long as the default license config has seats left.
|
|
14582
|
+
*/
|
|
14583
|
+
enableLicenseAutoRegister?: boolean | null;
|
|
14584
|
+
/**
|
|
14585
|
+
* Immutable. The full resource name of the User Store, in the format of `projects/{project\}/locations/{location\}/userStores/{user_store\}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.
|
|
14586
|
+
*/
|
|
14587
|
+
name?: string | null;
|
|
14588
|
+
}
|
|
14413
14589
|
/**
|
|
14414
14590
|
* Config to store data store type configuration for workspace data
|
|
14415
14591
|
*/
|
|
@@ -17917,7 +18093,7 @@ export namespace discoveryengine_v1 {
|
|
|
17917
18093
|
* query: 'placeholder-value',
|
|
17918
18094
|
* // Specifies the autocomplete data model. This overrides any model specified in the Configuration \> Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.
|
|
17919
18095
|
* queryModel: 'placeholder-value',
|
|
17920
|
-
* // A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
18096
|
+
* // Optional. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
17921
18097
|
* userPseudoId: 'placeholder-value',
|
|
17922
18098
|
* },
|
|
17923
18099
|
* );
|
|
@@ -18095,6 +18271,7 @@ export namespace discoveryengine_v1 {
|
|
|
18095
18271
|
* // "billingEstimation": {},
|
|
18096
18272
|
* // "cmekConfig": {},
|
|
18097
18273
|
* // "configurableBillingApproach": "my_configurableBillingApproach",
|
|
18274
|
+
* // "configurableBillingApproachUpdateTime": "my_configurableBillingApproachUpdateTime",
|
|
18098
18275
|
* // "contentConfig": "my_contentConfig",
|
|
18099
18276
|
* // "createTime": "my_createTime",
|
|
18100
18277
|
* // "defaultSchemaId": "my_defaultSchemaId",
|
|
@@ -18421,6 +18598,7 @@ export namespace discoveryengine_v1 {
|
|
|
18421
18598
|
* // "billingEstimation": {},
|
|
18422
18599
|
* // "cmekConfig": {},
|
|
18423
18600
|
* // "configurableBillingApproach": "my_configurableBillingApproach",
|
|
18601
|
+
* // "configurableBillingApproachUpdateTime": "my_configurableBillingApproachUpdateTime",
|
|
18424
18602
|
* // "contentConfig": "my_contentConfig",
|
|
18425
18603
|
* // "createTime": "my_createTime",
|
|
18426
18604
|
* // "defaultSchemaId": "my_defaultSchemaId",
|
|
@@ -18905,6 +19083,7 @@ export namespace discoveryengine_v1 {
|
|
|
18905
19083
|
* // "billingEstimation": {},
|
|
18906
19084
|
* // "cmekConfig": {},
|
|
18907
19085
|
* // "configurableBillingApproach": "my_configurableBillingApproach",
|
|
19086
|
+
* // "configurableBillingApproachUpdateTime": "my_configurableBillingApproachUpdateTime",
|
|
18908
19087
|
* // "contentConfig": "my_contentConfig",
|
|
18909
19088
|
* // "createTime": "my_createTime",
|
|
18910
19089
|
* // "defaultSchemaId": "my_defaultSchemaId",
|
|
@@ -18932,6 +19111,7 @@ export namespace discoveryengine_v1 {
|
|
|
18932
19111
|
* // "billingEstimation": {},
|
|
18933
19112
|
* // "cmekConfig": {},
|
|
18934
19113
|
* // "configurableBillingApproach": "my_configurableBillingApproach",
|
|
19114
|
+
* // "configurableBillingApproachUpdateTime": "my_configurableBillingApproachUpdateTime",
|
|
18935
19115
|
* // "contentConfig": "my_contentConfig",
|
|
18936
19116
|
* // "createTime": "my_createTime",
|
|
18937
19117
|
* // "defaultSchemaId": "my_defaultSchemaId",
|
|
@@ -19239,7 +19419,7 @@ export namespace discoveryengine_v1 {
|
|
|
19239
19419
|
*/
|
|
19240
19420
|
queryModel?: string;
|
|
19241
19421
|
/**
|
|
19242
|
-
* A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
19422
|
+
* Optional. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
19243
19423
|
*/
|
|
19244
19424
|
userPseudoId?: string;
|
|
19245
19425
|
}
|
|
@@ -26139,7 +26319,7 @@ export namespace discoveryengine_v1 {
|
|
|
26139
26319
|
}
|
|
26140
26320
|
|
|
26141
26321
|
/**
|
|
26142
|
-
*
|
|
26322
|
+
* Gets a ServingConfig. Returns a NotFound error if the ServingConfig does not exist.
|
|
26143
26323
|
* @example
|
|
26144
26324
|
* ```js
|
|
26145
26325
|
* // Before running the sample:
|
|
@@ -26172,39 +26352,10 @@ export namespace discoveryengine_v1 {
|
|
|
26172
26352
|
*
|
|
26173
26353
|
* // Do the magic
|
|
26174
26354
|
* const res =
|
|
26175
|
-
* await discoveryengine.projects.locations.collections.dataStores.servingConfigs.
|
|
26355
|
+
* await discoveryengine.projects.locations.collections.dataStores.servingConfigs.get(
|
|
26176
26356
|
* {
|
|
26177
|
-
* //
|
|
26357
|
+
* // Required. The resource name of the ServingConfig to get. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}/servingConfigs/{serving_config_id\}`
|
|
26178
26358
|
* name: 'projects/my-project/locations/my-location/collections/my-collection/dataStores/my-dataStore/servingConfigs/my-servingConfig',
|
|
26179
|
-
* // Indicates which fields in the provided ServingConfig to update. The following are NOT supported: * ServingConfig.name If not set, all supported fields are updated.
|
|
26180
|
-
* updateMask: 'placeholder-value',
|
|
26181
|
-
*
|
|
26182
|
-
* // Request body metadata
|
|
26183
|
-
* requestBody: {
|
|
26184
|
-
* // request body parameters
|
|
26185
|
-
* // {
|
|
26186
|
-
* // "answerGenerationSpec": {},
|
|
26187
|
-
* // "boostControlIds": [],
|
|
26188
|
-
* // "createTime": "my_createTime",
|
|
26189
|
-
* // "displayName": "my_displayName",
|
|
26190
|
-
* // "dissociateControlIds": [],
|
|
26191
|
-
* // "diversityLevel": "my_diversityLevel",
|
|
26192
|
-
* // "filterControlIds": [],
|
|
26193
|
-
* // "genericConfig": {},
|
|
26194
|
-
* // "ignoreControlIds": [],
|
|
26195
|
-
* // "mediaConfig": {},
|
|
26196
|
-
* // "modelId": "my_modelId",
|
|
26197
|
-
* // "name": "my_name",
|
|
26198
|
-
* // "onewaySynonymsControlIds": [],
|
|
26199
|
-
* // "promoteControlIds": [],
|
|
26200
|
-
* // "rankingExpression": "my_rankingExpression",
|
|
26201
|
-
* // "redirectControlIds": [],
|
|
26202
|
-
* // "replacementControlIds": [],
|
|
26203
|
-
* // "solutionType": "my_solutionType",
|
|
26204
|
-
* // "synonymsControlIds": [],
|
|
26205
|
-
* // "updateTime": "my_updateTime"
|
|
26206
|
-
* // }
|
|
26207
|
-
* },
|
|
26208
26359
|
* },
|
|
26209
26360
|
* );
|
|
26210
26361
|
* console.log(res.data);
|
|
@@ -26246,38 +26397,38 @@ export namespace discoveryengine_v1 {
|
|
|
26246
26397
|
* @param callback - Optional callback that handles the response.
|
|
26247
26398
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
26248
26399
|
*/
|
|
26249
|
-
|
|
26250
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26400
|
+
get(
|
|
26401
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get,
|
|
26251
26402
|
options: StreamMethodOptions
|
|
26252
26403
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
26253
|
-
|
|
26254
|
-
params?: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26404
|
+
get(
|
|
26405
|
+
params?: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get,
|
|
26255
26406
|
options?: MethodOptions
|
|
26256
26407
|
): Promise<
|
|
26257
26408
|
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26258
26409
|
>;
|
|
26259
|
-
|
|
26260
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26410
|
+
get(
|
|
26411
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get,
|
|
26261
26412
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
26262
26413
|
callback: BodyResponseCallback<Readable>
|
|
26263
26414
|
): void;
|
|
26264
|
-
|
|
26265
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26415
|
+
get(
|
|
26416
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get,
|
|
26266
26417
|
options:
|
|
26267
26418
|
| MethodOptions
|
|
26268
26419
|
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>,
|
|
26269
26420
|
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26270
26421
|
): void;
|
|
26271
|
-
|
|
26272
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26422
|
+
get(
|
|
26423
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get,
|
|
26273
26424
|
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26274
26425
|
): void;
|
|
26275
|
-
|
|
26426
|
+
get(
|
|
26276
26427
|
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26277
26428
|
): void;
|
|
26278
|
-
|
|
26429
|
+
get(
|
|
26279
26430
|
paramsOrCallback?:
|
|
26280
|
-
| Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26431
|
+
| Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get
|
|
26281
26432
|
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26282
26433
|
| BodyResponseCallback<Readable>,
|
|
26283
26434
|
optionsOrCallback?:
|
|
@@ -26295,13 +26446,13 @@ export namespace discoveryengine_v1 {
|
|
|
26295
26446
|
>
|
|
26296
26447
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
26297
26448
|
let params = (paramsOrCallback ||
|
|
26298
|
-
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26449
|
+
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get;
|
|
26299
26450
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
26300
26451
|
|
|
26301
26452
|
if (typeof paramsOrCallback === 'function') {
|
|
26302
26453
|
callback = paramsOrCallback;
|
|
26303
26454
|
params =
|
|
26304
|
-
{} as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26455
|
+
{} as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get;
|
|
26305
26456
|
options = {};
|
|
26306
26457
|
}
|
|
26307
26458
|
|
|
@@ -26316,7 +26467,7 @@ export namespace discoveryengine_v1 {
|
|
|
26316
26467
|
options: Object.assign(
|
|
26317
26468
|
{
|
|
26318
26469
|
url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
26319
|
-
method: '
|
|
26470
|
+
method: 'GET',
|
|
26320
26471
|
apiVersion: '',
|
|
26321
26472
|
},
|
|
26322
26473
|
options
|
|
@@ -26339,7 +26490,7 @@ export namespace discoveryengine_v1 {
|
|
|
26339
26490
|
}
|
|
26340
26491
|
|
|
26341
26492
|
/**
|
|
26342
|
-
*
|
|
26493
|
+
* Lists all ServingConfigs linked to this dataStore.
|
|
26343
26494
|
* @example
|
|
26344
26495
|
* ```js
|
|
26345
26496
|
* // Before running the sample:
|
|
@@ -26372,34 +26523,23 @@ export namespace discoveryengine_v1 {
|
|
|
26372
26523
|
*
|
|
26373
26524
|
* // Do the magic
|
|
26374
26525
|
* const res =
|
|
26375
|
-
* await discoveryengine.projects.locations.collections.dataStores.servingConfigs.
|
|
26526
|
+
* await discoveryengine.projects.locations.collections.dataStores.servingConfigs.list(
|
|
26376
26527
|
* {
|
|
26377
|
-
* //
|
|
26378
|
-
*
|
|
26379
|
-
*
|
|
26380
|
-
*
|
|
26381
|
-
* //
|
|
26382
|
-
*
|
|
26383
|
-
*
|
|
26384
|
-
* // {
|
|
26385
|
-
* // "filter": "my_filter",
|
|
26386
|
-
* // "pageSize": 0,
|
|
26387
|
-
* // "params": {},
|
|
26388
|
-
* // "userEvent": {},
|
|
26389
|
-
* // "userLabels": {},
|
|
26390
|
-
* // "validateOnly": false
|
|
26391
|
-
* // }
|
|
26392
|
-
* },
|
|
26528
|
+
* // Optional. Maximum number of results to return. If unspecified, defaults to 100. If a value greater than 100 is provided, at most 100 results are returned.
|
|
26529
|
+
* pageSize: 'placeholder-value',
|
|
26530
|
+
* // Optional. A page token, received from a previous `ListServingConfigs` call. Provide this to retrieve the subsequent page.
|
|
26531
|
+
* pageToken: 'placeholder-value',
|
|
26532
|
+
* // Required. Full resource name of the parent resource. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}`
|
|
26533
|
+
* parent:
|
|
26534
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/dataStores/my-dataStore',
|
|
26393
26535
|
* },
|
|
26394
26536
|
* );
|
|
26395
26537
|
* console.log(res.data);
|
|
26396
26538
|
*
|
|
26397
26539
|
* // Example response
|
|
26398
26540
|
* // {
|
|
26399
|
-
* // "
|
|
26400
|
-
* // "
|
|
26401
|
-
* // "results": [],
|
|
26402
|
-
* // "validateOnly": false
|
|
26541
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
26542
|
+
* // "servingConfigs": []
|
|
26403
26543
|
* // }
|
|
26404
26544
|
* }
|
|
26405
26545
|
*
|
|
@@ -26415,62 +26555,62 @@ export namespace discoveryengine_v1 {
|
|
|
26415
26555
|
* @param callback - Optional callback that handles the response.
|
|
26416
26556
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
26417
26557
|
*/
|
|
26418
|
-
|
|
26419
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26558
|
+
list(
|
|
26559
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List,
|
|
26420
26560
|
options: StreamMethodOptions
|
|
26421
26561
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
26422
|
-
|
|
26423
|
-
params?: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26562
|
+
list(
|
|
26563
|
+
params?: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List,
|
|
26424
26564
|
options?: MethodOptions
|
|
26425
26565
|
): Promise<
|
|
26426
|
-
GaxiosResponseWithHTTP2<Schema$
|
|
26566
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
26427
26567
|
>;
|
|
26428
|
-
|
|
26429
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26568
|
+
list(
|
|
26569
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List,
|
|
26430
26570
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
26431
26571
|
callback: BodyResponseCallback<Readable>
|
|
26432
26572
|
): void;
|
|
26433
|
-
|
|
26434
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26573
|
+
list(
|
|
26574
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List,
|
|
26435
26575
|
options:
|
|
26436
26576
|
| MethodOptions
|
|
26437
|
-
| BodyResponseCallback<Schema$
|
|
26438
|
-
callback: BodyResponseCallback<Schema$
|
|
26577
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>,
|
|
26578
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
26439
26579
|
): void;
|
|
26440
|
-
|
|
26441
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26442
|
-
callback: BodyResponseCallback<Schema$
|
|
26580
|
+
list(
|
|
26581
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List,
|
|
26582
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
26443
26583
|
): void;
|
|
26444
|
-
|
|
26445
|
-
callback: BodyResponseCallback<Schema$
|
|
26584
|
+
list(
|
|
26585
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
26446
26586
|
): void;
|
|
26447
|
-
|
|
26587
|
+
list(
|
|
26448
26588
|
paramsOrCallback?:
|
|
26449
|
-
| Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26450
|
-
| BodyResponseCallback<Schema$
|
|
26589
|
+
| Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List
|
|
26590
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
26451
26591
|
| BodyResponseCallback<Readable>,
|
|
26452
26592
|
optionsOrCallback?:
|
|
26453
26593
|
| MethodOptions
|
|
26454
26594
|
| StreamMethodOptions
|
|
26455
|
-
| BodyResponseCallback<Schema$
|
|
26595
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
26456
26596
|
| BodyResponseCallback<Readable>,
|
|
26457
26597
|
callback?:
|
|
26458
|
-
| BodyResponseCallback<Schema$
|
|
26598
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
26459
26599
|
| BodyResponseCallback<Readable>
|
|
26460
26600
|
):
|
|
26461
26601
|
| void
|
|
26462
26602
|
| Promise<
|
|
26463
|
-
GaxiosResponseWithHTTP2<Schema$
|
|
26603
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
26464
26604
|
>
|
|
26465
26605
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
26466
26606
|
let params = (paramsOrCallback ||
|
|
26467
|
-
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26607
|
+
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List;
|
|
26468
26608
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
26469
26609
|
|
|
26470
26610
|
if (typeof paramsOrCallback === 'function') {
|
|
26471
26611
|
callback = paramsOrCallback;
|
|
26472
26612
|
params =
|
|
26473
|
-
{} as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26613
|
+
{} as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List;
|
|
26474
26614
|
options = {};
|
|
26475
26615
|
}
|
|
26476
26616
|
|
|
@@ -26484,34 +26624,34 @@ export namespace discoveryengine_v1 {
|
|
|
26484
26624
|
const parameters = {
|
|
26485
26625
|
options: Object.assign(
|
|
26486
26626
|
{
|
|
26487
|
-
url: (rootUrl + '/v1/{+
|
|
26627
|
+
url: (rootUrl + '/v1/{+parent}/servingConfigs').replace(
|
|
26488
26628
|
/([^:]\/)\/+/g,
|
|
26489
26629
|
'$1'
|
|
26490
26630
|
),
|
|
26491
|
-
method: '
|
|
26631
|
+
method: 'GET',
|
|
26492
26632
|
apiVersion: '',
|
|
26493
26633
|
},
|
|
26494
26634
|
options
|
|
26495
26635
|
),
|
|
26496
26636
|
params,
|
|
26497
|
-
requiredParams: ['
|
|
26498
|
-
pathParams: ['
|
|
26637
|
+
requiredParams: ['parent'],
|
|
26638
|
+
pathParams: ['parent'],
|
|
26499
26639
|
context: this.context,
|
|
26500
26640
|
};
|
|
26501
26641
|
if (callback) {
|
|
26502
|
-
createAPIRequest<Schema$
|
|
26642
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>(
|
|
26503
26643
|
parameters,
|
|
26504
26644
|
callback as BodyResponseCallback<unknown>
|
|
26505
26645
|
);
|
|
26506
26646
|
} else {
|
|
26507
|
-
return createAPIRequest<Schema$
|
|
26647
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>(
|
|
26508
26648
|
parameters
|
|
26509
26649
|
);
|
|
26510
26650
|
}
|
|
26511
26651
|
}
|
|
26512
26652
|
|
|
26513
26653
|
/**
|
|
26514
|
-
*
|
|
26654
|
+
* Updates a ServingConfig. Returns a NOT_FOUND error if the ServingConfig does not exist.
|
|
26515
26655
|
* @example
|
|
26516
26656
|
* ```js
|
|
26517
26657
|
* // Before running the sample:
|
|
@@ -26534,7 +26674,6 @@ export namespace discoveryengine_v1 {
|
|
|
26534
26674
|
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
26535
26675
|
* scopes: [
|
|
26536
26676
|
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
26537
|
-
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
26538
26677
|
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
26539
26678
|
* ],
|
|
26540
26679
|
* });
|
|
@@ -26545,47 +26684,37 @@ export namespace discoveryengine_v1 {
|
|
|
26545
26684
|
*
|
|
26546
26685
|
* // Do the magic
|
|
26547
26686
|
* const res =
|
|
26548
|
-
* await discoveryengine.projects.locations.collections.dataStores.servingConfigs.
|
|
26687
|
+
* await discoveryengine.projects.locations.collections.dataStores.servingConfigs.patch(
|
|
26549
26688
|
* {
|
|
26550
|
-
* //
|
|
26551
|
-
* servingConfig
|
|
26552
|
-
*
|
|
26689
|
+
* // Immutable. Fully qualified name `projects/{project\}/locations/{location\}/collections/{collection_id\}/engines/{engine_id\}/servingConfigs/{serving_config_id\}`
|
|
26690
|
+
* name: 'projects/my-project/locations/my-location/collections/my-collection/dataStores/my-dataStore/servingConfigs/my-servingConfig',
|
|
26691
|
+
* // Indicates which fields in the provided ServingConfig to update. The following are NOT supported: * ServingConfig.name If not set, all supported fields are updated.
|
|
26692
|
+
* updateMask: 'placeholder-value',
|
|
26553
26693
|
*
|
|
26554
26694
|
* // Request body metadata
|
|
26555
26695
|
* requestBody: {
|
|
26556
26696
|
* // request body parameters
|
|
26557
26697
|
* // {
|
|
26558
|
-
* // "
|
|
26559
|
-
* // "
|
|
26560
|
-
* // "
|
|
26561
|
-
* // "
|
|
26562
|
-
* // "
|
|
26563
|
-
* // "
|
|
26564
|
-
* // "
|
|
26565
|
-
* // "
|
|
26566
|
-
* // "
|
|
26567
|
-
* // "
|
|
26568
|
-
* // "
|
|
26569
|
-
* // "
|
|
26570
|
-
* // "
|
|
26571
|
-
* // "
|
|
26572
|
-
* // "pageSize": 0,
|
|
26573
|
-
* // "pageToken": "my_pageToken",
|
|
26574
|
-
* // "params": {},
|
|
26575
|
-
* // "query": "my_query",
|
|
26576
|
-
* // "queryExpansionSpec": {},
|
|
26698
|
+
* // "answerGenerationSpec": {},
|
|
26699
|
+
* // "boostControlIds": [],
|
|
26700
|
+
* // "createTime": "my_createTime",
|
|
26701
|
+
* // "displayName": "my_displayName",
|
|
26702
|
+
* // "dissociateControlIds": [],
|
|
26703
|
+
* // "diversityLevel": "my_diversityLevel",
|
|
26704
|
+
* // "filterControlIds": [],
|
|
26705
|
+
* // "genericConfig": {},
|
|
26706
|
+
* // "ignoreControlIds": [],
|
|
26707
|
+
* // "mediaConfig": {},
|
|
26708
|
+
* // "modelId": "my_modelId",
|
|
26709
|
+
* // "name": "my_name",
|
|
26710
|
+
* // "onewaySynonymsControlIds": [],
|
|
26711
|
+
* // "promoteControlIds": [],
|
|
26577
26712
|
* // "rankingExpression": "my_rankingExpression",
|
|
26578
|
-
* // "
|
|
26579
|
-
* // "
|
|
26580
|
-
* // "
|
|
26581
|
-
* // "
|
|
26582
|
-
* // "
|
|
26583
|
-
* // "session": "my_session",
|
|
26584
|
-
* // "sessionSpec": {},
|
|
26585
|
-
* // "spellCorrectionSpec": {},
|
|
26586
|
-
* // "userInfo": {},
|
|
26587
|
-
* // "userLabels": {},
|
|
26588
|
-
* // "userPseudoId": "my_userPseudoId"
|
|
26713
|
+
* // "redirectControlIds": [],
|
|
26714
|
+
* // "replacementControlIds": [],
|
|
26715
|
+
* // "solutionType": "my_solutionType",
|
|
26716
|
+
* // "synonymsControlIds": [],
|
|
26717
|
+
* // "updateTime": "my_updateTime"
|
|
26589
26718
|
* // }
|
|
26590
26719
|
* },
|
|
26591
26720
|
* },
|
|
@@ -26594,17 +26723,26 @@ export namespace discoveryengine_v1 {
|
|
|
26594
26723
|
*
|
|
26595
26724
|
* // Example response
|
|
26596
26725
|
* // {
|
|
26597
|
-
* // "
|
|
26598
|
-
* // "
|
|
26599
|
-
* // "
|
|
26600
|
-
* // "
|
|
26601
|
-
* // "
|
|
26602
|
-
* // "
|
|
26603
|
-
* // "
|
|
26604
|
-
* // "
|
|
26605
|
-
* // "
|
|
26606
|
-
* // "
|
|
26607
|
-
* // "
|
|
26726
|
+
* // "answerGenerationSpec": {},
|
|
26727
|
+
* // "boostControlIds": [],
|
|
26728
|
+
* // "createTime": "my_createTime",
|
|
26729
|
+
* // "displayName": "my_displayName",
|
|
26730
|
+
* // "dissociateControlIds": [],
|
|
26731
|
+
* // "diversityLevel": "my_diversityLevel",
|
|
26732
|
+
* // "filterControlIds": [],
|
|
26733
|
+
* // "genericConfig": {},
|
|
26734
|
+
* // "ignoreControlIds": [],
|
|
26735
|
+
* // "mediaConfig": {},
|
|
26736
|
+
* // "modelId": "my_modelId",
|
|
26737
|
+
* // "name": "my_name",
|
|
26738
|
+
* // "onewaySynonymsControlIds": [],
|
|
26739
|
+
* // "promoteControlIds": [],
|
|
26740
|
+
* // "rankingExpression": "my_rankingExpression",
|
|
26741
|
+
* // "redirectControlIds": [],
|
|
26742
|
+
* // "replacementControlIds": [],
|
|
26743
|
+
* // "solutionType": "my_solutionType",
|
|
26744
|
+
* // "synonymsControlIds": [],
|
|
26745
|
+
* // "updateTime": "my_updateTime"
|
|
26608
26746
|
* // }
|
|
26609
26747
|
* }
|
|
26610
26748
|
*
|
|
@@ -26620,62 +26758,62 @@ export namespace discoveryengine_v1 {
|
|
|
26620
26758
|
* @param callback - Optional callback that handles the response.
|
|
26621
26759
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
26622
26760
|
*/
|
|
26623
|
-
|
|
26624
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26761
|
+
patch(
|
|
26762
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch,
|
|
26625
26763
|
options: StreamMethodOptions
|
|
26626
26764
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
26627
|
-
|
|
26628
|
-
params?: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26765
|
+
patch(
|
|
26766
|
+
params?: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch,
|
|
26629
26767
|
options?: MethodOptions
|
|
26630
26768
|
): Promise<
|
|
26631
|
-
GaxiosResponseWithHTTP2<Schema$
|
|
26769
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26632
26770
|
>;
|
|
26633
|
-
|
|
26634
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26771
|
+
patch(
|
|
26772
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch,
|
|
26635
26773
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
26636
26774
|
callback: BodyResponseCallback<Readable>
|
|
26637
26775
|
): void;
|
|
26638
|
-
|
|
26639
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26776
|
+
patch(
|
|
26777
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch,
|
|
26640
26778
|
options:
|
|
26641
26779
|
| MethodOptions
|
|
26642
|
-
| BodyResponseCallback<Schema$
|
|
26643
|
-
callback: BodyResponseCallback<Schema$
|
|
26780
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>,
|
|
26781
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26644
26782
|
): void;
|
|
26645
|
-
|
|
26646
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26647
|
-
callback: BodyResponseCallback<Schema$
|
|
26783
|
+
patch(
|
|
26784
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch,
|
|
26785
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26648
26786
|
): void;
|
|
26649
|
-
|
|
26650
|
-
callback: BodyResponseCallback<Schema$
|
|
26787
|
+
patch(
|
|
26788
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26651
26789
|
): void;
|
|
26652
|
-
|
|
26790
|
+
patch(
|
|
26653
26791
|
paramsOrCallback?:
|
|
26654
|
-
| Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26655
|
-
| BodyResponseCallback<Schema$
|
|
26792
|
+
| Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch
|
|
26793
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26656
26794
|
| BodyResponseCallback<Readable>,
|
|
26657
26795
|
optionsOrCallback?:
|
|
26658
26796
|
| MethodOptions
|
|
26659
26797
|
| StreamMethodOptions
|
|
26660
|
-
| BodyResponseCallback<Schema$
|
|
26798
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26661
26799
|
| BodyResponseCallback<Readable>,
|
|
26662
26800
|
callback?:
|
|
26663
|
-
| BodyResponseCallback<Schema$
|
|
26801
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26664
26802
|
| BodyResponseCallback<Readable>
|
|
26665
26803
|
):
|
|
26666
26804
|
| void
|
|
26667
26805
|
| Promise<
|
|
26668
|
-
GaxiosResponseWithHTTP2<Schema$
|
|
26806
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
26669
26807
|
>
|
|
26670
26808
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
26671
26809
|
let params = (paramsOrCallback ||
|
|
26672
|
-
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26810
|
+
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch;
|
|
26673
26811
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
26674
26812
|
|
|
26675
26813
|
if (typeof paramsOrCallback === 'function') {
|
|
26676
26814
|
callback = paramsOrCallback;
|
|
26677
26815
|
params =
|
|
26678
|
-
{} as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$
|
|
26816
|
+
{} as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch;
|
|
26679
26817
|
options = {};
|
|
26680
26818
|
}
|
|
26681
26819
|
|
|
@@ -26689,34 +26827,408 @@ export namespace discoveryengine_v1 {
|
|
|
26689
26827
|
const parameters = {
|
|
26690
26828
|
options: Object.assign(
|
|
26691
26829
|
{
|
|
26692
|
-
url: (rootUrl + '/v1/{+
|
|
26693
|
-
|
|
26694
|
-
'$1'
|
|
26695
|
-
),
|
|
26696
|
-
method: 'POST',
|
|
26830
|
+
url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
26831
|
+
method: 'PATCH',
|
|
26697
26832
|
apiVersion: '',
|
|
26698
26833
|
},
|
|
26699
26834
|
options
|
|
26700
26835
|
),
|
|
26701
26836
|
params,
|
|
26702
|
-
requiredParams: ['
|
|
26703
|
-
pathParams: ['
|
|
26837
|
+
requiredParams: ['name'],
|
|
26838
|
+
pathParams: ['name'],
|
|
26704
26839
|
context: this.context,
|
|
26705
26840
|
};
|
|
26706
26841
|
if (callback) {
|
|
26707
|
-
createAPIRequest<Schema$
|
|
26842
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ServingConfig>(
|
|
26708
26843
|
parameters,
|
|
26709
26844
|
callback as BodyResponseCallback<unknown>
|
|
26710
26845
|
);
|
|
26711
26846
|
} else {
|
|
26712
|
-
return createAPIRequest<Schema$
|
|
26847
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ServingConfig>(
|
|
26713
26848
|
parameters
|
|
26714
26849
|
);
|
|
26715
26850
|
}
|
|
26716
26851
|
}
|
|
26717
26852
|
|
|
26718
26853
|
/**
|
|
26719
|
-
*
|
|
26854
|
+
* Makes a recommendation, which requires a contextual user event.
|
|
26855
|
+
* @example
|
|
26856
|
+
* ```js
|
|
26857
|
+
* // Before running the sample:
|
|
26858
|
+
* // - Enable the API at:
|
|
26859
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
26860
|
+
* // - Login into gcloud by running:
|
|
26861
|
+
* // ```sh
|
|
26862
|
+
* // $ gcloud auth application-default login
|
|
26863
|
+
* // ```
|
|
26864
|
+
* // - Install the npm module by running:
|
|
26865
|
+
* // ```sh
|
|
26866
|
+
* // $ npm install googleapis
|
|
26867
|
+
* // ```
|
|
26868
|
+
*
|
|
26869
|
+
* const {google} = require('googleapis');
|
|
26870
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
26871
|
+
*
|
|
26872
|
+
* async function main() {
|
|
26873
|
+
* const auth = new google.auth.GoogleAuth({
|
|
26874
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
26875
|
+
* scopes: [
|
|
26876
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
26877
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
26878
|
+
* ],
|
|
26879
|
+
* });
|
|
26880
|
+
*
|
|
26881
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
26882
|
+
* const authClient = await auth.getClient();
|
|
26883
|
+
* google.options({auth: authClient});
|
|
26884
|
+
*
|
|
26885
|
+
* // Do the magic
|
|
26886
|
+
* const res =
|
|
26887
|
+
* await discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend(
|
|
26888
|
+
* {
|
|
26889
|
+
* // Required. Full resource name of a ServingConfig: `projects/x/locations/global/collections/x/engines/x/servingConfigs/x`, or `projects/x/locations/global/collections/x/dataStores/x/servingConfigs/x` One default serving config is created along with your recommendation engine creation. The engine ID is used as the ID of the default serving config. For example, for Engine `projects/x/locations/global/collections/x/engines/my-engine`, you can use `projects/x/locations/global/collections/x/engines/my-engine/servingConfigs/my-engine` for your RecommendationService.Recommend requests.
|
|
26890
|
+
* servingConfig:
|
|
26891
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/dataStores/my-dataStore/servingConfigs/my-servingConfig',
|
|
26892
|
+
*
|
|
26893
|
+
* // Request body metadata
|
|
26894
|
+
* requestBody: {
|
|
26895
|
+
* // request body parameters
|
|
26896
|
+
* // {
|
|
26897
|
+
* // "filter": "my_filter",
|
|
26898
|
+
* // "pageSize": 0,
|
|
26899
|
+
* // "params": {},
|
|
26900
|
+
* // "userEvent": {},
|
|
26901
|
+
* // "userLabels": {},
|
|
26902
|
+
* // "validateOnly": false
|
|
26903
|
+
* // }
|
|
26904
|
+
* },
|
|
26905
|
+
* },
|
|
26906
|
+
* );
|
|
26907
|
+
* console.log(res.data);
|
|
26908
|
+
*
|
|
26909
|
+
* // Example response
|
|
26910
|
+
* // {
|
|
26911
|
+
* // "attributionToken": "my_attributionToken",
|
|
26912
|
+
* // "missingIds": [],
|
|
26913
|
+
* // "results": [],
|
|
26914
|
+
* // "validateOnly": false
|
|
26915
|
+
* // }
|
|
26916
|
+
* }
|
|
26917
|
+
*
|
|
26918
|
+
* main().catch(e => {
|
|
26919
|
+
* console.error(e);
|
|
26920
|
+
* throw e;
|
|
26921
|
+
* });
|
|
26922
|
+
*
|
|
26923
|
+
* ```
|
|
26924
|
+
*
|
|
26925
|
+
* @param params - Parameters for request
|
|
26926
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
26927
|
+
* @param callback - Optional callback that handles the response.
|
|
26928
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
26929
|
+
*/
|
|
26930
|
+
recommend(
|
|
26931
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Recommend,
|
|
26932
|
+
options: StreamMethodOptions
|
|
26933
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
26934
|
+
recommend(
|
|
26935
|
+
params?: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Recommend,
|
|
26936
|
+
options?: MethodOptions
|
|
26937
|
+
): Promise<
|
|
26938
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
26939
|
+
>;
|
|
26940
|
+
recommend(
|
|
26941
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Recommend,
|
|
26942
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
26943
|
+
callback: BodyResponseCallback<Readable>
|
|
26944
|
+
): void;
|
|
26945
|
+
recommend(
|
|
26946
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Recommend,
|
|
26947
|
+
options:
|
|
26948
|
+
| MethodOptions
|
|
26949
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>,
|
|
26950
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
26951
|
+
): void;
|
|
26952
|
+
recommend(
|
|
26953
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Recommend,
|
|
26954
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
26955
|
+
): void;
|
|
26956
|
+
recommend(
|
|
26957
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
26958
|
+
): void;
|
|
26959
|
+
recommend(
|
|
26960
|
+
paramsOrCallback?:
|
|
26961
|
+
| Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Recommend
|
|
26962
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
26963
|
+
| BodyResponseCallback<Readable>,
|
|
26964
|
+
optionsOrCallback?:
|
|
26965
|
+
| MethodOptions
|
|
26966
|
+
| StreamMethodOptions
|
|
26967
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
26968
|
+
| BodyResponseCallback<Readable>,
|
|
26969
|
+
callback?:
|
|
26970
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
26971
|
+
| BodyResponseCallback<Readable>
|
|
26972
|
+
):
|
|
26973
|
+
| void
|
|
26974
|
+
| Promise<
|
|
26975
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
26976
|
+
>
|
|
26977
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
26978
|
+
let params = (paramsOrCallback ||
|
|
26979
|
+
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Recommend;
|
|
26980
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
26981
|
+
|
|
26982
|
+
if (typeof paramsOrCallback === 'function') {
|
|
26983
|
+
callback = paramsOrCallback;
|
|
26984
|
+
params =
|
|
26985
|
+
{} as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Recommend;
|
|
26986
|
+
options = {};
|
|
26987
|
+
}
|
|
26988
|
+
|
|
26989
|
+
if (typeof optionsOrCallback === 'function') {
|
|
26990
|
+
callback = optionsOrCallback;
|
|
26991
|
+
options = {};
|
|
26992
|
+
}
|
|
26993
|
+
|
|
26994
|
+
const rootUrl =
|
|
26995
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
26996
|
+
const parameters = {
|
|
26997
|
+
options: Object.assign(
|
|
26998
|
+
{
|
|
26999
|
+
url: (rootUrl + '/v1/{+servingConfig}:recommend').replace(
|
|
27000
|
+
/([^:]\/)\/+/g,
|
|
27001
|
+
'$1'
|
|
27002
|
+
),
|
|
27003
|
+
method: 'POST',
|
|
27004
|
+
apiVersion: '',
|
|
27005
|
+
},
|
|
27006
|
+
options
|
|
27007
|
+
),
|
|
27008
|
+
params,
|
|
27009
|
+
requiredParams: ['servingConfig'],
|
|
27010
|
+
pathParams: ['servingConfig'],
|
|
27011
|
+
context: this.context,
|
|
27012
|
+
};
|
|
27013
|
+
if (callback) {
|
|
27014
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>(
|
|
27015
|
+
parameters,
|
|
27016
|
+
callback as BodyResponseCallback<unknown>
|
|
27017
|
+
);
|
|
27018
|
+
} else {
|
|
27019
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>(
|
|
27020
|
+
parameters
|
|
27021
|
+
);
|
|
27022
|
+
}
|
|
27023
|
+
}
|
|
27024
|
+
|
|
27025
|
+
/**
|
|
27026
|
+
* Performs a search.
|
|
27027
|
+
* @example
|
|
27028
|
+
* ```js
|
|
27029
|
+
* // Before running the sample:
|
|
27030
|
+
* // - Enable the API at:
|
|
27031
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
27032
|
+
* // - Login into gcloud by running:
|
|
27033
|
+
* // ```sh
|
|
27034
|
+
* // $ gcloud auth application-default login
|
|
27035
|
+
* // ```
|
|
27036
|
+
* // - Install the npm module by running:
|
|
27037
|
+
* // ```sh
|
|
27038
|
+
* // $ npm install googleapis
|
|
27039
|
+
* // ```
|
|
27040
|
+
*
|
|
27041
|
+
* const {google} = require('googleapis');
|
|
27042
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
27043
|
+
*
|
|
27044
|
+
* async function main() {
|
|
27045
|
+
* const auth = new google.auth.GoogleAuth({
|
|
27046
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
27047
|
+
* scopes: [
|
|
27048
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
27049
|
+
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
27050
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
27051
|
+
* ],
|
|
27052
|
+
* });
|
|
27053
|
+
*
|
|
27054
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
27055
|
+
* const authClient = await auth.getClient();
|
|
27056
|
+
* google.options({auth: authClient});
|
|
27057
|
+
*
|
|
27058
|
+
* // Do the magic
|
|
27059
|
+
* const res =
|
|
27060
|
+
* await discoveryengine.projects.locations.collections.dataStores.servingConfigs.search(
|
|
27061
|
+
* {
|
|
27062
|
+
* // Required. The resource name of the Search serving config, such as `projects/x/locations/global/collections/default_collection/engines/x/servingConfigs/default_serving_config`, or `projects/x/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.
|
|
27063
|
+
* servingConfig:
|
|
27064
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/dataStores/my-dataStore/servingConfigs/my-servingConfig',
|
|
27065
|
+
*
|
|
27066
|
+
* // Request body metadata
|
|
27067
|
+
* requestBody: {
|
|
27068
|
+
* // request body parameters
|
|
27069
|
+
* // {
|
|
27070
|
+
* // "boostSpec": {},
|
|
27071
|
+
* // "branch": "my_branch",
|
|
27072
|
+
* // "canonicalFilter": "my_canonicalFilter",
|
|
27073
|
+
* // "contentSearchSpec": {},
|
|
27074
|
+
* // "dataStoreSpecs": [],
|
|
27075
|
+
* // "displaySpec": {},
|
|
27076
|
+
* // "facetSpecs": [],
|
|
27077
|
+
* // "filter": "my_filter",
|
|
27078
|
+
* // "imageQuery": {},
|
|
27079
|
+
* // "languageCode": "my_languageCode",
|
|
27080
|
+
* // "naturalLanguageQueryUnderstandingSpec": {},
|
|
27081
|
+
* // "offset": 0,
|
|
27082
|
+
* // "oneBoxPageSize": 0,
|
|
27083
|
+
* // "orderBy": "my_orderBy",
|
|
27084
|
+
* // "pageSize": 0,
|
|
27085
|
+
* // "pageToken": "my_pageToken",
|
|
27086
|
+
* // "params": {},
|
|
27087
|
+
* // "query": "my_query",
|
|
27088
|
+
* // "queryExpansionSpec": {},
|
|
27089
|
+
* // "rankingExpression": "my_rankingExpression",
|
|
27090
|
+
* // "rankingExpressionBackend": "my_rankingExpressionBackend",
|
|
27091
|
+
* // "relevanceScoreSpec": {},
|
|
27092
|
+
* // "relevanceThreshold": "my_relevanceThreshold",
|
|
27093
|
+
* // "safeSearch": false,
|
|
27094
|
+
* // "searchAsYouTypeSpec": {},
|
|
27095
|
+
* // "session": "my_session",
|
|
27096
|
+
* // "sessionSpec": {},
|
|
27097
|
+
* // "spellCorrectionSpec": {},
|
|
27098
|
+
* // "userInfo": {},
|
|
27099
|
+
* // "userLabels": {},
|
|
27100
|
+
* // "userPseudoId": "my_userPseudoId"
|
|
27101
|
+
* // }
|
|
27102
|
+
* },
|
|
27103
|
+
* },
|
|
27104
|
+
* );
|
|
27105
|
+
* console.log(res.data);
|
|
27106
|
+
*
|
|
27107
|
+
* // Example response
|
|
27108
|
+
* // {
|
|
27109
|
+
* // "attributionToken": "my_attributionToken",
|
|
27110
|
+
* // "correctedQuery": "my_correctedQuery",
|
|
27111
|
+
* // "facets": [],
|
|
27112
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
27113
|
+
* // "queryExpansionInfo": {},
|
|
27114
|
+
* // "redirectUri": "my_redirectUri",
|
|
27115
|
+
* // "results": [],
|
|
27116
|
+
* // "searchLinkPromotions": [],
|
|
27117
|
+
* // "sessionInfo": {},
|
|
27118
|
+
* // "summary": {},
|
|
27119
|
+
* // "totalSize": 0
|
|
27120
|
+
* // }
|
|
27121
|
+
* }
|
|
27122
|
+
*
|
|
27123
|
+
* main().catch(e => {
|
|
27124
|
+
* console.error(e);
|
|
27125
|
+
* throw e;
|
|
27126
|
+
* });
|
|
27127
|
+
*
|
|
27128
|
+
* ```
|
|
27129
|
+
*
|
|
27130
|
+
* @param params - Parameters for request
|
|
27131
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
27132
|
+
* @param callback - Optional callback that handles the response.
|
|
27133
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
27134
|
+
*/
|
|
27135
|
+
search(
|
|
27136
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Search,
|
|
27137
|
+
options: StreamMethodOptions
|
|
27138
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
27139
|
+
search(
|
|
27140
|
+
params?: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Search,
|
|
27141
|
+
options?: MethodOptions
|
|
27142
|
+
): Promise<
|
|
27143
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
27144
|
+
>;
|
|
27145
|
+
search(
|
|
27146
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Search,
|
|
27147
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
27148
|
+
callback: BodyResponseCallback<Readable>
|
|
27149
|
+
): void;
|
|
27150
|
+
search(
|
|
27151
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Search,
|
|
27152
|
+
options:
|
|
27153
|
+
| MethodOptions
|
|
27154
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>,
|
|
27155
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
27156
|
+
): void;
|
|
27157
|
+
search(
|
|
27158
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Search,
|
|
27159
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
27160
|
+
): void;
|
|
27161
|
+
search(
|
|
27162
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
27163
|
+
): void;
|
|
27164
|
+
search(
|
|
27165
|
+
paramsOrCallback?:
|
|
27166
|
+
| Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Search
|
|
27167
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
27168
|
+
| BodyResponseCallback<Readable>,
|
|
27169
|
+
optionsOrCallback?:
|
|
27170
|
+
| MethodOptions
|
|
27171
|
+
| StreamMethodOptions
|
|
27172
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
27173
|
+
| BodyResponseCallback<Readable>,
|
|
27174
|
+
callback?:
|
|
27175
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
27176
|
+
| BodyResponseCallback<Readable>
|
|
27177
|
+
):
|
|
27178
|
+
| void
|
|
27179
|
+
| Promise<
|
|
27180
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
27181
|
+
>
|
|
27182
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
27183
|
+
let params = (paramsOrCallback ||
|
|
27184
|
+
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Search;
|
|
27185
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
27186
|
+
|
|
27187
|
+
if (typeof paramsOrCallback === 'function') {
|
|
27188
|
+
callback = paramsOrCallback;
|
|
27189
|
+
params =
|
|
27190
|
+
{} as Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Search;
|
|
27191
|
+
options = {};
|
|
27192
|
+
}
|
|
27193
|
+
|
|
27194
|
+
if (typeof optionsOrCallback === 'function') {
|
|
27195
|
+
callback = optionsOrCallback;
|
|
27196
|
+
options = {};
|
|
27197
|
+
}
|
|
27198
|
+
|
|
27199
|
+
const rootUrl =
|
|
27200
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
27201
|
+
const parameters = {
|
|
27202
|
+
options: Object.assign(
|
|
27203
|
+
{
|
|
27204
|
+
url: (rootUrl + '/v1/{+servingConfig}:search').replace(
|
|
27205
|
+
/([^:]\/)\/+/g,
|
|
27206
|
+
'$1'
|
|
27207
|
+
),
|
|
27208
|
+
method: 'POST',
|
|
27209
|
+
apiVersion: '',
|
|
27210
|
+
},
|
|
27211
|
+
options
|
|
27212
|
+
),
|
|
27213
|
+
params,
|
|
27214
|
+
requiredParams: ['servingConfig'],
|
|
27215
|
+
pathParams: ['servingConfig'],
|
|
27216
|
+
context: this.context,
|
|
27217
|
+
};
|
|
27218
|
+
if (callback) {
|
|
27219
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1SearchResponse>(
|
|
27220
|
+
parameters,
|
|
27221
|
+
callback as BodyResponseCallback<unknown>
|
|
27222
|
+
);
|
|
27223
|
+
} else {
|
|
27224
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1SearchResponse>(
|
|
27225
|
+
parameters
|
|
27226
|
+
);
|
|
27227
|
+
}
|
|
27228
|
+
}
|
|
27229
|
+
|
|
27230
|
+
/**
|
|
27231
|
+
* Performs a search. Similar to the SearchService.Search method, but a lite version that allows API key for authentication, where OAuth and IAM checks are not required. Only public website search is supported by this method. If data stores and engines not associated with public website search are specified, a `FAILED_PRECONDITION` error is returned. This method can be used for easy onboarding without having to implement an authentication backend. However, it is strongly recommended to use SearchService.Search instead with required OAuth and IAM checks to provide better data security.
|
|
26720
27232
|
* @example
|
|
26721
27233
|
* ```js
|
|
26722
27234
|
* // Before running the sample:
|
|
@@ -27110,6 +27622,28 @@ export namespace discoveryengine_v1 {
|
|
|
27110
27622
|
*/
|
|
27111
27623
|
requestBody?: Schema$GoogleCloudDiscoveryengineV1AnswerQueryRequest;
|
|
27112
27624
|
}
|
|
27625
|
+
export interface Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Get
|
|
27626
|
+
extends StandardParameters {
|
|
27627
|
+
/**
|
|
27628
|
+
* Required. The resource name of the ServingConfig to get. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}/servingConfigs/{serving_config_id\}`
|
|
27629
|
+
*/
|
|
27630
|
+
name?: string;
|
|
27631
|
+
}
|
|
27632
|
+
export interface Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$List
|
|
27633
|
+
extends StandardParameters {
|
|
27634
|
+
/**
|
|
27635
|
+
* Optional. Maximum number of results to return. If unspecified, defaults to 100. If a value greater than 100 is provided, at most 100 results are returned.
|
|
27636
|
+
*/
|
|
27637
|
+
pageSize?: number;
|
|
27638
|
+
/**
|
|
27639
|
+
* Optional. A page token, received from a previous `ListServingConfigs` call. Provide this to retrieve the subsequent page.
|
|
27640
|
+
*/
|
|
27641
|
+
pageToken?: string;
|
|
27642
|
+
/**
|
|
27643
|
+
* Required. Full resource name of the parent resource. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}`
|
|
27644
|
+
*/
|
|
27645
|
+
parent?: string;
|
|
27646
|
+
}
|
|
27113
27647
|
export interface Params$Resource$Projects$Locations$Collections$Datastores$Servingconfigs$Patch
|
|
27114
27648
|
extends StandardParameters {
|
|
27115
27649
|
/**
|
|
@@ -36887,6 +37421,338 @@ export namespace discoveryengine_v1 {
|
|
|
36887
37421
|
}
|
|
36888
37422
|
}
|
|
36889
37423
|
|
|
37424
|
+
/**
|
|
37425
|
+
* Gets a ServingConfig. Returns a NotFound error if the ServingConfig does not exist.
|
|
37426
|
+
* @example
|
|
37427
|
+
* ```js
|
|
37428
|
+
* // Before running the sample:
|
|
37429
|
+
* // - Enable the API at:
|
|
37430
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
37431
|
+
* // - Login into gcloud by running:
|
|
37432
|
+
* // ```sh
|
|
37433
|
+
* // $ gcloud auth application-default login
|
|
37434
|
+
* // ```
|
|
37435
|
+
* // - Install the npm module by running:
|
|
37436
|
+
* // ```sh
|
|
37437
|
+
* // $ npm install googleapis
|
|
37438
|
+
* // ```
|
|
37439
|
+
*
|
|
37440
|
+
* const {google} = require('googleapis');
|
|
37441
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
37442
|
+
*
|
|
37443
|
+
* async function main() {
|
|
37444
|
+
* const auth = new google.auth.GoogleAuth({
|
|
37445
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
37446
|
+
* scopes: [
|
|
37447
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
37448
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
37449
|
+
* ],
|
|
37450
|
+
* });
|
|
37451
|
+
*
|
|
37452
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
37453
|
+
* const authClient = await auth.getClient();
|
|
37454
|
+
* google.options({auth: authClient});
|
|
37455
|
+
*
|
|
37456
|
+
* // Do the magic
|
|
37457
|
+
* const res =
|
|
37458
|
+
* await discoveryengine.projects.locations.collections.engines.servingConfigs.get(
|
|
37459
|
+
* {
|
|
37460
|
+
* // Required. The resource name of the ServingConfig to get. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}/servingConfigs/{serving_config_id\}`
|
|
37461
|
+
* name: 'projects/my-project/locations/my-location/collections/my-collection/engines/my-engine/servingConfigs/my-servingConfig',
|
|
37462
|
+
* },
|
|
37463
|
+
* );
|
|
37464
|
+
* console.log(res.data);
|
|
37465
|
+
*
|
|
37466
|
+
* // Example response
|
|
37467
|
+
* // {
|
|
37468
|
+
* // "answerGenerationSpec": {},
|
|
37469
|
+
* // "boostControlIds": [],
|
|
37470
|
+
* // "createTime": "my_createTime",
|
|
37471
|
+
* // "displayName": "my_displayName",
|
|
37472
|
+
* // "dissociateControlIds": [],
|
|
37473
|
+
* // "diversityLevel": "my_diversityLevel",
|
|
37474
|
+
* // "filterControlIds": [],
|
|
37475
|
+
* // "genericConfig": {},
|
|
37476
|
+
* // "ignoreControlIds": [],
|
|
37477
|
+
* // "mediaConfig": {},
|
|
37478
|
+
* // "modelId": "my_modelId",
|
|
37479
|
+
* // "name": "my_name",
|
|
37480
|
+
* // "onewaySynonymsControlIds": [],
|
|
37481
|
+
* // "promoteControlIds": [],
|
|
37482
|
+
* // "rankingExpression": "my_rankingExpression",
|
|
37483
|
+
* // "redirectControlIds": [],
|
|
37484
|
+
* // "replacementControlIds": [],
|
|
37485
|
+
* // "solutionType": "my_solutionType",
|
|
37486
|
+
* // "synonymsControlIds": [],
|
|
37487
|
+
* // "updateTime": "my_updateTime"
|
|
37488
|
+
* // }
|
|
37489
|
+
* }
|
|
37490
|
+
*
|
|
37491
|
+
* main().catch(e => {
|
|
37492
|
+
* console.error(e);
|
|
37493
|
+
* throw e;
|
|
37494
|
+
* });
|
|
37495
|
+
*
|
|
37496
|
+
* ```
|
|
37497
|
+
*
|
|
37498
|
+
* @param params - Parameters for request
|
|
37499
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
37500
|
+
* @param callback - Optional callback that handles the response.
|
|
37501
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
37502
|
+
*/
|
|
37503
|
+
get(
|
|
37504
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get,
|
|
37505
|
+
options: StreamMethodOptions
|
|
37506
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
37507
|
+
get(
|
|
37508
|
+
params?: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get,
|
|
37509
|
+
options?: MethodOptions
|
|
37510
|
+
): Promise<
|
|
37511
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
37512
|
+
>;
|
|
37513
|
+
get(
|
|
37514
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get,
|
|
37515
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
37516
|
+
callback: BodyResponseCallback<Readable>
|
|
37517
|
+
): void;
|
|
37518
|
+
get(
|
|
37519
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get,
|
|
37520
|
+
options:
|
|
37521
|
+
| MethodOptions
|
|
37522
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>,
|
|
37523
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
37524
|
+
): void;
|
|
37525
|
+
get(
|
|
37526
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get,
|
|
37527
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
37528
|
+
): void;
|
|
37529
|
+
get(
|
|
37530
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
37531
|
+
): void;
|
|
37532
|
+
get(
|
|
37533
|
+
paramsOrCallback?:
|
|
37534
|
+
| Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get
|
|
37535
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
37536
|
+
| BodyResponseCallback<Readable>,
|
|
37537
|
+
optionsOrCallback?:
|
|
37538
|
+
| MethodOptions
|
|
37539
|
+
| StreamMethodOptions
|
|
37540
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
37541
|
+
| BodyResponseCallback<Readable>,
|
|
37542
|
+
callback?:
|
|
37543
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
37544
|
+
| BodyResponseCallback<Readable>
|
|
37545
|
+
):
|
|
37546
|
+
| void
|
|
37547
|
+
| Promise<
|
|
37548
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
37549
|
+
>
|
|
37550
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
37551
|
+
let params = (paramsOrCallback ||
|
|
37552
|
+
{}) as Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get;
|
|
37553
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
37554
|
+
|
|
37555
|
+
if (typeof paramsOrCallback === 'function') {
|
|
37556
|
+
callback = paramsOrCallback;
|
|
37557
|
+
params =
|
|
37558
|
+
{} as Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get;
|
|
37559
|
+
options = {};
|
|
37560
|
+
}
|
|
37561
|
+
|
|
37562
|
+
if (typeof optionsOrCallback === 'function') {
|
|
37563
|
+
callback = optionsOrCallback;
|
|
37564
|
+
options = {};
|
|
37565
|
+
}
|
|
37566
|
+
|
|
37567
|
+
const rootUrl =
|
|
37568
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
37569
|
+
const parameters = {
|
|
37570
|
+
options: Object.assign(
|
|
37571
|
+
{
|
|
37572
|
+
url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
37573
|
+
method: 'GET',
|
|
37574
|
+
apiVersion: '',
|
|
37575
|
+
},
|
|
37576
|
+
options
|
|
37577
|
+
),
|
|
37578
|
+
params,
|
|
37579
|
+
requiredParams: ['name'],
|
|
37580
|
+
pathParams: ['name'],
|
|
37581
|
+
context: this.context,
|
|
37582
|
+
};
|
|
37583
|
+
if (callback) {
|
|
37584
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ServingConfig>(
|
|
37585
|
+
parameters,
|
|
37586
|
+
callback as BodyResponseCallback<unknown>
|
|
37587
|
+
);
|
|
37588
|
+
} else {
|
|
37589
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ServingConfig>(
|
|
37590
|
+
parameters
|
|
37591
|
+
);
|
|
37592
|
+
}
|
|
37593
|
+
}
|
|
37594
|
+
|
|
37595
|
+
/**
|
|
37596
|
+
* Lists all ServingConfigs linked to this dataStore.
|
|
37597
|
+
* @example
|
|
37598
|
+
* ```js
|
|
37599
|
+
* // Before running the sample:
|
|
37600
|
+
* // - Enable the API at:
|
|
37601
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
37602
|
+
* // - Login into gcloud by running:
|
|
37603
|
+
* // ```sh
|
|
37604
|
+
* // $ gcloud auth application-default login
|
|
37605
|
+
* // ```
|
|
37606
|
+
* // - Install the npm module by running:
|
|
37607
|
+
* // ```sh
|
|
37608
|
+
* // $ npm install googleapis
|
|
37609
|
+
* // ```
|
|
37610
|
+
*
|
|
37611
|
+
* const {google} = require('googleapis');
|
|
37612
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
37613
|
+
*
|
|
37614
|
+
* async function main() {
|
|
37615
|
+
* const auth = new google.auth.GoogleAuth({
|
|
37616
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
37617
|
+
* scopes: [
|
|
37618
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
37619
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
37620
|
+
* ],
|
|
37621
|
+
* });
|
|
37622
|
+
*
|
|
37623
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
37624
|
+
* const authClient = await auth.getClient();
|
|
37625
|
+
* google.options({auth: authClient});
|
|
37626
|
+
*
|
|
37627
|
+
* // Do the magic
|
|
37628
|
+
* const res =
|
|
37629
|
+
* await discoveryengine.projects.locations.collections.engines.servingConfigs.list(
|
|
37630
|
+
* {
|
|
37631
|
+
* // Optional. Maximum number of results to return. If unspecified, defaults to 100. If a value greater than 100 is provided, at most 100 results are returned.
|
|
37632
|
+
* pageSize: 'placeholder-value',
|
|
37633
|
+
* // Optional. A page token, received from a previous `ListServingConfigs` call. Provide this to retrieve the subsequent page.
|
|
37634
|
+
* pageToken: 'placeholder-value',
|
|
37635
|
+
* // Required. Full resource name of the parent resource. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}`
|
|
37636
|
+
* parent:
|
|
37637
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/engines/my-engine',
|
|
37638
|
+
* },
|
|
37639
|
+
* );
|
|
37640
|
+
* console.log(res.data);
|
|
37641
|
+
*
|
|
37642
|
+
* // Example response
|
|
37643
|
+
* // {
|
|
37644
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
37645
|
+
* // "servingConfigs": []
|
|
37646
|
+
* // }
|
|
37647
|
+
* }
|
|
37648
|
+
*
|
|
37649
|
+
* main().catch(e => {
|
|
37650
|
+
* console.error(e);
|
|
37651
|
+
* throw e;
|
|
37652
|
+
* });
|
|
37653
|
+
*
|
|
37654
|
+
* ```
|
|
37655
|
+
*
|
|
37656
|
+
* @param params - Parameters for request
|
|
37657
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
37658
|
+
* @param callback - Optional callback that handles the response.
|
|
37659
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
37660
|
+
*/
|
|
37661
|
+
list(
|
|
37662
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List,
|
|
37663
|
+
options: StreamMethodOptions
|
|
37664
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
37665
|
+
list(
|
|
37666
|
+
params?: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List,
|
|
37667
|
+
options?: MethodOptions
|
|
37668
|
+
): Promise<
|
|
37669
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
37670
|
+
>;
|
|
37671
|
+
list(
|
|
37672
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List,
|
|
37673
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
37674
|
+
callback: BodyResponseCallback<Readable>
|
|
37675
|
+
): void;
|
|
37676
|
+
list(
|
|
37677
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List,
|
|
37678
|
+
options:
|
|
37679
|
+
| MethodOptions
|
|
37680
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>,
|
|
37681
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
37682
|
+
): void;
|
|
37683
|
+
list(
|
|
37684
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List,
|
|
37685
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
37686
|
+
): void;
|
|
37687
|
+
list(
|
|
37688
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
37689
|
+
): void;
|
|
37690
|
+
list(
|
|
37691
|
+
paramsOrCallback?:
|
|
37692
|
+
| Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List
|
|
37693
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
37694
|
+
| BodyResponseCallback<Readable>,
|
|
37695
|
+
optionsOrCallback?:
|
|
37696
|
+
| MethodOptions
|
|
37697
|
+
| StreamMethodOptions
|
|
37698
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
37699
|
+
| BodyResponseCallback<Readable>,
|
|
37700
|
+
callback?:
|
|
37701
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
37702
|
+
| BodyResponseCallback<Readable>
|
|
37703
|
+
):
|
|
37704
|
+
| void
|
|
37705
|
+
| Promise<
|
|
37706
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
37707
|
+
>
|
|
37708
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
37709
|
+
let params = (paramsOrCallback ||
|
|
37710
|
+
{}) as Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List;
|
|
37711
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
37712
|
+
|
|
37713
|
+
if (typeof paramsOrCallback === 'function') {
|
|
37714
|
+
callback = paramsOrCallback;
|
|
37715
|
+
params =
|
|
37716
|
+
{} as Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List;
|
|
37717
|
+
options = {};
|
|
37718
|
+
}
|
|
37719
|
+
|
|
37720
|
+
if (typeof optionsOrCallback === 'function') {
|
|
37721
|
+
callback = optionsOrCallback;
|
|
37722
|
+
options = {};
|
|
37723
|
+
}
|
|
37724
|
+
|
|
37725
|
+
const rootUrl =
|
|
37726
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
37727
|
+
const parameters = {
|
|
37728
|
+
options: Object.assign(
|
|
37729
|
+
{
|
|
37730
|
+
url: (rootUrl + '/v1/{+parent}/servingConfigs').replace(
|
|
37731
|
+
/([^:]\/)\/+/g,
|
|
37732
|
+
'$1'
|
|
37733
|
+
),
|
|
37734
|
+
method: 'GET',
|
|
37735
|
+
apiVersion: '',
|
|
37736
|
+
},
|
|
37737
|
+
options
|
|
37738
|
+
),
|
|
37739
|
+
params,
|
|
37740
|
+
requiredParams: ['parent'],
|
|
37741
|
+
pathParams: ['parent'],
|
|
37742
|
+
context: this.context,
|
|
37743
|
+
};
|
|
37744
|
+
if (callback) {
|
|
37745
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>(
|
|
37746
|
+
parameters,
|
|
37747
|
+
callback as BodyResponseCallback<unknown>
|
|
37748
|
+
);
|
|
37749
|
+
} else {
|
|
37750
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>(
|
|
37751
|
+
parameters
|
|
37752
|
+
);
|
|
37753
|
+
}
|
|
37754
|
+
}
|
|
37755
|
+
|
|
36890
37756
|
/**
|
|
36891
37757
|
* Updates a ServingConfig. Returns a NOT_FOUND error if the ServingConfig does not exist.
|
|
36892
37758
|
* @example
|
|
@@ -37859,6 +38725,28 @@ export namespace discoveryengine_v1 {
|
|
|
37859
38725
|
*/
|
|
37860
38726
|
requestBody?: Schema$GoogleCloudDiscoveryengineV1AnswerQueryRequest;
|
|
37861
38727
|
}
|
|
38728
|
+
export interface Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Get
|
|
38729
|
+
extends StandardParameters {
|
|
38730
|
+
/**
|
|
38731
|
+
* Required. The resource name of the ServingConfig to get. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}/servingConfigs/{serving_config_id\}`
|
|
38732
|
+
*/
|
|
38733
|
+
name?: string;
|
|
38734
|
+
}
|
|
38735
|
+
export interface Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$List
|
|
38736
|
+
extends StandardParameters {
|
|
38737
|
+
/**
|
|
38738
|
+
* Optional. Maximum number of results to return. If unspecified, defaults to 100. If a value greater than 100 is provided, at most 100 results are returned.
|
|
38739
|
+
*/
|
|
38740
|
+
pageSize?: number;
|
|
38741
|
+
/**
|
|
38742
|
+
* Optional. A page token, received from a previous `ListServingConfigs` call. Provide this to retrieve the subsequent page.
|
|
38743
|
+
*/
|
|
38744
|
+
pageToken?: string;
|
|
38745
|
+
/**
|
|
38746
|
+
* Required. Full resource name of the parent resource. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}`
|
|
38747
|
+
*/
|
|
38748
|
+
parent?: string;
|
|
38749
|
+
}
|
|
37862
38750
|
export interface Params$Resource$Projects$Locations$Collections$Engines$Servingconfigs$Patch
|
|
37863
38751
|
extends StandardParameters {
|
|
37864
38752
|
/**
|
|
@@ -39466,7 +40354,7 @@ export namespace discoveryengine_v1 {
|
|
|
39466
40354
|
* query: 'placeholder-value',
|
|
39467
40355
|
* // Specifies the autocomplete data model. This overrides any model specified in the Configuration \> Autocomplete section of the Cloud console. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.
|
|
39468
40356
|
* queryModel: 'placeholder-value',
|
|
39469
|
-
* // A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
40357
|
+
* // Optional. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
39470
40358
|
* userPseudoId: 'placeholder-value',
|
|
39471
40359
|
* },
|
|
39472
40360
|
* );
|
|
@@ -39642,6 +40530,7 @@ export namespace discoveryengine_v1 {
|
|
|
39642
40530
|
* // "billingEstimation": {},
|
|
39643
40531
|
* // "cmekConfig": {},
|
|
39644
40532
|
* // "configurableBillingApproach": "my_configurableBillingApproach",
|
|
40533
|
+
* // "configurableBillingApproachUpdateTime": "my_configurableBillingApproachUpdateTime",
|
|
39645
40534
|
* // "contentConfig": "my_contentConfig",
|
|
39646
40535
|
* // "createTime": "my_createTime",
|
|
39647
40536
|
* // "defaultSchemaId": "my_defaultSchemaId",
|
|
@@ -39964,6 +40853,7 @@ export namespace discoveryengine_v1 {
|
|
|
39964
40853
|
* // "billingEstimation": {},
|
|
39965
40854
|
* // "cmekConfig": {},
|
|
39966
40855
|
* // "configurableBillingApproach": "my_configurableBillingApproach",
|
|
40856
|
+
* // "configurableBillingApproachUpdateTime": "my_configurableBillingApproachUpdateTime",
|
|
39967
40857
|
* // "contentConfig": "my_contentConfig",
|
|
39968
40858
|
* // "createTime": "my_createTime",
|
|
39969
40859
|
* // "defaultSchemaId": "my_defaultSchemaId",
|
|
@@ -40441,6 +41331,7 @@ export namespace discoveryengine_v1 {
|
|
|
40441
41331
|
* // "billingEstimation": {},
|
|
40442
41332
|
* // "cmekConfig": {},
|
|
40443
41333
|
* // "configurableBillingApproach": "my_configurableBillingApproach",
|
|
41334
|
+
* // "configurableBillingApproachUpdateTime": "my_configurableBillingApproachUpdateTime",
|
|
40444
41335
|
* // "contentConfig": "my_contentConfig",
|
|
40445
41336
|
* // "createTime": "my_createTime",
|
|
40446
41337
|
* // "defaultSchemaId": "my_defaultSchemaId",
|
|
@@ -40468,6 +41359,7 @@ export namespace discoveryengine_v1 {
|
|
|
40468
41359
|
* // "billingEstimation": {},
|
|
40469
41360
|
* // "cmekConfig": {},
|
|
40470
41361
|
* // "configurableBillingApproach": "my_configurableBillingApproach",
|
|
41362
|
+
* // "configurableBillingApproachUpdateTime": "my_configurableBillingApproachUpdateTime",
|
|
40471
41363
|
* // "contentConfig": "my_contentConfig",
|
|
40472
41364
|
* // "createTime": "my_createTime",
|
|
40473
41365
|
* // "defaultSchemaId": "my_defaultSchemaId",
|
|
@@ -40609,7 +41501,7 @@ export namespace discoveryengine_v1 {
|
|
|
40609
41501
|
*/
|
|
40610
41502
|
queryModel?: string;
|
|
40611
41503
|
/**
|
|
40612
|
-
* A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
41504
|
+
* Optional. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. This field should NOT have a fixed value such as `unknown_visitor`. This should be the same identifier as UserEvent.user_pseudo_id and SearchRequest.user_pseudo_id. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
40613
41505
|
*/
|
|
40614
41506
|
userPseudoId?: string;
|
|
40615
41507
|
}
|
|
@@ -46922,7 +47814,7 @@ export namespace discoveryengine_v1 {
|
|
|
46922
47814
|
}
|
|
46923
47815
|
|
|
46924
47816
|
/**
|
|
46925
|
-
*
|
|
47817
|
+
* Gets a ServingConfig. Returns a NotFound error if the ServingConfig does not exist.
|
|
46926
47818
|
* @example
|
|
46927
47819
|
* ```js
|
|
46928
47820
|
* // Before running the sample:
|
|
@@ -46955,38 +47847,9 @@ export namespace discoveryengine_v1 {
|
|
|
46955
47847
|
*
|
|
46956
47848
|
* // Do the magic
|
|
46957
47849
|
* const res =
|
|
46958
|
-
* await discoveryengine.projects.locations.dataStores.servingConfigs.
|
|
46959
|
-
* //
|
|
47850
|
+
* await discoveryengine.projects.locations.dataStores.servingConfigs.get({
|
|
47851
|
+
* // Required. The resource name of the ServingConfig to get. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}/servingConfigs/{serving_config_id\}`
|
|
46960
47852
|
* name: 'projects/my-project/locations/my-location/dataStores/my-dataStore/servingConfigs/my-servingConfig',
|
|
46961
|
-
* // Indicates which fields in the provided ServingConfig to update. The following are NOT supported: * ServingConfig.name If not set, all supported fields are updated.
|
|
46962
|
-
* updateMask: 'placeholder-value',
|
|
46963
|
-
*
|
|
46964
|
-
* // Request body metadata
|
|
46965
|
-
* requestBody: {
|
|
46966
|
-
* // request body parameters
|
|
46967
|
-
* // {
|
|
46968
|
-
* // "answerGenerationSpec": {},
|
|
46969
|
-
* // "boostControlIds": [],
|
|
46970
|
-
* // "createTime": "my_createTime",
|
|
46971
|
-
* // "displayName": "my_displayName",
|
|
46972
|
-
* // "dissociateControlIds": [],
|
|
46973
|
-
* // "diversityLevel": "my_diversityLevel",
|
|
46974
|
-
* // "filterControlIds": [],
|
|
46975
|
-
* // "genericConfig": {},
|
|
46976
|
-
* // "ignoreControlIds": [],
|
|
46977
|
-
* // "mediaConfig": {},
|
|
46978
|
-
* // "modelId": "my_modelId",
|
|
46979
|
-
* // "name": "my_name",
|
|
46980
|
-
* // "onewaySynonymsControlIds": [],
|
|
46981
|
-
* // "promoteControlIds": [],
|
|
46982
|
-
* // "rankingExpression": "my_rankingExpression",
|
|
46983
|
-
* // "redirectControlIds": [],
|
|
46984
|
-
* // "replacementControlIds": [],
|
|
46985
|
-
* // "solutionType": "my_solutionType",
|
|
46986
|
-
* // "synonymsControlIds": [],
|
|
46987
|
-
* // "updateTime": "my_updateTime"
|
|
46988
|
-
* // }
|
|
46989
|
-
* },
|
|
46990
47853
|
* });
|
|
46991
47854
|
* console.log(res.data);
|
|
46992
47855
|
*
|
|
@@ -47027,38 +47890,38 @@ export namespace discoveryengine_v1 {
|
|
|
47027
47890
|
* @param callback - Optional callback that handles the response.
|
|
47028
47891
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
47029
47892
|
*/
|
|
47030
|
-
|
|
47031
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47893
|
+
get(
|
|
47894
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get,
|
|
47032
47895
|
options: StreamMethodOptions
|
|
47033
47896
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
47034
|
-
|
|
47035
|
-
params?: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47897
|
+
get(
|
|
47898
|
+
params?: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get,
|
|
47036
47899
|
options?: MethodOptions
|
|
47037
47900
|
): Promise<
|
|
47038
47901
|
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47039
47902
|
>;
|
|
47040
|
-
|
|
47041
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47903
|
+
get(
|
|
47904
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get,
|
|
47042
47905
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
47043
47906
|
callback: BodyResponseCallback<Readable>
|
|
47044
47907
|
): void;
|
|
47045
|
-
|
|
47046
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47908
|
+
get(
|
|
47909
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get,
|
|
47047
47910
|
options:
|
|
47048
47911
|
| MethodOptions
|
|
47049
47912
|
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>,
|
|
47050
47913
|
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47051
47914
|
): void;
|
|
47052
|
-
|
|
47053
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47915
|
+
get(
|
|
47916
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get,
|
|
47054
47917
|
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47055
47918
|
): void;
|
|
47056
|
-
|
|
47919
|
+
get(
|
|
47057
47920
|
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47058
47921
|
): void;
|
|
47059
|
-
|
|
47922
|
+
get(
|
|
47060
47923
|
paramsOrCallback?:
|
|
47061
|
-
| Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47924
|
+
| Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get
|
|
47062
47925
|
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47063
47926
|
| BodyResponseCallback<Readable>,
|
|
47064
47927
|
optionsOrCallback?:
|
|
@@ -47076,13 +47939,13 @@ export namespace discoveryengine_v1 {
|
|
|
47076
47939
|
>
|
|
47077
47940
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
47078
47941
|
let params = (paramsOrCallback ||
|
|
47079
|
-
{}) as Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47942
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get;
|
|
47080
47943
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
47081
47944
|
|
|
47082
47945
|
if (typeof paramsOrCallback === 'function') {
|
|
47083
47946
|
callback = paramsOrCallback;
|
|
47084
47947
|
params =
|
|
47085
|
-
{} as Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47948
|
+
{} as Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get;
|
|
47086
47949
|
options = {};
|
|
47087
47950
|
}
|
|
47088
47951
|
|
|
@@ -47097,7 +47960,7 @@ export namespace discoveryengine_v1 {
|
|
|
47097
47960
|
options: Object.assign(
|
|
47098
47961
|
{
|
|
47099
47962
|
url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
47100
|
-
method: '
|
|
47963
|
+
method: 'GET',
|
|
47101
47964
|
apiVersion: '',
|
|
47102
47965
|
},
|
|
47103
47966
|
options
|
|
@@ -47120,7 +47983,7 @@ export namespace discoveryengine_v1 {
|
|
|
47120
47983
|
}
|
|
47121
47984
|
|
|
47122
47985
|
/**
|
|
47123
|
-
*
|
|
47986
|
+
* Lists all ServingConfigs linked to this dataStore.
|
|
47124
47987
|
* @example
|
|
47125
47988
|
* ```js
|
|
47126
47989
|
* // Before running the sample:
|
|
@@ -47153,34 +48016,21 @@ export namespace discoveryengine_v1 {
|
|
|
47153
48016
|
*
|
|
47154
48017
|
* // Do the magic
|
|
47155
48018
|
* const res =
|
|
47156
|
-
* await discoveryengine.projects.locations.dataStores.servingConfigs.
|
|
47157
|
-
*
|
|
47158
|
-
*
|
|
47159
|
-
*
|
|
47160
|
-
*
|
|
47161
|
-
*
|
|
47162
|
-
*
|
|
47163
|
-
*
|
|
47164
|
-
*
|
|
47165
|
-
* // {
|
|
47166
|
-
* // "filter": "my_filter",
|
|
47167
|
-
* // "pageSize": 0,
|
|
47168
|
-
* // "params": {},
|
|
47169
|
-
* // "userEvent": {},
|
|
47170
|
-
* // "userLabels": {},
|
|
47171
|
-
* // "validateOnly": false
|
|
47172
|
-
* // }
|
|
47173
|
-
* },
|
|
47174
|
-
* },
|
|
47175
|
-
* );
|
|
48019
|
+
* await discoveryengine.projects.locations.dataStores.servingConfigs.list({
|
|
48020
|
+
* // Optional. Maximum number of results to return. If unspecified, defaults to 100. If a value greater than 100 is provided, at most 100 results are returned.
|
|
48021
|
+
* pageSize: 'placeholder-value',
|
|
48022
|
+
* // Optional. A page token, received from a previous `ListServingConfigs` call. Provide this to retrieve the subsequent page.
|
|
48023
|
+
* pageToken: 'placeholder-value',
|
|
48024
|
+
* // Required. Full resource name of the parent resource. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}`
|
|
48025
|
+
* parent:
|
|
48026
|
+
* 'projects/my-project/locations/my-location/dataStores/my-dataStore',
|
|
48027
|
+
* });
|
|
47176
48028
|
* console.log(res.data);
|
|
47177
48029
|
*
|
|
47178
48030
|
* // Example response
|
|
47179
48031
|
* // {
|
|
47180
|
-
* // "
|
|
47181
|
-
* // "
|
|
47182
|
-
* // "results": [],
|
|
47183
|
-
* // "validateOnly": false
|
|
48032
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
48033
|
+
* // "servingConfigs": []
|
|
47184
48034
|
* // }
|
|
47185
48035
|
* }
|
|
47186
48036
|
*
|
|
@@ -47196,62 +48046,62 @@ export namespace discoveryengine_v1 {
|
|
|
47196
48046
|
* @param callback - Optional callback that handles the response.
|
|
47197
48047
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
47198
48048
|
*/
|
|
47199
|
-
|
|
47200
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48049
|
+
list(
|
|
48050
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$List,
|
|
47201
48051
|
options: StreamMethodOptions
|
|
47202
48052
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
47203
|
-
|
|
47204
|
-
params?: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48053
|
+
list(
|
|
48054
|
+
params?: Params$Resource$Projects$Locations$Datastores$Servingconfigs$List,
|
|
47205
48055
|
options?: MethodOptions
|
|
47206
48056
|
): Promise<
|
|
47207
|
-
GaxiosResponseWithHTTP2<Schema$
|
|
48057
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
47208
48058
|
>;
|
|
47209
|
-
|
|
47210
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48059
|
+
list(
|
|
48060
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$List,
|
|
47211
48061
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
47212
48062
|
callback: BodyResponseCallback<Readable>
|
|
47213
48063
|
): void;
|
|
47214
|
-
|
|
47215
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48064
|
+
list(
|
|
48065
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$List,
|
|
47216
48066
|
options:
|
|
47217
48067
|
| MethodOptions
|
|
47218
|
-
| BodyResponseCallback<Schema$
|
|
47219
|
-
callback: BodyResponseCallback<Schema$
|
|
48068
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>,
|
|
48069
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
47220
48070
|
): void;
|
|
47221
|
-
|
|
47222
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47223
|
-
callback: BodyResponseCallback<Schema$
|
|
48071
|
+
list(
|
|
48072
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$List,
|
|
48073
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
47224
48074
|
): void;
|
|
47225
|
-
|
|
47226
|
-
callback: BodyResponseCallback<Schema$
|
|
48075
|
+
list(
|
|
48076
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
47227
48077
|
): void;
|
|
47228
|
-
|
|
48078
|
+
list(
|
|
47229
48079
|
paramsOrCallback?:
|
|
47230
|
-
| Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47231
|
-
| BodyResponseCallback<Schema$
|
|
48080
|
+
| Params$Resource$Projects$Locations$Datastores$Servingconfigs$List
|
|
48081
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
47232
48082
|
| BodyResponseCallback<Readable>,
|
|
47233
48083
|
optionsOrCallback?:
|
|
47234
48084
|
| MethodOptions
|
|
47235
48085
|
| StreamMethodOptions
|
|
47236
|
-
| BodyResponseCallback<Schema$
|
|
48086
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
47237
48087
|
| BodyResponseCallback<Readable>,
|
|
47238
48088
|
callback?:
|
|
47239
|
-
| BodyResponseCallback<Schema$
|
|
48089
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
47240
48090
|
| BodyResponseCallback<Readable>
|
|
47241
48091
|
):
|
|
47242
48092
|
| void
|
|
47243
48093
|
| Promise<
|
|
47244
|
-
GaxiosResponseWithHTTP2<Schema$
|
|
48094
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>
|
|
47245
48095
|
>
|
|
47246
48096
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
47247
48097
|
let params = (paramsOrCallback ||
|
|
47248
|
-
{}) as Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48098
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Servingconfigs$List;
|
|
47249
48099
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
47250
48100
|
|
|
47251
48101
|
if (typeof paramsOrCallback === 'function') {
|
|
47252
48102
|
callback = paramsOrCallback;
|
|
47253
48103
|
params =
|
|
47254
|
-
{} as Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48104
|
+
{} as Params$Resource$Projects$Locations$Datastores$Servingconfigs$List;
|
|
47255
48105
|
options = {};
|
|
47256
48106
|
}
|
|
47257
48107
|
|
|
@@ -47265,34 +48115,34 @@ export namespace discoveryengine_v1 {
|
|
|
47265
48115
|
const parameters = {
|
|
47266
48116
|
options: Object.assign(
|
|
47267
48117
|
{
|
|
47268
|
-
url: (rootUrl + '/v1/{+
|
|
48118
|
+
url: (rootUrl + '/v1/{+parent}/servingConfigs').replace(
|
|
47269
48119
|
/([^:]\/)\/+/g,
|
|
47270
48120
|
'$1'
|
|
47271
48121
|
),
|
|
47272
|
-
method: '
|
|
48122
|
+
method: 'GET',
|
|
47273
48123
|
apiVersion: '',
|
|
47274
48124
|
},
|
|
47275
48125
|
options
|
|
47276
48126
|
),
|
|
47277
48127
|
params,
|
|
47278
|
-
requiredParams: ['
|
|
47279
|
-
pathParams: ['
|
|
48128
|
+
requiredParams: ['parent'],
|
|
48129
|
+
pathParams: ['parent'],
|
|
47280
48130
|
context: this.context,
|
|
47281
48131
|
};
|
|
47282
48132
|
if (callback) {
|
|
47283
|
-
createAPIRequest<Schema$
|
|
48133
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>(
|
|
47284
48134
|
parameters,
|
|
47285
48135
|
callback as BodyResponseCallback<unknown>
|
|
47286
48136
|
);
|
|
47287
48137
|
} else {
|
|
47288
|
-
return createAPIRequest<Schema$
|
|
48138
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ListServingConfigsResponse>(
|
|
47289
48139
|
parameters
|
|
47290
48140
|
);
|
|
47291
48141
|
}
|
|
47292
48142
|
}
|
|
47293
48143
|
|
|
47294
48144
|
/**
|
|
47295
|
-
*
|
|
48145
|
+
* Updates a ServingConfig. Returns a NOT_FOUND error if the ServingConfig does not exist.
|
|
47296
48146
|
* @example
|
|
47297
48147
|
* ```js
|
|
47298
48148
|
* // Before running the sample:
|
|
@@ -47315,7 +48165,6 @@ export namespace discoveryengine_v1 {
|
|
|
47315
48165
|
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
47316
48166
|
* scopes: [
|
|
47317
48167
|
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
47318
|
-
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
47319
48168
|
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
47320
48169
|
* ],
|
|
47321
48170
|
* });
|
|
@@ -47326,46 +48175,36 @@ export namespace discoveryengine_v1 {
|
|
|
47326
48175
|
*
|
|
47327
48176
|
* // Do the magic
|
|
47328
48177
|
* const res =
|
|
47329
|
-
* await discoveryengine.projects.locations.dataStores.servingConfigs.
|
|
47330
|
-
* //
|
|
47331
|
-
* servingConfig
|
|
47332
|
-
*
|
|
48178
|
+
* await discoveryengine.projects.locations.dataStores.servingConfigs.patch({
|
|
48179
|
+
* // Immutable. Fully qualified name `projects/{project\}/locations/{location\}/collections/{collection_id\}/engines/{engine_id\}/servingConfigs/{serving_config_id\}`
|
|
48180
|
+
* name: 'projects/my-project/locations/my-location/dataStores/my-dataStore/servingConfigs/my-servingConfig',
|
|
48181
|
+
* // Indicates which fields in the provided ServingConfig to update. The following are NOT supported: * ServingConfig.name If not set, all supported fields are updated.
|
|
48182
|
+
* updateMask: 'placeholder-value',
|
|
47333
48183
|
*
|
|
47334
48184
|
* // Request body metadata
|
|
47335
48185
|
* requestBody: {
|
|
47336
48186
|
* // request body parameters
|
|
47337
48187
|
* // {
|
|
47338
|
-
* // "
|
|
47339
|
-
* // "
|
|
47340
|
-
* // "
|
|
47341
|
-
* // "
|
|
47342
|
-
* // "
|
|
47343
|
-
* // "
|
|
47344
|
-
* // "
|
|
47345
|
-
* // "
|
|
47346
|
-
* // "
|
|
47347
|
-
* // "
|
|
47348
|
-
* // "
|
|
47349
|
-
* // "
|
|
47350
|
-
* // "
|
|
47351
|
-
* // "
|
|
47352
|
-
* // "pageSize": 0,
|
|
47353
|
-
* // "pageToken": "my_pageToken",
|
|
47354
|
-
* // "params": {},
|
|
47355
|
-
* // "query": "my_query",
|
|
47356
|
-
* // "queryExpansionSpec": {},
|
|
48188
|
+
* // "answerGenerationSpec": {},
|
|
48189
|
+
* // "boostControlIds": [],
|
|
48190
|
+
* // "createTime": "my_createTime",
|
|
48191
|
+
* // "displayName": "my_displayName",
|
|
48192
|
+
* // "dissociateControlIds": [],
|
|
48193
|
+
* // "diversityLevel": "my_diversityLevel",
|
|
48194
|
+
* // "filterControlIds": [],
|
|
48195
|
+
* // "genericConfig": {},
|
|
48196
|
+
* // "ignoreControlIds": [],
|
|
48197
|
+
* // "mediaConfig": {},
|
|
48198
|
+
* // "modelId": "my_modelId",
|
|
48199
|
+
* // "name": "my_name",
|
|
48200
|
+
* // "onewaySynonymsControlIds": [],
|
|
48201
|
+
* // "promoteControlIds": [],
|
|
47357
48202
|
* // "rankingExpression": "my_rankingExpression",
|
|
47358
|
-
* // "
|
|
47359
|
-
* // "
|
|
47360
|
-
* // "
|
|
47361
|
-
* // "
|
|
47362
|
-
* // "
|
|
47363
|
-
* // "session": "my_session",
|
|
47364
|
-
* // "sessionSpec": {},
|
|
47365
|
-
* // "spellCorrectionSpec": {},
|
|
47366
|
-
* // "userInfo": {},
|
|
47367
|
-
* // "userLabels": {},
|
|
47368
|
-
* // "userPseudoId": "my_userPseudoId"
|
|
48203
|
+
* // "redirectControlIds": [],
|
|
48204
|
+
* // "replacementControlIds": [],
|
|
48205
|
+
* // "solutionType": "my_solutionType",
|
|
48206
|
+
* // "synonymsControlIds": [],
|
|
48207
|
+
* // "updateTime": "my_updateTime"
|
|
47369
48208
|
* // }
|
|
47370
48209
|
* },
|
|
47371
48210
|
* });
|
|
@@ -47373,17 +48212,26 @@ export namespace discoveryengine_v1 {
|
|
|
47373
48212
|
*
|
|
47374
48213
|
* // Example response
|
|
47375
48214
|
* // {
|
|
47376
|
-
* // "
|
|
47377
|
-
* // "
|
|
47378
|
-
* // "
|
|
47379
|
-
* // "
|
|
47380
|
-
* // "
|
|
47381
|
-
* // "
|
|
47382
|
-
* // "
|
|
47383
|
-
* // "
|
|
47384
|
-
* // "
|
|
47385
|
-
* // "
|
|
47386
|
-
* // "
|
|
48215
|
+
* // "answerGenerationSpec": {},
|
|
48216
|
+
* // "boostControlIds": [],
|
|
48217
|
+
* // "createTime": "my_createTime",
|
|
48218
|
+
* // "displayName": "my_displayName",
|
|
48219
|
+
* // "dissociateControlIds": [],
|
|
48220
|
+
* // "diversityLevel": "my_diversityLevel",
|
|
48221
|
+
* // "filterControlIds": [],
|
|
48222
|
+
* // "genericConfig": {},
|
|
48223
|
+
* // "ignoreControlIds": [],
|
|
48224
|
+
* // "mediaConfig": {},
|
|
48225
|
+
* // "modelId": "my_modelId",
|
|
48226
|
+
* // "name": "my_name",
|
|
48227
|
+
* // "onewaySynonymsControlIds": [],
|
|
48228
|
+
* // "promoteControlIds": [],
|
|
48229
|
+
* // "rankingExpression": "my_rankingExpression",
|
|
48230
|
+
* // "redirectControlIds": [],
|
|
48231
|
+
* // "replacementControlIds": [],
|
|
48232
|
+
* // "solutionType": "my_solutionType",
|
|
48233
|
+
* // "synonymsControlIds": [],
|
|
48234
|
+
* // "updateTime": "my_updateTime"
|
|
47387
48235
|
* // }
|
|
47388
48236
|
* }
|
|
47389
48237
|
*
|
|
@@ -47399,62 +48247,62 @@ export namespace discoveryengine_v1 {
|
|
|
47399
48247
|
* @param callback - Optional callback that handles the response.
|
|
47400
48248
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
47401
48249
|
*/
|
|
47402
|
-
|
|
47403
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48250
|
+
patch(
|
|
48251
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch,
|
|
47404
48252
|
options: StreamMethodOptions
|
|
47405
48253
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
47406
|
-
|
|
47407
|
-
params?: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48254
|
+
patch(
|
|
48255
|
+
params?: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch,
|
|
47408
48256
|
options?: MethodOptions
|
|
47409
48257
|
): Promise<
|
|
47410
|
-
GaxiosResponseWithHTTP2<Schema$
|
|
48258
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47411
48259
|
>;
|
|
47412
|
-
|
|
47413
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48260
|
+
patch(
|
|
48261
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch,
|
|
47414
48262
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
47415
48263
|
callback: BodyResponseCallback<Readable>
|
|
47416
48264
|
): void;
|
|
47417
|
-
|
|
47418
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48265
|
+
patch(
|
|
48266
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch,
|
|
47419
48267
|
options:
|
|
47420
48268
|
| MethodOptions
|
|
47421
|
-
| BodyResponseCallback<Schema$
|
|
47422
|
-
callback: BodyResponseCallback<Schema$
|
|
48269
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>,
|
|
48270
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47423
48271
|
): void;
|
|
47424
|
-
|
|
47425
|
-
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47426
|
-
callback: BodyResponseCallback<Schema$
|
|
48272
|
+
patch(
|
|
48273
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch,
|
|
48274
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47427
48275
|
): void;
|
|
47428
|
-
|
|
47429
|
-
callback: BodyResponseCallback<Schema$
|
|
48276
|
+
patch(
|
|
48277
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47430
48278
|
): void;
|
|
47431
|
-
|
|
48279
|
+
patch(
|
|
47432
48280
|
paramsOrCallback?:
|
|
47433
|
-
| Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
47434
|
-
| BodyResponseCallback<Schema$
|
|
48281
|
+
| Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch
|
|
48282
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47435
48283
|
| BodyResponseCallback<Readable>,
|
|
47436
48284
|
optionsOrCallback?:
|
|
47437
48285
|
| MethodOptions
|
|
47438
48286
|
| StreamMethodOptions
|
|
47439
|
-
| BodyResponseCallback<Schema$
|
|
48287
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47440
48288
|
| BodyResponseCallback<Readable>,
|
|
47441
48289
|
callback?:
|
|
47442
|
-
| BodyResponseCallback<Schema$
|
|
48290
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47443
48291
|
| BodyResponseCallback<Readable>
|
|
47444
48292
|
):
|
|
47445
48293
|
| void
|
|
47446
48294
|
| Promise<
|
|
47447
|
-
GaxiosResponseWithHTTP2<Schema$
|
|
48295
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1ServingConfig>
|
|
47448
48296
|
>
|
|
47449
48297
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
47450
48298
|
let params = (paramsOrCallback ||
|
|
47451
|
-
{}) as Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48299
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch;
|
|
47452
48300
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
47453
48301
|
|
|
47454
48302
|
if (typeof paramsOrCallback === 'function') {
|
|
47455
48303
|
callback = paramsOrCallback;
|
|
47456
48304
|
params =
|
|
47457
|
-
{} as Params$Resource$Projects$Locations$Datastores$Servingconfigs$
|
|
48305
|
+
{} as Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch;
|
|
47458
48306
|
options = {};
|
|
47459
48307
|
}
|
|
47460
48308
|
|
|
@@ -47468,34 +48316,406 @@ export namespace discoveryengine_v1 {
|
|
|
47468
48316
|
const parameters = {
|
|
47469
48317
|
options: Object.assign(
|
|
47470
48318
|
{
|
|
47471
|
-
url: (rootUrl + '/v1/{+
|
|
47472
|
-
|
|
47473
|
-
'$1'
|
|
47474
|
-
),
|
|
47475
|
-
method: 'POST',
|
|
48319
|
+
url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
48320
|
+
method: 'PATCH',
|
|
47476
48321
|
apiVersion: '',
|
|
47477
48322
|
},
|
|
47478
48323
|
options
|
|
47479
48324
|
),
|
|
47480
48325
|
params,
|
|
47481
|
-
requiredParams: ['
|
|
47482
|
-
pathParams: ['
|
|
48326
|
+
requiredParams: ['name'],
|
|
48327
|
+
pathParams: ['name'],
|
|
47483
48328
|
context: this.context,
|
|
47484
48329
|
};
|
|
47485
48330
|
if (callback) {
|
|
47486
|
-
createAPIRequest<Schema$
|
|
48331
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ServingConfig>(
|
|
47487
48332
|
parameters,
|
|
47488
48333
|
callback as BodyResponseCallback<unknown>
|
|
47489
48334
|
);
|
|
47490
48335
|
} else {
|
|
47491
|
-
return createAPIRequest<Schema$
|
|
48336
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1ServingConfig>(
|
|
47492
48337
|
parameters
|
|
47493
48338
|
);
|
|
47494
48339
|
}
|
|
47495
48340
|
}
|
|
47496
48341
|
|
|
47497
48342
|
/**
|
|
47498
|
-
*
|
|
48343
|
+
* Makes a recommendation, which requires a contextual user event.
|
|
48344
|
+
* @example
|
|
48345
|
+
* ```js
|
|
48346
|
+
* // Before running the sample:
|
|
48347
|
+
* // - Enable the API at:
|
|
48348
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
48349
|
+
* // - Login into gcloud by running:
|
|
48350
|
+
* // ```sh
|
|
48351
|
+
* // $ gcloud auth application-default login
|
|
48352
|
+
* // ```
|
|
48353
|
+
* // - Install the npm module by running:
|
|
48354
|
+
* // ```sh
|
|
48355
|
+
* // $ npm install googleapis
|
|
48356
|
+
* // ```
|
|
48357
|
+
*
|
|
48358
|
+
* const {google} = require('googleapis');
|
|
48359
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
48360
|
+
*
|
|
48361
|
+
* async function main() {
|
|
48362
|
+
* const auth = new google.auth.GoogleAuth({
|
|
48363
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
48364
|
+
* scopes: [
|
|
48365
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
48366
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
48367
|
+
* ],
|
|
48368
|
+
* });
|
|
48369
|
+
*
|
|
48370
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
48371
|
+
* const authClient = await auth.getClient();
|
|
48372
|
+
* google.options({auth: authClient});
|
|
48373
|
+
*
|
|
48374
|
+
* // Do the magic
|
|
48375
|
+
* const res =
|
|
48376
|
+
* await discoveryengine.projects.locations.dataStores.servingConfigs.recommend(
|
|
48377
|
+
* {
|
|
48378
|
+
* // Required. Full resource name of a ServingConfig: `projects/x/locations/global/collections/x/engines/x/servingConfigs/x`, or `projects/x/locations/global/collections/x/dataStores/x/servingConfigs/x` One default serving config is created along with your recommendation engine creation. The engine ID is used as the ID of the default serving config. For example, for Engine `projects/x/locations/global/collections/x/engines/my-engine`, you can use `projects/x/locations/global/collections/x/engines/my-engine/servingConfigs/my-engine` for your RecommendationService.Recommend requests.
|
|
48379
|
+
* servingConfig:
|
|
48380
|
+
* 'projects/my-project/locations/my-location/dataStores/my-dataStore/servingConfigs/my-servingConfig',
|
|
48381
|
+
*
|
|
48382
|
+
* // Request body metadata
|
|
48383
|
+
* requestBody: {
|
|
48384
|
+
* // request body parameters
|
|
48385
|
+
* // {
|
|
48386
|
+
* // "filter": "my_filter",
|
|
48387
|
+
* // "pageSize": 0,
|
|
48388
|
+
* // "params": {},
|
|
48389
|
+
* // "userEvent": {},
|
|
48390
|
+
* // "userLabels": {},
|
|
48391
|
+
* // "validateOnly": false
|
|
48392
|
+
* // }
|
|
48393
|
+
* },
|
|
48394
|
+
* },
|
|
48395
|
+
* );
|
|
48396
|
+
* console.log(res.data);
|
|
48397
|
+
*
|
|
48398
|
+
* // Example response
|
|
48399
|
+
* // {
|
|
48400
|
+
* // "attributionToken": "my_attributionToken",
|
|
48401
|
+
* // "missingIds": [],
|
|
48402
|
+
* // "results": [],
|
|
48403
|
+
* // "validateOnly": false
|
|
48404
|
+
* // }
|
|
48405
|
+
* }
|
|
48406
|
+
*
|
|
48407
|
+
* main().catch(e => {
|
|
48408
|
+
* console.error(e);
|
|
48409
|
+
* throw e;
|
|
48410
|
+
* });
|
|
48411
|
+
*
|
|
48412
|
+
* ```
|
|
48413
|
+
*
|
|
48414
|
+
* @param params - Parameters for request
|
|
48415
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
48416
|
+
* @param callback - Optional callback that handles the response.
|
|
48417
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
48418
|
+
*/
|
|
48419
|
+
recommend(
|
|
48420
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Recommend,
|
|
48421
|
+
options: StreamMethodOptions
|
|
48422
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
48423
|
+
recommend(
|
|
48424
|
+
params?: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Recommend,
|
|
48425
|
+
options?: MethodOptions
|
|
48426
|
+
): Promise<
|
|
48427
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
48428
|
+
>;
|
|
48429
|
+
recommend(
|
|
48430
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Recommend,
|
|
48431
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
48432
|
+
callback: BodyResponseCallback<Readable>
|
|
48433
|
+
): void;
|
|
48434
|
+
recommend(
|
|
48435
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Recommend,
|
|
48436
|
+
options:
|
|
48437
|
+
| MethodOptions
|
|
48438
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>,
|
|
48439
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
48440
|
+
): void;
|
|
48441
|
+
recommend(
|
|
48442
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Recommend,
|
|
48443
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
48444
|
+
): void;
|
|
48445
|
+
recommend(
|
|
48446
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
48447
|
+
): void;
|
|
48448
|
+
recommend(
|
|
48449
|
+
paramsOrCallback?:
|
|
48450
|
+
| Params$Resource$Projects$Locations$Datastores$Servingconfigs$Recommend
|
|
48451
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
48452
|
+
| BodyResponseCallback<Readable>,
|
|
48453
|
+
optionsOrCallback?:
|
|
48454
|
+
| MethodOptions
|
|
48455
|
+
| StreamMethodOptions
|
|
48456
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
48457
|
+
| BodyResponseCallback<Readable>,
|
|
48458
|
+
callback?:
|
|
48459
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
48460
|
+
| BodyResponseCallback<Readable>
|
|
48461
|
+
):
|
|
48462
|
+
| void
|
|
48463
|
+
| Promise<
|
|
48464
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>
|
|
48465
|
+
>
|
|
48466
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
48467
|
+
let params = (paramsOrCallback ||
|
|
48468
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Servingconfigs$Recommend;
|
|
48469
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
48470
|
+
|
|
48471
|
+
if (typeof paramsOrCallback === 'function') {
|
|
48472
|
+
callback = paramsOrCallback;
|
|
48473
|
+
params =
|
|
48474
|
+
{} as Params$Resource$Projects$Locations$Datastores$Servingconfigs$Recommend;
|
|
48475
|
+
options = {};
|
|
48476
|
+
}
|
|
48477
|
+
|
|
48478
|
+
if (typeof optionsOrCallback === 'function') {
|
|
48479
|
+
callback = optionsOrCallback;
|
|
48480
|
+
options = {};
|
|
48481
|
+
}
|
|
48482
|
+
|
|
48483
|
+
const rootUrl =
|
|
48484
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
48485
|
+
const parameters = {
|
|
48486
|
+
options: Object.assign(
|
|
48487
|
+
{
|
|
48488
|
+
url: (rootUrl + '/v1/{+servingConfig}:recommend').replace(
|
|
48489
|
+
/([^:]\/)\/+/g,
|
|
48490
|
+
'$1'
|
|
48491
|
+
),
|
|
48492
|
+
method: 'POST',
|
|
48493
|
+
apiVersion: '',
|
|
48494
|
+
},
|
|
48495
|
+
options
|
|
48496
|
+
),
|
|
48497
|
+
params,
|
|
48498
|
+
requiredParams: ['servingConfig'],
|
|
48499
|
+
pathParams: ['servingConfig'],
|
|
48500
|
+
context: this.context,
|
|
48501
|
+
};
|
|
48502
|
+
if (callback) {
|
|
48503
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>(
|
|
48504
|
+
parameters,
|
|
48505
|
+
callback as BodyResponseCallback<unknown>
|
|
48506
|
+
);
|
|
48507
|
+
} else {
|
|
48508
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1RecommendResponse>(
|
|
48509
|
+
parameters
|
|
48510
|
+
);
|
|
48511
|
+
}
|
|
48512
|
+
}
|
|
48513
|
+
|
|
48514
|
+
/**
|
|
48515
|
+
* Performs a search.
|
|
48516
|
+
* @example
|
|
48517
|
+
* ```js
|
|
48518
|
+
* // Before running the sample:
|
|
48519
|
+
* // - Enable the API at:
|
|
48520
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
48521
|
+
* // - Login into gcloud by running:
|
|
48522
|
+
* // ```sh
|
|
48523
|
+
* // $ gcloud auth application-default login
|
|
48524
|
+
* // ```
|
|
48525
|
+
* // - Install the npm module by running:
|
|
48526
|
+
* // ```sh
|
|
48527
|
+
* // $ npm install googleapis
|
|
48528
|
+
* // ```
|
|
48529
|
+
*
|
|
48530
|
+
* const {google} = require('googleapis');
|
|
48531
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
48532
|
+
*
|
|
48533
|
+
* async function main() {
|
|
48534
|
+
* const auth = new google.auth.GoogleAuth({
|
|
48535
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
48536
|
+
* scopes: [
|
|
48537
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
48538
|
+
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
48539
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
48540
|
+
* ],
|
|
48541
|
+
* });
|
|
48542
|
+
*
|
|
48543
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
48544
|
+
* const authClient = await auth.getClient();
|
|
48545
|
+
* google.options({auth: authClient});
|
|
48546
|
+
*
|
|
48547
|
+
* // Do the magic
|
|
48548
|
+
* const res =
|
|
48549
|
+
* await discoveryengine.projects.locations.dataStores.servingConfigs.search({
|
|
48550
|
+
* // Required. The resource name of the Search serving config, such as `projects/x/locations/global/collections/default_collection/engines/x/servingConfigs/default_serving_config`, or `projects/x/locations/global/collections/default_collection/dataStores/default_data_store/servingConfigs/default_serving_config`. This field is used to identify the serving configuration name, set of models used to make the search.
|
|
48551
|
+
* servingConfig:
|
|
48552
|
+
* 'projects/my-project/locations/my-location/dataStores/my-dataStore/servingConfigs/my-servingConfig',
|
|
48553
|
+
*
|
|
48554
|
+
* // Request body metadata
|
|
48555
|
+
* requestBody: {
|
|
48556
|
+
* // request body parameters
|
|
48557
|
+
* // {
|
|
48558
|
+
* // "boostSpec": {},
|
|
48559
|
+
* // "branch": "my_branch",
|
|
48560
|
+
* // "canonicalFilter": "my_canonicalFilter",
|
|
48561
|
+
* // "contentSearchSpec": {},
|
|
48562
|
+
* // "dataStoreSpecs": [],
|
|
48563
|
+
* // "displaySpec": {},
|
|
48564
|
+
* // "facetSpecs": [],
|
|
48565
|
+
* // "filter": "my_filter",
|
|
48566
|
+
* // "imageQuery": {},
|
|
48567
|
+
* // "languageCode": "my_languageCode",
|
|
48568
|
+
* // "naturalLanguageQueryUnderstandingSpec": {},
|
|
48569
|
+
* // "offset": 0,
|
|
48570
|
+
* // "oneBoxPageSize": 0,
|
|
48571
|
+
* // "orderBy": "my_orderBy",
|
|
48572
|
+
* // "pageSize": 0,
|
|
48573
|
+
* // "pageToken": "my_pageToken",
|
|
48574
|
+
* // "params": {},
|
|
48575
|
+
* // "query": "my_query",
|
|
48576
|
+
* // "queryExpansionSpec": {},
|
|
48577
|
+
* // "rankingExpression": "my_rankingExpression",
|
|
48578
|
+
* // "rankingExpressionBackend": "my_rankingExpressionBackend",
|
|
48579
|
+
* // "relevanceScoreSpec": {},
|
|
48580
|
+
* // "relevanceThreshold": "my_relevanceThreshold",
|
|
48581
|
+
* // "safeSearch": false,
|
|
48582
|
+
* // "searchAsYouTypeSpec": {},
|
|
48583
|
+
* // "session": "my_session",
|
|
48584
|
+
* // "sessionSpec": {},
|
|
48585
|
+
* // "spellCorrectionSpec": {},
|
|
48586
|
+
* // "userInfo": {},
|
|
48587
|
+
* // "userLabels": {},
|
|
48588
|
+
* // "userPseudoId": "my_userPseudoId"
|
|
48589
|
+
* // }
|
|
48590
|
+
* },
|
|
48591
|
+
* });
|
|
48592
|
+
* console.log(res.data);
|
|
48593
|
+
*
|
|
48594
|
+
* // Example response
|
|
48595
|
+
* // {
|
|
48596
|
+
* // "attributionToken": "my_attributionToken",
|
|
48597
|
+
* // "correctedQuery": "my_correctedQuery",
|
|
48598
|
+
* // "facets": [],
|
|
48599
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
48600
|
+
* // "queryExpansionInfo": {},
|
|
48601
|
+
* // "redirectUri": "my_redirectUri",
|
|
48602
|
+
* // "results": [],
|
|
48603
|
+
* // "searchLinkPromotions": [],
|
|
48604
|
+
* // "sessionInfo": {},
|
|
48605
|
+
* // "summary": {},
|
|
48606
|
+
* // "totalSize": 0
|
|
48607
|
+
* // }
|
|
48608
|
+
* }
|
|
48609
|
+
*
|
|
48610
|
+
* main().catch(e => {
|
|
48611
|
+
* console.error(e);
|
|
48612
|
+
* throw e;
|
|
48613
|
+
* });
|
|
48614
|
+
*
|
|
48615
|
+
* ```
|
|
48616
|
+
*
|
|
48617
|
+
* @param params - Parameters for request
|
|
48618
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
48619
|
+
* @param callback - Optional callback that handles the response.
|
|
48620
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
48621
|
+
*/
|
|
48622
|
+
search(
|
|
48623
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Search,
|
|
48624
|
+
options: StreamMethodOptions
|
|
48625
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
48626
|
+
search(
|
|
48627
|
+
params?: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Search,
|
|
48628
|
+
options?: MethodOptions
|
|
48629
|
+
): Promise<
|
|
48630
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
48631
|
+
>;
|
|
48632
|
+
search(
|
|
48633
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Search,
|
|
48634
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
48635
|
+
callback: BodyResponseCallback<Readable>
|
|
48636
|
+
): void;
|
|
48637
|
+
search(
|
|
48638
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Search,
|
|
48639
|
+
options:
|
|
48640
|
+
| MethodOptions
|
|
48641
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>,
|
|
48642
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
48643
|
+
): void;
|
|
48644
|
+
search(
|
|
48645
|
+
params: Params$Resource$Projects$Locations$Datastores$Servingconfigs$Search,
|
|
48646
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
48647
|
+
): void;
|
|
48648
|
+
search(
|
|
48649
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
48650
|
+
): void;
|
|
48651
|
+
search(
|
|
48652
|
+
paramsOrCallback?:
|
|
48653
|
+
| Params$Resource$Projects$Locations$Datastores$Servingconfigs$Search
|
|
48654
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
48655
|
+
| BodyResponseCallback<Readable>,
|
|
48656
|
+
optionsOrCallback?:
|
|
48657
|
+
| MethodOptions
|
|
48658
|
+
| StreamMethodOptions
|
|
48659
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
48660
|
+
| BodyResponseCallback<Readable>,
|
|
48661
|
+
callback?:
|
|
48662
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
48663
|
+
| BodyResponseCallback<Readable>
|
|
48664
|
+
):
|
|
48665
|
+
| void
|
|
48666
|
+
| Promise<
|
|
48667
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1SearchResponse>
|
|
48668
|
+
>
|
|
48669
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
48670
|
+
let params = (paramsOrCallback ||
|
|
48671
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Servingconfigs$Search;
|
|
48672
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
48673
|
+
|
|
48674
|
+
if (typeof paramsOrCallback === 'function') {
|
|
48675
|
+
callback = paramsOrCallback;
|
|
48676
|
+
params =
|
|
48677
|
+
{} as Params$Resource$Projects$Locations$Datastores$Servingconfigs$Search;
|
|
48678
|
+
options = {};
|
|
48679
|
+
}
|
|
48680
|
+
|
|
48681
|
+
if (typeof optionsOrCallback === 'function') {
|
|
48682
|
+
callback = optionsOrCallback;
|
|
48683
|
+
options = {};
|
|
48684
|
+
}
|
|
48685
|
+
|
|
48686
|
+
const rootUrl =
|
|
48687
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
48688
|
+
const parameters = {
|
|
48689
|
+
options: Object.assign(
|
|
48690
|
+
{
|
|
48691
|
+
url: (rootUrl + '/v1/{+servingConfig}:search').replace(
|
|
48692
|
+
/([^:]\/)\/+/g,
|
|
48693
|
+
'$1'
|
|
48694
|
+
),
|
|
48695
|
+
method: 'POST',
|
|
48696
|
+
apiVersion: '',
|
|
48697
|
+
},
|
|
48698
|
+
options
|
|
48699
|
+
),
|
|
48700
|
+
params,
|
|
48701
|
+
requiredParams: ['servingConfig'],
|
|
48702
|
+
pathParams: ['servingConfig'],
|
|
48703
|
+
context: this.context,
|
|
48704
|
+
};
|
|
48705
|
+
if (callback) {
|
|
48706
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1SearchResponse>(
|
|
48707
|
+
parameters,
|
|
48708
|
+
callback as BodyResponseCallback<unknown>
|
|
48709
|
+
);
|
|
48710
|
+
} else {
|
|
48711
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1SearchResponse>(
|
|
48712
|
+
parameters
|
|
48713
|
+
);
|
|
48714
|
+
}
|
|
48715
|
+
}
|
|
48716
|
+
|
|
48717
|
+
/**
|
|
48718
|
+
* Performs a search. Similar to the SearchService.Search method, but a lite version that allows API key for authentication, where OAuth and IAM checks are not required. Only public website search is supported by this method. If data stores and engines not associated with public website search are specified, a `FAILED_PRECONDITION` error is returned. This method can be used for easy onboarding without having to implement an authentication backend. However, it is strongly recommended to use SearchService.Search instead with required OAuth and IAM checks to provide better data security.
|
|
47499
48719
|
* @example
|
|
47500
48720
|
* ```js
|
|
47501
48721
|
* // Before running the sample:
|
|
@@ -47889,6 +49109,28 @@ export namespace discoveryengine_v1 {
|
|
|
47889
49109
|
*/
|
|
47890
49110
|
requestBody?: Schema$GoogleCloudDiscoveryengineV1AnswerQueryRequest;
|
|
47891
49111
|
}
|
|
49112
|
+
export interface Params$Resource$Projects$Locations$Datastores$Servingconfigs$Get
|
|
49113
|
+
extends StandardParameters {
|
|
49114
|
+
/**
|
|
49115
|
+
* Required. The resource name of the ServingConfig to get. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}/servingConfigs/{serving_config_id\}`
|
|
49116
|
+
*/
|
|
49117
|
+
name?: string;
|
|
49118
|
+
}
|
|
49119
|
+
export interface Params$Resource$Projects$Locations$Datastores$Servingconfigs$List
|
|
49120
|
+
extends StandardParameters {
|
|
49121
|
+
/**
|
|
49122
|
+
* Optional. Maximum number of results to return. If unspecified, defaults to 100. If a value greater than 100 is provided, at most 100 results are returned.
|
|
49123
|
+
*/
|
|
49124
|
+
pageSize?: number;
|
|
49125
|
+
/**
|
|
49126
|
+
* Optional. A page token, received from a previous `ListServingConfigs` call. Provide this to retrieve the subsequent page.
|
|
49127
|
+
*/
|
|
49128
|
+
pageToken?: string;
|
|
49129
|
+
/**
|
|
49130
|
+
* Required. Full resource name of the parent resource. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}`
|
|
49131
|
+
*/
|
|
49132
|
+
parent?: string;
|
|
49133
|
+
}
|
|
47892
49134
|
export interface Params$Resource$Projects$Locations$Datastores$Servingconfigs$Patch
|
|
47893
49135
|
extends StandardParameters {
|
|
47894
49136
|
/**
|
|
@@ -55993,6 +57235,639 @@ export namespace discoveryengine_v1 {
|
|
|
55993
57235
|
return createAPIRequest<Schema$GoogleLongrunningOperation>(parameters);
|
|
55994
57236
|
}
|
|
55995
57237
|
}
|
|
57238
|
+
|
|
57239
|
+
/**
|
|
57240
|
+
* Creates a new User Store.
|
|
57241
|
+
* @example
|
|
57242
|
+
* ```js
|
|
57243
|
+
* // Before running the sample:
|
|
57244
|
+
* // - Enable the API at:
|
|
57245
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
57246
|
+
* // - Login into gcloud by running:
|
|
57247
|
+
* // ```sh
|
|
57248
|
+
* // $ gcloud auth application-default login
|
|
57249
|
+
* // ```
|
|
57250
|
+
* // - Install the npm module by running:
|
|
57251
|
+
* // ```sh
|
|
57252
|
+
* // $ npm install googleapis
|
|
57253
|
+
* // ```
|
|
57254
|
+
*
|
|
57255
|
+
* const {google} = require('googleapis');
|
|
57256
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
57257
|
+
*
|
|
57258
|
+
* async function main() {
|
|
57259
|
+
* const auth = new google.auth.GoogleAuth({
|
|
57260
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
57261
|
+
* scopes: [
|
|
57262
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
57263
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
57264
|
+
* ],
|
|
57265
|
+
* });
|
|
57266
|
+
*
|
|
57267
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
57268
|
+
* const authClient = await auth.getClient();
|
|
57269
|
+
* google.options({auth: authClient});
|
|
57270
|
+
*
|
|
57271
|
+
* // Do the magic
|
|
57272
|
+
* const res = await discoveryengine.projects.locations.userStores.create({
|
|
57273
|
+
* // Required. The parent collection resource name, such as `projects/{project\}/locations/{location\}`.
|
|
57274
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
57275
|
+
* // Required. The ID of the User Store to create. The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 63 characters.
|
|
57276
|
+
* userStoreId: 'placeholder-value',
|
|
57277
|
+
*
|
|
57278
|
+
* // Request body metadata
|
|
57279
|
+
* requestBody: {
|
|
57280
|
+
* // request body parameters
|
|
57281
|
+
* // {
|
|
57282
|
+
* // "defaultLicenseConfig": "my_defaultLicenseConfig",
|
|
57283
|
+
* // "displayName": "my_displayName",
|
|
57284
|
+
* // "enableExpiredLicenseAutoUpdate": false,
|
|
57285
|
+
* // "enableLicenseAutoRegister": false,
|
|
57286
|
+
* // "name": "my_name"
|
|
57287
|
+
* // }
|
|
57288
|
+
* },
|
|
57289
|
+
* });
|
|
57290
|
+
* console.log(res.data);
|
|
57291
|
+
*
|
|
57292
|
+
* // Example response
|
|
57293
|
+
* // {
|
|
57294
|
+
* // "defaultLicenseConfig": "my_defaultLicenseConfig",
|
|
57295
|
+
* // "displayName": "my_displayName",
|
|
57296
|
+
* // "enableExpiredLicenseAutoUpdate": false,
|
|
57297
|
+
* // "enableLicenseAutoRegister": false,
|
|
57298
|
+
* // "name": "my_name"
|
|
57299
|
+
* // }
|
|
57300
|
+
* }
|
|
57301
|
+
*
|
|
57302
|
+
* main().catch(e => {
|
|
57303
|
+
* console.error(e);
|
|
57304
|
+
* throw e;
|
|
57305
|
+
* });
|
|
57306
|
+
*
|
|
57307
|
+
* ```
|
|
57308
|
+
*
|
|
57309
|
+
* @param params - Parameters for request
|
|
57310
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
57311
|
+
* @param callback - Optional callback that handles the response.
|
|
57312
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
57313
|
+
*/
|
|
57314
|
+
create(
|
|
57315
|
+
params: Params$Resource$Projects$Locations$Userstores$Create,
|
|
57316
|
+
options: StreamMethodOptions
|
|
57317
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
57318
|
+
create(
|
|
57319
|
+
params?: Params$Resource$Projects$Locations$Userstores$Create,
|
|
57320
|
+
options?: MethodOptions
|
|
57321
|
+
): Promise<
|
|
57322
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57323
|
+
>;
|
|
57324
|
+
create(
|
|
57325
|
+
params: Params$Resource$Projects$Locations$Userstores$Create,
|
|
57326
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
57327
|
+
callback: BodyResponseCallback<Readable>
|
|
57328
|
+
): void;
|
|
57329
|
+
create(
|
|
57330
|
+
params: Params$Resource$Projects$Locations$Userstores$Create,
|
|
57331
|
+
options:
|
|
57332
|
+
| MethodOptions
|
|
57333
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>,
|
|
57334
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57335
|
+
): void;
|
|
57336
|
+
create(
|
|
57337
|
+
params: Params$Resource$Projects$Locations$Userstores$Create,
|
|
57338
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57339
|
+
): void;
|
|
57340
|
+
create(
|
|
57341
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57342
|
+
): void;
|
|
57343
|
+
create(
|
|
57344
|
+
paramsOrCallback?:
|
|
57345
|
+
| Params$Resource$Projects$Locations$Userstores$Create
|
|
57346
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57347
|
+
| BodyResponseCallback<Readable>,
|
|
57348
|
+
optionsOrCallback?:
|
|
57349
|
+
| MethodOptions
|
|
57350
|
+
| StreamMethodOptions
|
|
57351
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57352
|
+
| BodyResponseCallback<Readable>,
|
|
57353
|
+
callback?:
|
|
57354
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57355
|
+
| BodyResponseCallback<Readable>
|
|
57356
|
+
):
|
|
57357
|
+
| void
|
|
57358
|
+
| Promise<
|
|
57359
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57360
|
+
>
|
|
57361
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
57362
|
+
let params = (paramsOrCallback ||
|
|
57363
|
+
{}) as Params$Resource$Projects$Locations$Userstores$Create;
|
|
57364
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
57365
|
+
|
|
57366
|
+
if (typeof paramsOrCallback === 'function') {
|
|
57367
|
+
callback = paramsOrCallback;
|
|
57368
|
+
params = {} as Params$Resource$Projects$Locations$Userstores$Create;
|
|
57369
|
+
options = {};
|
|
57370
|
+
}
|
|
57371
|
+
|
|
57372
|
+
if (typeof optionsOrCallback === 'function') {
|
|
57373
|
+
callback = optionsOrCallback;
|
|
57374
|
+
options = {};
|
|
57375
|
+
}
|
|
57376
|
+
|
|
57377
|
+
const rootUrl =
|
|
57378
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
57379
|
+
const parameters = {
|
|
57380
|
+
options: Object.assign(
|
|
57381
|
+
{
|
|
57382
|
+
url: (rootUrl + '/v1/{+parent}/userStores').replace(
|
|
57383
|
+
/([^:]\/)\/+/g,
|
|
57384
|
+
'$1'
|
|
57385
|
+
),
|
|
57386
|
+
method: 'POST',
|
|
57387
|
+
apiVersion: '',
|
|
57388
|
+
},
|
|
57389
|
+
options
|
|
57390
|
+
),
|
|
57391
|
+
params,
|
|
57392
|
+
requiredParams: ['parent'],
|
|
57393
|
+
pathParams: ['parent'],
|
|
57394
|
+
context: this.context,
|
|
57395
|
+
};
|
|
57396
|
+
if (callback) {
|
|
57397
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1UserStore>(
|
|
57398
|
+
parameters,
|
|
57399
|
+
callback as BodyResponseCallback<unknown>
|
|
57400
|
+
);
|
|
57401
|
+
} else {
|
|
57402
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1UserStore>(
|
|
57403
|
+
parameters
|
|
57404
|
+
);
|
|
57405
|
+
}
|
|
57406
|
+
}
|
|
57407
|
+
|
|
57408
|
+
/**
|
|
57409
|
+
* Deletes the User Store.
|
|
57410
|
+
* @example
|
|
57411
|
+
* ```js
|
|
57412
|
+
* // Before running the sample:
|
|
57413
|
+
* // - Enable the API at:
|
|
57414
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
57415
|
+
* // - Login into gcloud by running:
|
|
57416
|
+
* // ```sh
|
|
57417
|
+
* // $ gcloud auth application-default login
|
|
57418
|
+
* // ```
|
|
57419
|
+
* // - Install the npm module by running:
|
|
57420
|
+
* // ```sh
|
|
57421
|
+
* // $ npm install googleapis
|
|
57422
|
+
* // ```
|
|
57423
|
+
*
|
|
57424
|
+
* const {google} = require('googleapis');
|
|
57425
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
57426
|
+
*
|
|
57427
|
+
* async function main() {
|
|
57428
|
+
* const auth = new google.auth.GoogleAuth({
|
|
57429
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
57430
|
+
* scopes: [
|
|
57431
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
57432
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
57433
|
+
* ],
|
|
57434
|
+
* });
|
|
57435
|
+
*
|
|
57436
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
57437
|
+
* const authClient = await auth.getClient();
|
|
57438
|
+
* google.options({auth: authClient});
|
|
57439
|
+
*
|
|
57440
|
+
* // Do the magic
|
|
57441
|
+
* const res = await discoveryengine.projects.locations.userStores.delete({
|
|
57442
|
+
* // Required. The name of the User Store to delete. Format: `projects/{project\}/locations/{location\}/userStores/{user_store_id\}`
|
|
57443
|
+
* name: 'projects/my-project/locations/my-location/userStores/my-userStore',
|
|
57444
|
+
* });
|
|
57445
|
+
* console.log(res.data);
|
|
57446
|
+
*
|
|
57447
|
+
* // Example response
|
|
57448
|
+
* // {
|
|
57449
|
+
* // "done": false,
|
|
57450
|
+
* // "error": {},
|
|
57451
|
+
* // "metadata": {},
|
|
57452
|
+
* // "name": "my_name",
|
|
57453
|
+
* // "response": {}
|
|
57454
|
+
* // }
|
|
57455
|
+
* }
|
|
57456
|
+
*
|
|
57457
|
+
* main().catch(e => {
|
|
57458
|
+
* console.error(e);
|
|
57459
|
+
* throw e;
|
|
57460
|
+
* });
|
|
57461
|
+
*
|
|
57462
|
+
* ```
|
|
57463
|
+
*
|
|
57464
|
+
* @param params - Parameters for request
|
|
57465
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
57466
|
+
* @param callback - Optional callback that handles the response.
|
|
57467
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
57468
|
+
*/
|
|
57469
|
+
delete(
|
|
57470
|
+
params: Params$Resource$Projects$Locations$Userstores$Delete,
|
|
57471
|
+
options: StreamMethodOptions
|
|
57472
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
57473
|
+
delete(
|
|
57474
|
+
params?: Params$Resource$Projects$Locations$Userstores$Delete,
|
|
57475
|
+
options?: MethodOptions
|
|
57476
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>;
|
|
57477
|
+
delete(
|
|
57478
|
+
params: Params$Resource$Projects$Locations$Userstores$Delete,
|
|
57479
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
57480
|
+
callback: BodyResponseCallback<Readable>
|
|
57481
|
+
): void;
|
|
57482
|
+
delete(
|
|
57483
|
+
params: Params$Resource$Projects$Locations$Userstores$Delete,
|
|
57484
|
+
options:
|
|
57485
|
+
| MethodOptions
|
|
57486
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>,
|
|
57487
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
57488
|
+
): void;
|
|
57489
|
+
delete(
|
|
57490
|
+
params: Params$Resource$Projects$Locations$Userstores$Delete,
|
|
57491
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
57492
|
+
): void;
|
|
57493
|
+
delete(
|
|
57494
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
57495
|
+
): void;
|
|
57496
|
+
delete(
|
|
57497
|
+
paramsOrCallback?:
|
|
57498
|
+
| Params$Resource$Projects$Locations$Userstores$Delete
|
|
57499
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
57500
|
+
| BodyResponseCallback<Readable>,
|
|
57501
|
+
optionsOrCallback?:
|
|
57502
|
+
| MethodOptions
|
|
57503
|
+
| StreamMethodOptions
|
|
57504
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
57505
|
+
| BodyResponseCallback<Readable>,
|
|
57506
|
+
callback?:
|
|
57507
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
57508
|
+
| BodyResponseCallback<Readable>
|
|
57509
|
+
):
|
|
57510
|
+
| void
|
|
57511
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>
|
|
57512
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
57513
|
+
let params = (paramsOrCallback ||
|
|
57514
|
+
{}) as Params$Resource$Projects$Locations$Userstores$Delete;
|
|
57515
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
57516
|
+
|
|
57517
|
+
if (typeof paramsOrCallback === 'function') {
|
|
57518
|
+
callback = paramsOrCallback;
|
|
57519
|
+
params = {} as Params$Resource$Projects$Locations$Userstores$Delete;
|
|
57520
|
+
options = {};
|
|
57521
|
+
}
|
|
57522
|
+
|
|
57523
|
+
if (typeof optionsOrCallback === 'function') {
|
|
57524
|
+
callback = optionsOrCallback;
|
|
57525
|
+
options = {};
|
|
57526
|
+
}
|
|
57527
|
+
|
|
57528
|
+
const rootUrl =
|
|
57529
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
57530
|
+
const parameters = {
|
|
57531
|
+
options: Object.assign(
|
|
57532
|
+
{
|
|
57533
|
+
url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
57534
|
+
method: 'DELETE',
|
|
57535
|
+
apiVersion: '',
|
|
57536
|
+
},
|
|
57537
|
+
options
|
|
57538
|
+
),
|
|
57539
|
+
params,
|
|
57540
|
+
requiredParams: ['name'],
|
|
57541
|
+
pathParams: ['name'],
|
|
57542
|
+
context: this.context,
|
|
57543
|
+
};
|
|
57544
|
+
if (callback) {
|
|
57545
|
+
createAPIRequest<Schema$GoogleLongrunningOperation>(
|
|
57546
|
+
parameters,
|
|
57547
|
+
callback as BodyResponseCallback<unknown>
|
|
57548
|
+
);
|
|
57549
|
+
} else {
|
|
57550
|
+
return createAPIRequest<Schema$GoogleLongrunningOperation>(parameters);
|
|
57551
|
+
}
|
|
57552
|
+
}
|
|
57553
|
+
|
|
57554
|
+
/**
|
|
57555
|
+
* Gets the User Store.
|
|
57556
|
+
* @example
|
|
57557
|
+
* ```js
|
|
57558
|
+
* // Before running the sample:
|
|
57559
|
+
* // - Enable the API at:
|
|
57560
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
57561
|
+
* // - Login into gcloud by running:
|
|
57562
|
+
* // ```sh
|
|
57563
|
+
* // $ gcloud auth application-default login
|
|
57564
|
+
* // ```
|
|
57565
|
+
* // - Install the npm module by running:
|
|
57566
|
+
* // ```sh
|
|
57567
|
+
* // $ npm install googleapis
|
|
57568
|
+
* // ```
|
|
57569
|
+
*
|
|
57570
|
+
* const {google} = require('googleapis');
|
|
57571
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
57572
|
+
*
|
|
57573
|
+
* async function main() {
|
|
57574
|
+
* const auth = new google.auth.GoogleAuth({
|
|
57575
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
57576
|
+
* scopes: [
|
|
57577
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
57578
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
57579
|
+
* ],
|
|
57580
|
+
* });
|
|
57581
|
+
*
|
|
57582
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
57583
|
+
* const authClient = await auth.getClient();
|
|
57584
|
+
* google.options({auth: authClient});
|
|
57585
|
+
*
|
|
57586
|
+
* // Do the magic
|
|
57587
|
+
* const res = await discoveryengine.projects.locations.userStores.get({
|
|
57588
|
+
* // Required. The name of the User Store to get. Format: `projects/{project\}/locations/{location\}/userStores/{user_store_id\}`
|
|
57589
|
+
* name: 'projects/my-project/locations/my-location/userStores/my-userStore',
|
|
57590
|
+
* });
|
|
57591
|
+
* console.log(res.data);
|
|
57592
|
+
*
|
|
57593
|
+
* // Example response
|
|
57594
|
+
* // {
|
|
57595
|
+
* // "defaultLicenseConfig": "my_defaultLicenseConfig",
|
|
57596
|
+
* // "displayName": "my_displayName",
|
|
57597
|
+
* // "enableExpiredLicenseAutoUpdate": false,
|
|
57598
|
+
* // "enableLicenseAutoRegister": false,
|
|
57599
|
+
* // "name": "my_name"
|
|
57600
|
+
* // }
|
|
57601
|
+
* }
|
|
57602
|
+
*
|
|
57603
|
+
* main().catch(e => {
|
|
57604
|
+
* console.error(e);
|
|
57605
|
+
* throw e;
|
|
57606
|
+
* });
|
|
57607
|
+
*
|
|
57608
|
+
* ```
|
|
57609
|
+
*
|
|
57610
|
+
* @param params - Parameters for request
|
|
57611
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
57612
|
+
* @param callback - Optional callback that handles the response.
|
|
57613
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
57614
|
+
*/
|
|
57615
|
+
get(
|
|
57616
|
+
params: Params$Resource$Projects$Locations$Userstores$Get,
|
|
57617
|
+
options: StreamMethodOptions
|
|
57618
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
57619
|
+
get(
|
|
57620
|
+
params?: Params$Resource$Projects$Locations$Userstores$Get,
|
|
57621
|
+
options?: MethodOptions
|
|
57622
|
+
): Promise<
|
|
57623
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57624
|
+
>;
|
|
57625
|
+
get(
|
|
57626
|
+
params: Params$Resource$Projects$Locations$Userstores$Get,
|
|
57627
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
57628
|
+
callback: BodyResponseCallback<Readable>
|
|
57629
|
+
): void;
|
|
57630
|
+
get(
|
|
57631
|
+
params: Params$Resource$Projects$Locations$Userstores$Get,
|
|
57632
|
+
options:
|
|
57633
|
+
| MethodOptions
|
|
57634
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>,
|
|
57635
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57636
|
+
): void;
|
|
57637
|
+
get(
|
|
57638
|
+
params: Params$Resource$Projects$Locations$Userstores$Get,
|
|
57639
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57640
|
+
): void;
|
|
57641
|
+
get(
|
|
57642
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57643
|
+
): void;
|
|
57644
|
+
get(
|
|
57645
|
+
paramsOrCallback?:
|
|
57646
|
+
| Params$Resource$Projects$Locations$Userstores$Get
|
|
57647
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57648
|
+
| BodyResponseCallback<Readable>,
|
|
57649
|
+
optionsOrCallback?:
|
|
57650
|
+
| MethodOptions
|
|
57651
|
+
| StreamMethodOptions
|
|
57652
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57653
|
+
| BodyResponseCallback<Readable>,
|
|
57654
|
+
callback?:
|
|
57655
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57656
|
+
| BodyResponseCallback<Readable>
|
|
57657
|
+
):
|
|
57658
|
+
| void
|
|
57659
|
+
| Promise<
|
|
57660
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57661
|
+
>
|
|
57662
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
57663
|
+
let params = (paramsOrCallback ||
|
|
57664
|
+
{}) as Params$Resource$Projects$Locations$Userstores$Get;
|
|
57665
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
57666
|
+
|
|
57667
|
+
if (typeof paramsOrCallback === 'function') {
|
|
57668
|
+
callback = paramsOrCallback;
|
|
57669
|
+
params = {} as Params$Resource$Projects$Locations$Userstores$Get;
|
|
57670
|
+
options = {};
|
|
57671
|
+
}
|
|
57672
|
+
|
|
57673
|
+
if (typeof optionsOrCallback === 'function') {
|
|
57674
|
+
callback = optionsOrCallback;
|
|
57675
|
+
options = {};
|
|
57676
|
+
}
|
|
57677
|
+
|
|
57678
|
+
const rootUrl =
|
|
57679
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
57680
|
+
const parameters = {
|
|
57681
|
+
options: Object.assign(
|
|
57682
|
+
{
|
|
57683
|
+
url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
57684
|
+
method: 'GET',
|
|
57685
|
+
apiVersion: '',
|
|
57686
|
+
},
|
|
57687
|
+
options
|
|
57688
|
+
),
|
|
57689
|
+
params,
|
|
57690
|
+
requiredParams: ['name'],
|
|
57691
|
+
pathParams: ['name'],
|
|
57692
|
+
context: this.context,
|
|
57693
|
+
};
|
|
57694
|
+
if (callback) {
|
|
57695
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1UserStore>(
|
|
57696
|
+
parameters,
|
|
57697
|
+
callback as BodyResponseCallback<unknown>
|
|
57698
|
+
);
|
|
57699
|
+
} else {
|
|
57700
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1UserStore>(
|
|
57701
|
+
parameters
|
|
57702
|
+
);
|
|
57703
|
+
}
|
|
57704
|
+
}
|
|
57705
|
+
|
|
57706
|
+
/**
|
|
57707
|
+
* Updates the User Store.
|
|
57708
|
+
* @example
|
|
57709
|
+
* ```js
|
|
57710
|
+
* // Before running the sample:
|
|
57711
|
+
* // - Enable the API at:
|
|
57712
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
57713
|
+
* // - Login into gcloud by running:
|
|
57714
|
+
* // ```sh
|
|
57715
|
+
* // $ gcloud auth application-default login
|
|
57716
|
+
* // ```
|
|
57717
|
+
* // - Install the npm module by running:
|
|
57718
|
+
* // ```sh
|
|
57719
|
+
* // $ npm install googleapis
|
|
57720
|
+
* // ```
|
|
57721
|
+
*
|
|
57722
|
+
* const {google} = require('googleapis');
|
|
57723
|
+
* const discoveryengine = google.discoveryengine('v1');
|
|
57724
|
+
*
|
|
57725
|
+
* async function main() {
|
|
57726
|
+
* const auth = new google.auth.GoogleAuth({
|
|
57727
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
57728
|
+
* scopes: [
|
|
57729
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
57730
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
57731
|
+
* ],
|
|
57732
|
+
* });
|
|
57733
|
+
*
|
|
57734
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
57735
|
+
* const authClient = await auth.getClient();
|
|
57736
|
+
* google.options({auth: authClient});
|
|
57737
|
+
*
|
|
57738
|
+
* // Do the magic
|
|
57739
|
+
* const res = await discoveryengine.projects.locations.userStores.patch({
|
|
57740
|
+
* // Immutable. The full resource name of the User Store, in the format of `projects/{project\}/locations/{location\}/userStores/{user_store\}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.
|
|
57741
|
+
* name: 'projects/my-project/locations/my-location/userStores/my-userStore',
|
|
57742
|
+
* // Optional. The list of fields to update.
|
|
57743
|
+
* updateMask: 'placeholder-value',
|
|
57744
|
+
*
|
|
57745
|
+
* // Request body metadata
|
|
57746
|
+
* requestBody: {
|
|
57747
|
+
* // request body parameters
|
|
57748
|
+
* // {
|
|
57749
|
+
* // "defaultLicenseConfig": "my_defaultLicenseConfig",
|
|
57750
|
+
* // "displayName": "my_displayName",
|
|
57751
|
+
* // "enableExpiredLicenseAutoUpdate": false,
|
|
57752
|
+
* // "enableLicenseAutoRegister": false,
|
|
57753
|
+
* // "name": "my_name"
|
|
57754
|
+
* // }
|
|
57755
|
+
* },
|
|
57756
|
+
* });
|
|
57757
|
+
* console.log(res.data);
|
|
57758
|
+
*
|
|
57759
|
+
* // Example response
|
|
57760
|
+
* // {
|
|
57761
|
+
* // "defaultLicenseConfig": "my_defaultLicenseConfig",
|
|
57762
|
+
* // "displayName": "my_displayName",
|
|
57763
|
+
* // "enableExpiredLicenseAutoUpdate": false,
|
|
57764
|
+
* // "enableLicenseAutoRegister": false,
|
|
57765
|
+
* // "name": "my_name"
|
|
57766
|
+
* // }
|
|
57767
|
+
* }
|
|
57768
|
+
*
|
|
57769
|
+
* main().catch(e => {
|
|
57770
|
+
* console.error(e);
|
|
57771
|
+
* throw e;
|
|
57772
|
+
* });
|
|
57773
|
+
*
|
|
57774
|
+
* ```
|
|
57775
|
+
*
|
|
57776
|
+
* @param params - Parameters for request
|
|
57777
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
57778
|
+
* @param callback - Optional callback that handles the response.
|
|
57779
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
57780
|
+
*/
|
|
57781
|
+
patch(
|
|
57782
|
+
params: Params$Resource$Projects$Locations$Userstores$Patch,
|
|
57783
|
+
options: StreamMethodOptions
|
|
57784
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
57785
|
+
patch(
|
|
57786
|
+
params?: Params$Resource$Projects$Locations$Userstores$Patch,
|
|
57787
|
+
options?: MethodOptions
|
|
57788
|
+
): Promise<
|
|
57789
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57790
|
+
>;
|
|
57791
|
+
patch(
|
|
57792
|
+
params: Params$Resource$Projects$Locations$Userstores$Patch,
|
|
57793
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
57794
|
+
callback: BodyResponseCallback<Readable>
|
|
57795
|
+
): void;
|
|
57796
|
+
patch(
|
|
57797
|
+
params: Params$Resource$Projects$Locations$Userstores$Patch,
|
|
57798
|
+
options:
|
|
57799
|
+
| MethodOptions
|
|
57800
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>,
|
|
57801
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57802
|
+
): void;
|
|
57803
|
+
patch(
|
|
57804
|
+
params: Params$Resource$Projects$Locations$Userstores$Patch,
|
|
57805
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57806
|
+
): void;
|
|
57807
|
+
patch(
|
|
57808
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57809
|
+
): void;
|
|
57810
|
+
patch(
|
|
57811
|
+
paramsOrCallback?:
|
|
57812
|
+
| Params$Resource$Projects$Locations$Userstores$Patch
|
|
57813
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57814
|
+
| BodyResponseCallback<Readable>,
|
|
57815
|
+
optionsOrCallback?:
|
|
57816
|
+
| MethodOptions
|
|
57817
|
+
| StreamMethodOptions
|
|
57818
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57819
|
+
| BodyResponseCallback<Readable>,
|
|
57820
|
+
callback?:
|
|
57821
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57822
|
+
| BodyResponseCallback<Readable>
|
|
57823
|
+
):
|
|
57824
|
+
| void
|
|
57825
|
+
| Promise<
|
|
57826
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1UserStore>
|
|
57827
|
+
>
|
|
57828
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
57829
|
+
let params = (paramsOrCallback ||
|
|
57830
|
+
{}) as Params$Resource$Projects$Locations$Userstores$Patch;
|
|
57831
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
57832
|
+
|
|
57833
|
+
if (typeof paramsOrCallback === 'function') {
|
|
57834
|
+
callback = paramsOrCallback;
|
|
57835
|
+
params = {} as Params$Resource$Projects$Locations$Userstores$Patch;
|
|
57836
|
+
options = {};
|
|
57837
|
+
}
|
|
57838
|
+
|
|
57839
|
+
if (typeof optionsOrCallback === 'function') {
|
|
57840
|
+
callback = optionsOrCallback;
|
|
57841
|
+
options = {};
|
|
57842
|
+
}
|
|
57843
|
+
|
|
57844
|
+
const rootUrl =
|
|
57845
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
57846
|
+
const parameters = {
|
|
57847
|
+
options: Object.assign(
|
|
57848
|
+
{
|
|
57849
|
+
url: (rootUrl + '/v1/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
57850
|
+
method: 'PATCH',
|
|
57851
|
+
apiVersion: '',
|
|
57852
|
+
},
|
|
57853
|
+
options
|
|
57854
|
+
),
|
|
57855
|
+
params,
|
|
57856
|
+
requiredParams: ['name'],
|
|
57857
|
+
pathParams: ['name'],
|
|
57858
|
+
context: this.context,
|
|
57859
|
+
};
|
|
57860
|
+
if (callback) {
|
|
57861
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1UserStore>(
|
|
57862
|
+
parameters,
|
|
57863
|
+
callback as BodyResponseCallback<unknown>
|
|
57864
|
+
);
|
|
57865
|
+
} else {
|
|
57866
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1UserStore>(
|
|
57867
|
+
parameters
|
|
57868
|
+
);
|
|
57869
|
+
}
|
|
57870
|
+
}
|
|
55996
57871
|
}
|
|
55997
57872
|
|
|
55998
57873
|
export interface Params$Resource$Projects$Locations$Userstores$Batchupdateuserlicenses
|
|
@@ -56007,6 +57882,52 @@ export namespace discoveryengine_v1 {
|
|
|
56007
57882
|
*/
|
|
56008
57883
|
requestBody?: Schema$GoogleCloudDiscoveryengineV1BatchUpdateUserLicensesRequest;
|
|
56009
57884
|
}
|
|
57885
|
+
export interface Params$Resource$Projects$Locations$Userstores$Create
|
|
57886
|
+
extends StandardParameters {
|
|
57887
|
+
/**
|
|
57888
|
+
* Required. The parent collection resource name, such as `projects/{project\}/locations/{location\}`.
|
|
57889
|
+
*/
|
|
57890
|
+
parent?: string;
|
|
57891
|
+
/**
|
|
57892
|
+
* Required. The ID of the User Store to create. The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 63 characters.
|
|
57893
|
+
*/
|
|
57894
|
+
userStoreId?: string;
|
|
57895
|
+
|
|
57896
|
+
/**
|
|
57897
|
+
* Request body metadata
|
|
57898
|
+
*/
|
|
57899
|
+
requestBody?: Schema$GoogleCloudDiscoveryengineV1UserStore;
|
|
57900
|
+
}
|
|
57901
|
+
export interface Params$Resource$Projects$Locations$Userstores$Delete
|
|
57902
|
+
extends StandardParameters {
|
|
57903
|
+
/**
|
|
57904
|
+
* Required. The name of the User Store to delete. Format: `projects/{project\}/locations/{location\}/userStores/{user_store_id\}`
|
|
57905
|
+
*/
|
|
57906
|
+
name?: string;
|
|
57907
|
+
}
|
|
57908
|
+
export interface Params$Resource$Projects$Locations$Userstores$Get
|
|
57909
|
+
extends StandardParameters {
|
|
57910
|
+
/**
|
|
57911
|
+
* Required. The name of the User Store to get. Format: `projects/{project\}/locations/{location\}/userStores/{user_store_id\}`
|
|
57912
|
+
*/
|
|
57913
|
+
name?: string;
|
|
57914
|
+
}
|
|
57915
|
+
export interface Params$Resource$Projects$Locations$Userstores$Patch
|
|
57916
|
+
extends StandardParameters {
|
|
57917
|
+
/**
|
|
57918
|
+
* Immutable. The full resource name of the User Store, in the format of `projects/{project\}/locations/{location\}/userStores/{user_store\}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.
|
|
57919
|
+
*/
|
|
57920
|
+
name?: string;
|
|
57921
|
+
/**
|
|
57922
|
+
* Optional. The list of fields to update.
|
|
57923
|
+
*/
|
|
57924
|
+
updateMask?: string;
|
|
57925
|
+
|
|
57926
|
+
/**
|
|
57927
|
+
* Request body metadata
|
|
57928
|
+
*/
|
|
57929
|
+
requestBody?: Schema$GoogleCloudDiscoveryengineV1UserStore;
|
|
57930
|
+
}
|
|
56010
57931
|
|
|
56011
57932
|
export class Resource$Projects$Locations$Userstores$Userlicenses {
|
|
56012
57933
|
context: APIRequestContext;
|