@googleapis/discoveryengine 32.0.0 → 33.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 +35 -0
- package/build/tsconfig.tsbuildinfo +1 -1
- package/build/v1.d.ts +119 -5
- package/build/v1.js.map +1 -1
- package/build/v1alpha.d.ts +725 -39
- package/build/v1alpha.js +231 -0
- package/build/v1alpha.js.map +1 -1
- package/build/v1beta.d.ts +64 -4
- package/build/v1beta.js.map +1 -1
- package/package.json +1 -1
- package/v1.ts +115 -5
- package/v1alpha.ts +1709 -448
- package/v1beta.ts +60 -4
package/v1alpha.ts
CHANGED
|
@@ -2428,6 +2428,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
2428
2428
|
* Final verdict of the customer policy enforcement. If only one policy blocked the processing, the verdict is BLOCK.
|
|
2429
2429
|
*/
|
|
2430
2430
|
verdict?: string | null;
|
|
2431
|
+
/**
|
|
2432
|
+
* Output only. The source of the violation.
|
|
2433
|
+
*/
|
|
2434
|
+
violationSource?: string | null;
|
|
2431
2435
|
}
|
|
2432
2436
|
/**
|
|
2433
2437
|
* Customer policy enforcement result for the banned phrase policy.
|
|
@@ -2732,6 +2736,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
2732
2736
|
* Referenced content and related document metadata.
|
|
2733
2737
|
*/
|
|
2734
2738
|
export interface Schema$GoogleCloudDiscoveryengineV1alphaAssistantGroundedContentTextGroundingMetadataReference {
|
|
2739
|
+
/**
|
|
2740
|
+
* Output only. Generic structured chunk metadata from upstream data source connectors.
|
|
2741
|
+
*/
|
|
2742
|
+
chunkMetadata?: {[key: string]: any} | null;
|
|
2735
2743
|
/**
|
|
2736
2744
|
* Chunk of code snippet from the referenced document.
|
|
2737
2745
|
*/
|
|
@@ -3857,7 +3865,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
3857
3865
|
*/
|
|
3858
3866
|
numUniqueUsersThreshold?: number | null;
|
|
3859
3867
|
/**
|
|
3860
|
-
* This field is only meaningful for suggestions generated from user events or search history. If a query shows up less than this threshold, it may indicate that the query is rarely searched and thus will not be generated as a suggestion. This is field can be helpful for preventing PII queries becoming suggestions, as those queries are usually uniquely searched. If not set, the default value is
|
|
3868
|
+
* This field is only meaningful for suggestions generated from user events or search history. If a query shows up less than this threshold, it may indicate that the query is rarely searched and thus will not be generated as a suggestion. This is field can be helpful for preventing PII queries becoming suggestions, as those queries are usually uniquely searched. If not set, the default value is 8 used in the generation pipeline.
|
|
3861
3869
|
*/
|
|
3862
3870
|
queryFrequencyThreshold?: number | null;
|
|
3863
3871
|
/**
|
|
@@ -5727,7 +5735,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
5727
5735
|
*/
|
|
5728
5736
|
displayName?: string | null;
|
|
5729
5737
|
/**
|
|
5730
|
-
* Optional. Feature config for the engine to opt in or opt out of features. Supported keys: * `*`: all features, if it's present, all other feature state settings are ignored. * `agent-gallery` * `no-code-agent-builder` * `prompt-gallery` * `model-selector` * `notebook-lm` * `people-search` * `people-search-org-chart` * `bi-directional-audio` * `feedback` * `session-sharing` * `personalization-memory` * `personalization-suggested-highlights` * `mobile-app-access` * `disable-agent-sharing` * `disable-image-generation` * `disable-video-generation` * `disable-onedrive-upload` * `disable-talk-to-content` * `disable-google-drive-upload` * `disable-welcome-emails` * `disable-canvas` * `canvas-workspace` * `skills` * `skill-sharing` * `skill-sharing-without-admin-approval` * `disable-projects` * `sobi` * `enable-end-user-sharing-with-groups` * `single-agent-orchestration` * `multi-agent-orchestration` * `cross-product-intelligence` * `workflow-agents` * `in-app-notifications`
|
|
5738
|
+
* Optional. Feature config for the engine to opt in or opt out of features. Supported keys: * `*`: all features, if it's present, all other feature state settings are ignored. * `agent-gallery` * `no-code-agent-builder` * `prompt-gallery` * `model-selector` * `notebook-lm` * `people-search` * `people-search-org-chart` * `bi-directional-audio` * `speech-to-text` * `feedback` * `session-sharing` * `personalization-memory` * `personalization-suggested-highlights` * `mobile-app-access` * `disable-agent-sharing` * `disable-image-generation` * `disable-video-generation` * `disable-onedrive-upload` * `disable-talk-to-content` * `disable-google-drive-upload` * `disable-welcome-emails` * `disable-canvas` * `canvas-workspace` * `skills` * `skill-sharing` * `skill-sharing-without-admin-approval` * `disable-projects` * `sobi` * `enable-end-user-sharing-with-groups` * `single-agent-orchestration` * `multi-agent-orchestration` * `cross-product-intelligence` * `workflow-agents` * `in-app-notifications`
|
|
5731
5739
|
*/
|
|
5732
5740
|
features?: {[key: string]: string} | null;
|
|
5733
5741
|
/**
|
|
@@ -7221,6 +7229,40 @@ export namespace discoveryengine_v1alpha {
|
|
|
7221
7229
|
*/
|
|
7222
7230
|
minimum?: number | null;
|
|
7223
7231
|
}
|
|
7232
|
+
/**
|
|
7233
|
+
* Request message for making a call to an MCP connector. It carries the connector name, the method to invoke, and optional parameters.
|
|
7234
|
+
*/
|
|
7235
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpRequest {
|
|
7236
|
+
/**
|
|
7237
|
+
* Optional. The engine resource name (e.g. "projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}"). Used as the search engine id when invoking tool registry tools that issue Discovery Search Service requests.
|
|
7238
|
+
*/
|
|
7239
|
+
engine?: string | null;
|
|
7240
|
+
/**
|
|
7241
|
+
* Required. The method to invoke (e.g. "tools/list", "tools/call", "resources/read", "prompts/get", etc.).
|
|
7242
|
+
*/
|
|
7243
|
+
method?: string | null;
|
|
7244
|
+
/**
|
|
7245
|
+
* Optional. Arbitrary structured parameters for the method. Using google.protobuf.Struct keeps the payload schema-flexible, matching JSON-RPC's free-form `params` field.
|
|
7246
|
+
*/
|
|
7247
|
+
params?: {[key: string]: any} | null;
|
|
7248
|
+
/**
|
|
7249
|
+
* Optional. The tool spec version to resolve the connector's tool surface against. This corresponds to the connector's BAP tool spec file name (e.g. "v2", "v5.2"). When unset, the server uses its default (latest) tool spec for the connector. Applies to all methods (e.g. "tools/list" and "tools/call").
|
|
7250
|
+
*/
|
|
7251
|
+
toolSpecVersion?: string | null;
|
|
7252
|
+
}
|
|
7253
|
+
/**
|
|
7254
|
+
* Response message returning the result of an MCP connector invocation. It contains either a successful result payload or error details.
|
|
7255
|
+
*/
|
|
7256
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse {
|
|
7257
|
+
/**
|
|
7258
|
+
* Error details when the call fails.
|
|
7259
|
+
*/
|
|
7260
|
+
error?: Schema$GoogleCloudDiscoveryengineV1alphaMcpError;
|
|
7261
|
+
/**
|
|
7262
|
+
* Successful result — arbitrary structured data.
|
|
7263
|
+
*/
|
|
7264
|
+
result?: any | null;
|
|
7265
|
+
}
|
|
7224
7266
|
/**
|
|
7225
7267
|
* Language info for DataStore.
|
|
7226
7268
|
*/
|
|
@@ -7762,6 +7804,23 @@ export namespace discoveryengine_v1alpha {
|
|
|
7762
7804
|
* Stores the definition of a Google managed agent.
|
|
7763
7805
|
*/
|
|
7764
7806
|
export interface Schema$GoogleCloudDiscoveryengineV1alphaManagedAgentDefinition {}
|
|
7807
|
+
/**
|
|
7808
|
+
* McpError represents error details when an MCP call fails. This structure follows the JSON-RPC 2.0 error object shape.
|
|
7809
|
+
*/
|
|
7810
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaMcpError {
|
|
7811
|
+
/**
|
|
7812
|
+
* Numeric error code.
|
|
7813
|
+
*/
|
|
7814
|
+
code?: number | null;
|
|
7815
|
+
/**
|
|
7816
|
+
* Optional structured data with additional error context.
|
|
7817
|
+
*/
|
|
7818
|
+
data?: any | null;
|
|
7819
|
+
/**
|
|
7820
|
+
* Short, human-readable description of the error.
|
|
7821
|
+
*/
|
|
7822
|
+
message?: string | null;
|
|
7823
|
+
}
|
|
7765
7824
|
/**
|
|
7766
7825
|
* Media-specific user event information.
|
|
7767
7826
|
*/
|
|
@@ -9987,7 +10046,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
9987
10046
|
*/
|
|
9988
10047
|
export interface Schema$GoogleCloudDiscoveryengineV1alphaSearchResponse {
|
|
9989
10048
|
/**
|
|
9990
|
-
* Controls applied as part of the Control service.
|
|
10049
|
+
* Optional. Controls applied as part of the Control service.
|
|
9991
10050
|
*/
|
|
9992
10051
|
appliedControls?: string[] | null;
|
|
9993
10052
|
/**
|
|
@@ -10999,6 +11058,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
10999
11058
|
* Optional. Specification of actions for the request.
|
|
11000
11059
|
*/
|
|
11001
11060
|
actionSpec?: Schema$GoogleCloudDiscoveryengineV1alphaStreamAssistRequestActionSpec;
|
|
11061
|
+
/**
|
|
11062
|
+
* Optional. Specification of agents that are used to serve the request.
|
|
11063
|
+
*/
|
|
11064
|
+
agentsSpec?: Schema$GoogleCloudDiscoveryengineV1alphaStreamAssistRequestAgentsSpec;
|
|
11002
11065
|
/**
|
|
11003
11066
|
* Optional. Specification of the generation configuration for the request.
|
|
11004
11067
|
*/
|
|
@@ -11029,6 +11092,24 @@ export namespace discoveryengine_v1alpha {
|
|
|
11029
11092
|
*/
|
|
11030
11093
|
actionDisabled?: boolean | null;
|
|
11031
11094
|
}
|
|
11095
|
+
/**
|
|
11096
|
+
* Specification of agents that are used to serve the request.
|
|
11097
|
+
*/
|
|
11098
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaStreamAssistRequestAgentsSpec {
|
|
11099
|
+
/**
|
|
11100
|
+
* Optional. Specification of agents that are used to serve the request.
|
|
11101
|
+
*/
|
|
11102
|
+
agentSpecs?: Schema$GoogleCloudDiscoveryengineV1alphaStreamAssistRequestAgentsSpecAgentSpec[];
|
|
11103
|
+
}
|
|
11104
|
+
/**
|
|
11105
|
+
* Specification of an agent.
|
|
11106
|
+
*/
|
|
11107
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaStreamAssistRequestAgentsSpecAgentSpec {
|
|
11108
|
+
/**
|
|
11109
|
+
* Required. ID to identify the agent resource serving the request. This field must conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) with a length limit of 63 characters.
|
|
11110
|
+
*/
|
|
11111
|
+
agentId?: string | null;
|
|
11112
|
+
}
|
|
11032
11113
|
/**
|
|
11033
11114
|
* Assistant generation specification for the request. This allows to override the default generation configuration at the engine level.
|
|
11034
11115
|
*/
|
|
@@ -11955,7 +12036,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
11955
12036
|
*/
|
|
11956
12037
|
id?: string | null;
|
|
11957
12038
|
/**
|
|
11958
|
-
* Output only. Whether this is a first-party (Google-owned) connector, as opposed to a third-party connector. Used by the frontend to group 1P vs 3P connectors.
|
|
12039
|
+
* Output only. Whether this is a first-party (Google-owned) connector, as opposed to a third-party connector. Used by the frontend to group 1P vs 3P connectors.
|
|
11959
12040
|
*/
|
|
11960
12041
|
isFirstParty?: boolean | null;
|
|
11961
12042
|
/**
|
|
@@ -12199,7 +12280,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
12199
12280
|
*/
|
|
12200
12281
|
enableVisualContentSummary?: boolean | null;
|
|
12201
12282
|
/**
|
|
12202
|
-
* Output only. Feature config for the engine to opt in or opt out of features. Supported keys: * `agent-gallery` * `no-code-agent-builder` * `prompt-gallery` * `model-selector` * `notebook-lm` * `people-search` * `people-search-org-chart` * `bi-directional-audio` * `feedback` * `session-sharing` * `personalization-memory` * `personalization-suggested-highlights` * `mobile-app-access` * `disable-agent-sharing` * `disable-image-generation` * `disable-video-generation` * `disable-onedrive-upload` * `disable-talk-to-content` * `disable-google-drive-upload` * `disable-welcome-emails` * `disable-canvas` * `canvas-workspace` * `skills` * `skill-sharing` * `skill-sharing-without-admin-approval` * `disable-projects` * `sobi` * `enable-end-user-sharing-with-groups` * `single-agent-orchestration` * `multi-agent-orchestration` * `cross-product-intelligence` * `workflow-agents` * `in-app-notifications`
|
|
12283
|
+
* Output only. Feature config for the engine to opt in or opt out of features. Supported keys: * `agent-gallery` * `no-code-agent-builder` * `prompt-gallery` * `model-selector` * `notebook-lm` * `people-search` * `people-search-org-chart` * `bi-directional-audio` * `speech-to-text` * `feedback` * `session-sharing` * `personalization-memory` * `personalization-suggested-highlights` * `mobile-app-access` * `disable-agent-sharing` * `disable-image-generation` * `disable-video-generation` * `disable-onedrive-upload` * `disable-talk-to-content` * `disable-google-drive-upload` * `disable-welcome-emails` * `disable-canvas` * `canvas-workspace` * `skills` * `skill-sharing` * `skill-sharing-without-admin-approval` * `disable-projects` * `sobi` * `enable-end-user-sharing-with-groups` * `single-agent-orchestration` * `multi-agent-orchestration` * `cross-product-intelligence` * `workflow-agents` * `in-app-notifications`
|
|
12203
12284
|
*/
|
|
12204
12285
|
features?: {[key: string]: string} | null;
|
|
12205
12286
|
/**
|
|
@@ -12321,10 +12402,18 @@ export namespace discoveryengine_v1alpha {
|
|
|
12321
12402
|
* Output only. Whether the model is currently in preview. Clients should surface this via a "Preview" badge in the selector UI.
|
|
12322
12403
|
*/
|
|
12323
12404
|
isPreview?: boolean | null;
|
|
12405
|
+
/**
|
|
12406
|
+
* Output only. Short label shown in the compact selector bar chip (e.g. `3.x Flash`) as opposed to the full `display_name` (`Gemini 3.x Flash`). Falls back to `display_name` when the backend registry does not specify a distinct short label.
|
|
12407
|
+
*/
|
|
12408
|
+
label?: string | null;
|
|
12324
12409
|
/**
|
|
12325
12410
|
* Output only. Unique identifier of the model (e.g. `gemini-2.5-flash`, `gemini-3.1-pro-preview`). This is the same identifier that clients pass back to the assistant service to select this model. Virtual / "pseudo" models (e.g. `gemini-fast`) are also valid values here; they are resolved to the underlying concrete model on the backend.
|
|
12326
12411
|
*/
|
|
12327
12412
|
modelId?: string | null;
|
|
12413
|
+
/**
|
|
12414
|
+
* Output only. Whether this model should be promoted in the GE chat homepage banner.
|
|
12415
|
+
*/
|
|
12416
|
+
promoted?: boolean | null;
|
|
12328
12417
|
}
|
|
12329
12418
|
/**
|
|
12330
12419
|
* Admin-surface metadata. Populated only when the request originates from the Cloud Console admin "Feature Control" page; left unset for end-user surfaces (Web, Mobile). Lets the admin page render its toggle table directly from the backend instead of a hardcoded client-side registry.
|
|
@@ -13623,7 +13712,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
13623
13712
|
*/
|
|
13624
13713
|
displayName?: string | null;
|
|
13625
13714
|
/**
|
|
13626
|
-
* Optional. Feature config for the engine to opt in or opt out of features. Supported keys: * `*`: all features, if it's present, all other feature state settings are ignored. * `agent-gallery` * `no-code-agent-builder` * `prompt-gallery` * `model-selector` * `notebook-lm` * `people-search` * `people-search-org-chart` * `bi-directional-audio` * `feedback` * `session-sharing` * `personalization-memory` * `personalization-suggested-highlights` * `mobile-app-access` * `disable-agent-sharing` * `disable-image-generation` * `disable-video-generation` * `disable-onedrive-upload` * `disable-talk-to-content` * `disable-google-drive-upload` * `disable-welcome-emails` * `disable-canvas` * `canvas-workspace` * `skills` * `skill-sharing` * `skill-sharing-without-admin-approval` * `disable-projects` * `sobi` * `enable-end-user-sharing-with-groups` * `single-agent-orchestration` * `multi-agent-orchestration` * `cross-product-intelligence` * `workflow-agents` * `in-app-notifications`
|
|
13715
|
+
* Optional. Feature config for the engine to opt in or opt out of features. Supported keys: * `*`: all features, if it's present, all other feature state settings are ignored. * `agent-gallery` * `no-code-agent-builder` * `prompt-gallery` * `model-selector` * `notebook-lm` * `people-search` * `people-search-org-chart` * `bi-directional-audio` * `speech-to-text` * `feedback` * `session-sharing` * `personalization-memory` * `personalization-suggested-highlights` * `mobile-app-access` * `disable-agent-sharing` * `disable-image-generation` * `disable-video-generation` * `disable-onedrive-upload` * `disable-talk-to-content` * `disable-google-drive-upload` * `disable-welcome-emails` * `disable-canvas` * `canvas-workspace` * `skills` * `skill-sharing` * `skill-sharing-without-admin-approval` * `disable-projects` * `sobi` * `enable-end-user-sharing-with-groups` * `single-agent-orchestration` * `multi-agent-orchestration` * `cross-product-intelligence` * `workflow-agents` * `in-app-notifications`
|
|
13627
13716
|
*/
|
|
13628
13717
|
features?: {[key: string]: string} | null;
|
|
13629
13718
|
/**
|
|
@@ -16915,7 +17004,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
16915
17004
|
*/
|
|
16916
17005
|
displayName?: string | null;
|
|
16917
17006
|
/**
|
|
16918
|
-
* Optional. Feature config for the engine to opt in or opt out of features. Supported keys: * `*`: all features, if it's present, all other feature state settings are ignored. * `agent-gallery` * `no-code-agent-builder` * `prompt-gallery` * `model-selector` * `notebook-lm` * `people-search` * `people-search-org-chart` * `bi-directional-audio` * `feedback` * `session-sharing` * `personalization-memory` * `personalization-suggested-highlights` * `mobile-app-access` * `disable-agent-sharing` * `disable-image-generation` * `disable-video-generation` * `disable-onedrive-upload` * `disable-talk-to-content` * `disable-google-drive-upload` * `disable-welcome-emails` * `disable-canvas` * `canvas-workspace` * `skills` * `skill-sharing` * `skill-sharing-without-admin-approval` * `disable-projects` * `sobi` * `enable-end-user-sharing-with-groups` * `single-agent-orchestration` * `multi-agent-orchestration` * `cross-product-intelligence` * `workflow-agents` * `in-app-notifications`
|
|
17007
|
+
* Optional. Feature config for the engine to opt in or opt out of features. Supported keys: * `*`: all features, if it's present, all other feature state settings are ignored. * `agent-gallery` * `no-code-agent-builder` * `prompt-gallery` * `model-selector` * `notebook-lm` * `people-search` * `people-search-org-chart` * `bi-directional-audio` * `speech-to-text` * `feedback` * `session-sharing` * `personalization-memory` * `personalization-suggested-highlights` * `mobile-app-access` * `disable-agent-sharing` * `disable-image-generation` * `disable-video-generation` * `disable-onedrive-upload` * `disable-talk-to-content` * `disable-google-drive-upload` * `disable-welcome-emails` * `disable-canvas` * `canvas-workspace` * `skills` * `skill-sharing` * `skill-sharing-without-admin-approval` * `disable-projects` * `sobi` * `enable-end-user-sharing-with-groups` * `single-agent-orchestration` * `multi-agent-orchestration` * `cross-product-intelligence` * `workflow-agents` * `in-app-notifications`
|
|
16919
17008
|
*/
|
|
16920
17009
|
features?: {[key: string]: string} | null;
|
|
16921
17010
|
/**
|
|
@@ -25023,6 +25112,158 @@ export namespace discoveryengine_v1alpha {
|
|
|
25023
25112
|
}
|
|
25024
25113
|
}
|
|
25025
25114
|
|
|
25115
|
+
/**
|
|
25116
|
+
* Gets the IAM access control policy for a Collection. A `NOT_FOUND` error is returned if the resource does not exist. An empty policy is returned if the resource exists but does not have a policy set on it.
|
|
25117
|
+
* @example
|
|
25118
|
+
* ```js
|
|
25119
|
+
* // Before running the sample:
|
|
25120
|
+
* // - Enable the API at:
|
|
25121
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
25122
|
+
* // - Login into gcloud by running:
|
|
25123
|
+
* // ```sh
|
|
25124
|
+
* // $ gcloud auth application-default login
|
|
25125
|
+
* // ```
|
|
25126
|
+
* // - Install the npm module by running:
|
|
25127
|
+
* // ```sh
|
|
25128
|
+
* // $ npm install googleapis
|
|
25129
|
+
* // ```
|
|
25130
|
+
*
|
|
25131
|
+
* const {google} = require('googleapis');
|
|
25132
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
25133
|
+
*
|
|
25134
|
+
* async function main() {
|
|
25135
|
+
* const auth = new google.auth.GoogleAuth({
|
|
25136
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
25137
|
+
* scopes: [
|
|
25138
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
25139
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
25140
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
25141
|
+
* ],
|
|
25142
|
+
* });
|
|
25143
|
+
*
|
|
25144
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
25145
|
+
* const authClient = await auth.getClient();
|
|
25146
|
+
* google.options({auth: authClient});
|
|
25147
|
+
*
|
|
25148
|
+
* // Do the magic
|
|
25149
|
+
* const res = await discoveryengine.projects.locations.collections.getIamPolicy(
|
|
25150
|
+
* {
|
|
25151
|
+
* // Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
|
|
25152
|
+
* 'options.requestedPolicyVersion': 'placeholder-value',
|
|
25153
|
+
* // REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
25154
|
+
* resource:
|
|
25155
|
+
* 'projects/my-project/locations/my-location/collections/my-collection',
|
|
25156
|
+
* },
|
|
25157
|
+
* );
|
|
25158
|
+
* console.log(res.data);
|
|
25159
|
+
*
|
|
25160
|
+
* // Example response
|
|
25161
|
+
* // {
|
|
25162
|
+
* // "bindings": [],
|
|
25163
|
+
* // "etag": "my_etag",
|
|
25164
|
+
* // "version": 0
|
|
25165
|
+
* // }
|
|
25166
|
+
* }
|
|
25167
|
+
*
|
|
25168
|
+
* main().catch(e => {
|
|
25169
|
+
* console.error(e);
|
|
25170
|
+
* throw e;
|
|
25171
|
+
* });
|
|
25172
|
+
*
|
|
25173
|
+
* ```
|
|
25174
|
+
*
|
|
25175
|
+
* @param params - Parameters for request
|
|
25176
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
25177
|
+
* @param callback - Optional callback that handles the response.
|
|
25178
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
25179
|
+
*/
|
|
25180
|
+
getIamPolicy(
|
|
25181
|
+
params: Params$Resource$Projects$Locations$Collections$Getiampolicy,
|
|
25182
|
+
options: StreamMethodOptions
|
|
25183
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
25184
|
+
getIamPolicy(
|
|
25185
|
+
params?: Params$Resource$Projects$Locations$Collections$Getiampolicy,
|
|
25186
|
+
options?: MethodOptions
|
|
25187
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>;
|
|
25188
|
+
getIamPolicy(
|
|
25189
|
+
params: Params$Resource$Projects$Locations$Collections$Getiampolicy,
|
|
25190
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
25191
|
+
callback: BodyResponseCallback<Readable>
|
|
25192
|
+
): void;
|
|
25193
|
+
getIamPolicy(
|
|
25194
|
+
params: Params$Resource$Projects$Locations$Collections$Getiampolicy,
|
|
25195
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleIamV1Policy>,
|
|
25196
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25197
|
+
): void;
|
|
25198
|
+
getIamPolicy(
|
|
25199
|
+
params: Params$Resource$Projects$Locations$Collections$Getiampolicy,
|
|
25200
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25201
|
+
): void;
|
|
25202
|
+
getIamPolicy(
|
|
25203
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25204
|
+
): void;
|
|
25205
|
+
getIamPolicy(
|
|
25206
|
+
paramsOrCallback?:
|
|
25207
|
+
| Params$Resource$Projects$Locations$Collections$Getiampolicy
|
|
25208
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25209
|
+
| BodyResponseCallback<Readable>,
|
|
25210
|
+
optionsOrCallback?:
|
|
25211
|
+
| MethodOptions
|
|
25212
|
+
| StreamMethodOptions
|
|
25213
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25214
|
+
| BodyResponseCallback<Readable>,
|
|
25215
|
+
callback?:
|
|
25216
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25217
|
+
| BodyResponseCallback<Readable>
|
|
25218
|
+
):
|
|
25219
|
+
| void
|
|
25220
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>
|
|
25221
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
25222
|
+
let params = (paramsOrCallback ||
|
|
25223
|
+
{}) as Params$Resource$Projects$Locations$Collections$Getiampolicy;
|
|
25224
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
25225
|
+
|
|
25226
|
+
if (typeof paramsOrCallback === 'function') {
|
|
25227
|
+
callback = paramsOrCallback;
|
|
25228
|
+
params =
|
|
25229
|
+
{} as Params$Resource$Projects$Locations$Collections$Getiampolicy;
|
|
25230
|
+
options = {};
|
|
25231
|
+
}
|
|
25232
|
+
|
|
25233
|
+
if (typeof optionsOrCallback === 'function') {
|
|
25234
|
+
callback = optionsOrCallback;
|
|
25235
|
+
options = {};
|
|
25236
|
+
}
|
|
25237
|
+
|
|
25238
|
+
const rootUrl =
|
|
25239
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
25240
|
+
const parameters = {
|
|
25241
|
+
options: Object.assign(
|
|
25242
|
+
{
|
|
25243
|
+
url: (rootUrl + '/v1alpha/{+resource}:getIamPolicy').replace(
|
|
25244
|
+
/([^:]\/)\/+/g,
|
|
25245
|
+
'$1'
|
|
25246
|
+
),
|
|
25247
|
+
method: 'GET',
|
|
25248
|
+
apiVersion: '',
|
|
25249
|
+
},
|
|
25250
|
+
options
|
|
25251
|
+
),
|
|
25252
|
+
params,
|
|
25253
|
+
requiredParams: ['resource'],
|
|
25254
|
+
pathParams: ['resource'],
|
|
25255
|
+
context: this.context,
|
|
25256
|
+
};
|
|
25257
|
+
if (callback) {
|
|
25258
|
+
createAPIRequest<Schema$GoogleIamV1Policy>(
|
|
25259
|
+
parameters,
|
|
25260
|
+
callback as BodyResponseCallback<unknown>
|
|
25261
|
+
);
|
|
25262
|
+
} else {
|
|
25263
|
+
return createAPIRequest<Schema$GoogleIamV1Policy>(parameters);
|
|
25264
|
+
}
|
|
25265
|
+
}
|
|
25266
|
+
|
|
25026
25267
|
/**
|
|
25027
25268
|
* Gets a list of Collections.
|
|
25028
25269
|
* @example
|
|
@@ -25341,6 +25582,164 @@ export namespace discoveryengine_v1alpha {
|
|
|
25341
25582
|
}
|
|
25342
25583
|
}
|
|
25343
25584
|
|
|
25585
|
+
/**
|
|
25586
|
+
* Sets the IAM access control policy for a Collection. A `NOT_FOUND` error is returned if the resource does not exist. **Important:** When setting a policy directly on a Collection resource, the only recommended roles in the bindings are: `roles/discoveryengine.admin` `roles/discoveryengine.agentspaceAdmin` `roles/discoveryengine.viewer` `roles/discoveryengine.agentspaceViewer` `roles/discoveryengine.user` `roles/discoveryengine.agentspaceUser` Attempting to grant any other role will result in a warning in logging.
|
|
25587
|
+
* @example
|
|
25588
|
+
* ```js
|
|
25589
|
+
* // Before running the sample:
|
|
25590
|
+
* // - Enable the API at:
|
|
25591
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
25592
|
+
* // - Login into gcloud by running:
|
|
25593
|
+
* // ```sh
|
|
25594
|
+
* // $ gcloud auth application-default login
|
|
25595
|
+
* // ```
|
|
25596
|
+
* // - Install the npm module by running:
|
|
25597
|
+
* // ```sh
|
|
25598
|
+
* // $ npm install googleapis
|
|
25599
|
+
* // ```
|
|
25600
|
+
*
|
|
25601
|
+
* const {google} = require('googleapis');
|
|
25602
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
25603
|
+
*
|
|
25604
|
+
* async function main() {
|
|
25605
|
+
* const auth = new google.auth.GoogleAuth({
|
|
25606
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
25607
|
+
* scopes: [
|
|
25608
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
25609
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
25610
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
25611
|
+
* ],
|
|
25612
|
+
* });
|
|
25613
|
+
*
|
|
25614
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
25615
|
+
* const authClient = await auth.getClient();
|
|
25616
|
+
* google.options({auth: authClient});
|
|
25617
|
+
*
|
|
25618
|
+
* // Do the magic
|
|
25619
|
+
* const res = await discoveryengine.projects.locations.collections.setIamPolicy(
|
|
25620
|
+
* {
|
|
25621
|
+
* // REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
25622
|
+
* resource:
|
|
25623
|
+
* 'projects/my-project/locations/my-location/collections/my-collection',
|
|
25624
|
+
*
|
|
25625
|
+
* // Request body metadata
|
|
25626
|
+
* requestBody: {
|
|
25627
|
+
* // request body parameters
|
|
25628
|
+
* // {
|
|
25629
|
+
* // "policy": {}
|
|
25630
|
+
* // }
|
|
25631
|
+
* },
|
|
25632
|
+
* },
|
|
25633
|
+
* );
|
|
25634
|
+
* console.log(res.data);
|
|
25635
|
+
*
|
|
25636
|
+
* // Example response
|
|
25637
|
+
* // {
|
|
25638
|
+
* // "bindings": [],
|
|
25639
|
+
* // "etag": "my_etag",
|
|
25640
|
+
* // "version": 0
|
|
25641
|
+
* // }
|
|
25642
|
+
* }
|
|
25643
|
+
*
|
|
25644
|
+
* main().catch(e => {
|
|
25645
|
+
* console.error(e);
|
|
25646
|
+
* throw e;
|
|
25647
|
+
* });
|
|
25648
|
+
*
|
|
25649
|
+
* ```
|
|
25650
|
+
*
|
|
25651
|
+
* @param params - Parameters for request
|
|
25652
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
25653
|
+
* @param callback - Optional callback that handles the response.
|
|
25654
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
25655
|
+
*/
|
|
25656
|
+
setIamPolicy(
|
|
25657
|
+
params: Params$Resource$Projects$Locations$Collections$Setiampolicy,
|
|
25658
|
+
options: StreamMethodOptions
|
|
25659
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
25660
|
+
setIamPolicy(
|
|
25661
|
+
params?: Params$Resource$Projects$Locations$Collections$Setiampolicy,
|
|
25662
|
+
options?: MethodOptions
|
|
25663
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>;
|
|
25664
|
+
setIamPolicy(
|
|
25665
|
+
params: Params$Resource$Projects$Locations$Collections$Setiampolicy,
|
|
25666
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
25667
|
+
callback: BodyResponseCallback<Readable>
|
|
25668
|
+
): void;
|
|
25669
|
+
setIamPolicy(
|
|
25670
|
+
params: Params$Resource$Projects$Locations$Collections$Setiampolicy,
|
|
25671
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleIamV1Policy>,
|
|
25672
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25673
|
+
): void;
|
|
25674
|
+
setIamPolicy(
|
|
25675
|
+
params: Params$Resource$Projects$Locations$Collections$Setiampolicy,
|
|
25676
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25677
|
+
): void;
|
|
25678
|
+
setIamPolicy(
|
|
25679
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25680
|
+
): void;
|
|
25681
|
+
setIamPolicy(
|
|
25682
|
+
paramsOrCallback?:
|
|
25683
|
+
| Params$Resource$Projects$Locations$Collections$Setiampolicy
|
|
25684
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25685
|
+
| BodyResponseCallback<Readable>,
|
|
25686
|
+
optionsOrCallback?:
|
|
25687
|
+
| MethodOptions
|
|
25688
|
+
| StreamMethodOptions
|
|
25689
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25690
|
+
| BodyResponseCallback<Readable>,
|
|
25691
|
+
callback?:
|
|
25692
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
25693
|
+
| BodyResponseCallback<Readable>
|
|
25694
|
+
):
|
|
25695
|
+
| void
|
|
25696
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>
|
|
25697
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
25698
|
+
let params = (paramsOrCallback ||
|
|
25699
|
+
{}) as Params$Resource$Projects$Locations$Collections$Setiampolicy;
|
|
25700
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
25701
|
+
|
|
25702
|
+
if (typeof paramsOrCallback === 'function') {
|
|
25703
|
+
callback = paramsOrCallback;
|
|
25704
|
+
params =
|
|
25705
|
+
{} as Params$Resource$Projects$Locations$Collections$Setiampolicy;
|
|
25706
|
+
options = {};
|
|
25707
|
+
}
|
|
25708
|
+
|
|
25709
|
+
if (typeof optionsOrCallback === 'function') {
|
|
25710
|
+
callback = optionsOrCallback;
|
|
25711
|
+
options = {};
|
|
25712
|
+
}
|
|
25713
|
+
|
|
25714
|
+
const rootUrl =
|
|
25715
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
25716
|
+
const parameters = {
|
|
25717
|
+
options: Object.assign(
|
|
25718
|
+
{
|
|
25719
|
+
url: (rootUrl + '/v1alpha/{+resource}:setIamPolicy').replace(
|
|
25720
|
+
/([^:]\/)\/+/g,
|
|
25721
|
+
'$1'
|
|
25722
|
+
),
|
|
25723
|
+
method: 'POST',
|
|
25724
|
+
apiVersion: '',
|
|
25725
|
+
},
|
|
25726
|
+
options
|
|
25727
|
+
),
|
|
25728
|
+
params,
|
|
25729
|
+
requiredParams: ['resource'],
|
|
25730
|
+
pathParams: ['resource'],
|
|
25731
|
+
context: this.context,
|
|
25732
|
+
};
|
|
25733
|
+
if (callback) {
|
|
25734
|
+
createAPIRequest<Schema$GoogleIamV1Policy>(
|
|
25735
|
+
parameters,
|
|
25736
|
+
callback as BodyResponseCallback<unknown>
|
|
25737
|
+
);
|
|
25738
|
+
} else {
|
|
25739
|
+
return createAPIRequest<Schema$GoogleIamV1Policy>(parameters);
|
|
25740
|
+
}
|
|
25741
|
+
}
|
|
25742
|
+
|
|
25344
25743
|
/**
|
|
25345
25744
|
* Updates a DataConnector.
|
|
25346
25745
|
* @example
|
|
@@ -25616,6 +26015,16 @@ export namespace discoveryengine_v1alpha {
|
|
|
25616
26015
|
*/
|
|
25617
26016
|
name?: string;
|
|
25618
26017
|
}
|
|
26018
|
+
export interface Params$Resource$Projects$Locations$Collections$Getiampolicy extends StandardParameters {
|
|
26019
|
+
/**
|
|
26020
|
+
* Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
|
|
26021
|
+
*/
|
|
26022
|
+
'options.requestedPolicyVersion'?: number;
|
|
26023
|
+
/**
|
|
26024
|
+
* REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
26025
|
+
*/
|
|
26026
|
+
resource?: string;
|
|
26027
|
+
}
|
|
25619
26028
|
export interface Params$Resource$Projects$Locations$Collections$List extends StandardParameters {
|
|
25620
26029
|
/**
|
|
25621
26030
|
* Filter returned collections by associated data connector data sources. For example: `filter = 'data_source:jira confluence'`. If the filter is empty, we return all collections under a project and location.
|
|
@@ -25649,6 +26058,17 @@ export namespace discoveryengine_v1alpha {
|
|
|
25649
26058
|
*/
|
|
25650
26059
|
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaCollection;
|
|
25651
26060
|
}
|
|
26061
|
+
export interface Params$Resource$Projects$Locations$Collections$Setiampolicy extends StandardParameters {
|
|
26062
|
+
/**
|
|
26063
|
+
* REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
26064
|
+
*/
|
|
26065
|
+
resource?: string;
|
|
26066
|
+
|
|
26067
|
+
/**
|
|
26068
|
+
* Request body metadata
|
|
26069
|
+
*/
|
|
26070
|
+
requestBody?: Schema$GoogleIamV1SetIamPolicyRequest;
|
|
26071
|
+
}
|
|
25652
26072
|
export interface Params$Resource$Projects$Locations$Collections$Updatedataconnector extends StandardParameters {
|
|
25653
26073
|
/**
|
|
25654
26074
|
* Identifier. The full resource name of the Data Connector. Format: `projects/x/locations/x/collections/x/dataConnector`.
|
|
@@ -26168,7 +26588,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
26168
26588
|
}
|
|
26169
26589
|
|
|
26170
26590
|
/**
|
|
26171
|
-
*
|
|
26591
|
+
* Makes a call to an MCP connector.
|
|
26172
26592
|
* @example
|
|
26173
26593
|
* ```js
|
|
26174
26594
|
* // Before running the sample:
|
|
@@ -26191,6 +26611,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
26191
26611
|
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
26192
26612
|
* scopes: [
|
|
26193
26613
|
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
26614
|
+
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
26194
26615
|
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
26195
26616
|
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
26196
26617
|
* ],
|
|
@@ -26202,26 +26623,29 @@ export namespace discoveryengine_v1alpha {
|
|
|
26202
26623
|
*
|
|
26203
26624
|
* // Do the magic
|
|
26204
26625
|
* const res =
|
|
26205
|
-
* await discoveryengine.projects.locations.collections.dataConnector.
|
|
26206
|
-
*
|
|
26207
|
-
*
|
|
26208
|
-
*
|
|
26209
|
-
* // The HTTP request/response body as raw binary.
|
|
26210
|
-
* data: 'placeholder-value',
|
|
26211
|
-
* // Application specific response metadata. Must be set in the first response for streaming APIs.
|
|
26212
|
-
* extensions: 'placeholder-value',
|
|
26213
|
-
*
|
|
26214
|
-
* locationsId: 'placeholder-value',
|
|
26626
|
+
* await discoveryengine.projects.locations.collections.dataConnector.invokeConnectorMcp(
|
|
26627
|
+
* {
|
|
26628
|
+
* // Required. DataConnector resource. The data connector used for making the MCP call.
|
|
26629
|
+
* name: 'projects/my-project/locations/my-location/collections/my-collection/dataConnector',
|
|
26215
26630
|
*
|
|
26216
|
-
*
|
|
26217
|
-
*
|
|
26631
|
+
* // Request body metadata
|
|
26632
|
+
* requestBody: {
|
|
26633
|
+
* // request body parameters
|
|
26634
|
+
* // {
|
|
26635
|
+
* // "engine": "my_engine",
|
|
26636
|
+
* // "method": "my_method",
|
|
26637
|
+
* // "params": {},
|
|
26638
|
+
* // "toolSpecVersion": "my_toolSpecVersion"
|
|
26639
|
+
* // }
|
|
26640
|
+
* },
|
|
26641
|
+
* },
|
|
26642
|
+
* );
|
|
26218
26643
|
* console.log(res.data);
|
|
26219
26644
|
*
|
|
26220
26645
|
* // Example response
|
|
26221
26646
|
* // {
|
|
26222
|
-
* // "
|
|
26223
|
-
* // "
|
|
26224
|
-
* // "extensions": []
|
|
26647
|
+
* // "error": {},
|
|
26648
|
+
* // "result": {}
|
|
26225
26649
|
* // }
|
|
26226
26650
|
* }
|
|
26227
26651
|
*
|
|
@@ -26237,54 +26661,62 @@ export namespace discoveryengine_v1alpha {
|
|
|
26237
26661
|
* @param callback - Optional callback that handles the response.
|
|
26238
26662
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
26239
26663
|
*/
|
|
26240
|
-
|
|
26241
|
-
params: Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26664
|
+
invokeConnectorMcp(
|
|
26665
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp,
|
|
26242
26666
|
options: StreamMethodOptions
|
|
26243
26667
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
26244
|
-
|
|
26245
|
-
params?: Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26668
|
+
invokeConnectorMcp(
|
|
26669
|
+
params?: Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp,
|
|
26246
26670
|
options?: MethodOptions
|
|
26247
|
-
): Promise<
|
|
26248
|
-
|
|
26249
|
-
|
|
26671
|
+
): Promise<
|
|
26672
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>
|
|
26673
|
+
>;
|
|
26674
|
+
invokeConnectorMcp(
|
|
26675
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp,
|
|
26250
26676
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
26251
26677
|
callback: BodyResponseCallback<Readable>
|
|
26252
26678
|
): void;
|
|
26253
|
-
|
|
26254
|
-
params: Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26255
|
-
options:
|
|
26256
|
-
|
|
26679
|
+
invokeConnectorMcp(
|
|
26680
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp,
|
|
26681
|
+
options:
|
|
26682
|
+
| MethodOptions
|
|
26683
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>,
|
|
26684
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>
|
|
26257
26685
|
): void;
|
|
26258
|
-
|
|
26259
|
-
params: Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26260
|
-
callback: BodyResponseCallback<Schema$
|
|
26686
|
+
invokeConnectorMcp(
|
|
26687
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp,
|
|
26688
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>
|
|
26261
26689
|
): void;
|
|
26262
|
-
|
|
26263
|
-
|
|
26690
|
+
invokeConnectorMcp(
|
|
26691
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>
|
|
26692
|
+
): void;
|
|
26693
|
+
invokeConnectorMcp(
|
|
26264
26694
|
paramsOrCallback?:
|
|
26265
|
-
| Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26266
|
-
| BodyResponseCallback<Schema$
|
|
26695
|
+
| Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp
|
|
26696
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>
|
|
26267
26697
|
| BodyResponseCallback<Readable>,
|
|
26268
26698
|
optionsOrCallback?:
|
|
26269
26699
|
| MethodOptions
|
|
26270
26700
|
| StreamMethodOptions
|
|
26271
|
-
| BodyResponseCallback<Schema$
|
|
26701
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>
|
|
26272
26702
|
| BodyResponseCallback<Readable>,
|
|
26273
26703
|
callback?:
|
|
26274
|
-
| BodyResponseCallback<Schema$
|
|
26704
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>
|
|
26275
26705
|
| BodyResponseCallback<Readable>
|
|
26276
26706
|
):
|
|
26277
26707
|
| void
|
|
26278
|
-
| Promise<
|
|
26708
|
+
| Promise<
|
|
26709
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>
|
|
26710
|
+
>
|
|
26279
26711
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
26280
26712
|
let params = (paramsOrCallback ||
|
|
26281
|
-
{}) as Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26713
|
+
{}) as Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp;
|
|
26282
26714
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
26283
26715
|
|
|
26284
26716
|
if (typeof paramsOrCallback === 'function') {
|
|
26285
26717
|
callback = paramsOrCallback;
|
|
26286
26718
|
params =
|
|
26287
|
-
{} as Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26719
|
+
{} as Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp;
|
|
26288
26720
|
options = {};
|
|
26289
26721
|
}
|
|
26290
26722
|
|
|
@@ -26298,32 +26730,34 @@ export namespace discoveryengine_v1alpha {
|
|
|
26298
26730
|
const parameters = {
|
|
26299
26731
|
options: Object.assign(
|
|
26300
26732
|
{
|
|
26301
|
-
url: (
|
|
26302
|
-
|
|
26303
|
-
'
|
|
26304
|
-
)
|
|
26305
|
-
method: '
|
|
26733
|
+
url: (rootUrl + '/v1alpha/{+name}:invokeConnectorMcp').replace(
|
|
26734
|
+
/([^:]\/)\/+/g,
|
|
26735
|
+
'$1'
|
|
26736
|
+
),
|
|
26737
|
+
method: 'POST',
|
|
26306
26738
|
apiVersion: '',
|
|
26307
26739
|
},
|
|
26308
26740
|
options
|
|
26309
26741
|
),
|
|
26310
26742
|
params,
|
|
26311
|
-
requiredParams: ['
|
|
26312
|
-
pathParams: ['
|
|
26743
|
+
requiredParams: ['name'],
|
|
26744
|
+
pathParams: ['name'],
|
|
26313
26745
|
context: this.context,
|
|
26314
26746
|
};
|
|
26315
26747
|
if (callback) {
|
|
26316
|
-
createAPIRequest<Schema$
|
|
26748
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>(
|
|
26317
26749
|
parameters,
|
|
26318
26750
|
callback as BodyResponseCallback<unknown>
|
|
26319
26751
|
);
|
|
26320
26752
|
} else {
|
|
26321
|
-
return createAPIRequest<Schema$
|
|
26753
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpResponse>(
|
|
26754
|
+
parameters
|
|
26755
|
+
);
|
|
26322
26756
|
}
|
|
26323
26757
|
}
|
|
26324
26758
|
|
|
26325
26759
|
/**
|
|
26326
|
-
*
|
|
26760
|
+
* ServeMcpDeleteRequest serves a MCP DELETE request.
|
|
26327
26761
|
* @example
|
|
26328
26762
|
* ```js
|
|
26329
26763
|
* // Before running the sample:
|
|
@@ -26346,7 +26780,6 @@ export namespace discoveryengine_v1alpha {
|
|
|
26346
26780
|
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
26347
26781
|
* scopes: [
|
|
26348
26782
|
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
26349
|
-
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
26350
26783
|
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
26351
26784
|
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
26352
26785
|
* ],
|
|
@@ -26358,38 +26791,26 @@ export namespace discoveryengine_v1alpha {
|
|
|
26358
26791
|
*
|
|
26359
26792
|
* // Do the magic
|
|
26360
26793
|
* const res =
|
|
26361
|
-
* await discoveryengine.projects.locations.collections.dataConnector.
|
|
26362
|
-
*
|
|
26363
|
-
*
|
|
26364
|
-
*
|
|
26365
|
-
*
|
|
26794
|
+
* await discoveryengine.projects.locations.collections.dataConnector.mcp({
|
|
26795
|
+
* collectionsId: 'placeholder-value',
|
|
26796
|
+
* // The HTTP Content-Type header value specifying the content type of the body.
|
|
26797
|
+
* contentType: 'placeholder-value',
|
|
26798
|
+
* // The HTTP request/response body as raw binary.
|
|
26799
|
+
* data: 'placeholder-value',
|
|
26800
|
+
* // Application specific response metadata. Must be set in the first response for streaming APIs.
|
|
26801
|
+
* extensions: 'placeholder-value',
|
|
26366
26802
|
*
|
|
26367
|
-
*
|
|
26368
|
-
*
|
|
26369
|
-
*
|
|
26370
|
-
*
|
|
26371
|
-
* // "entities": [],
|
|
26372
|
-
* // "forceRefreshContent": false,
|
|
26373
|
-
* // "healthcareFhirResourceTypes": [],
|
|
26374
|
-
* // "syncIdentity": false,
|
|
26375
|
-
* // "syncSinceTimestamp": "my_syncSinceTimestamp"
|
|
26376
|
-
* // }
|
|
26377
|
-
* },
|
|
26378
|
-
* },
|
|
26379
|
-
* );
|
|
26803
|
+
* locationsId: 'placeholder-value',
|
|
26804
|
+
*
|
|
26805
|
+
* projectsId: 'placeholder-value',
|
|
26806
|
+
* });
|
|
26380
26807
|
* console.log(res.data);
|
|
26381
26808
|
*
|
|
26382
26809
|
* // Example response
|
|
26383
26810
|
* // {
|
|
26384
|
-
* // "
|
|
26385
|
-
* // "
|
|
26386
|
-
* // "
|
|
26387
|
-
* // "latestPauseTime": "my_latestPauseTime",
|
|
26388
|
-
* // "name": "my_name",
|
|
26389
|
-
* // "startTime": "my_startTime",
|
|
26390
|
-
* // "state": "my_state",
|
|
26391
|
-
* // "stateUpdateTime": "my_stateUpdateTime",
|
|
26392
|
-
* // "trigger": "my_trigger"
|
|
26811
|
+
* // "contentType": "my_contentType",
|
|
26812
|
+
* // "data": "my_data",
|
|
26813
|
+
* // "extensions": []
|
|
26393
26814
|
* // }
|
|
26394
26815
|
* }
|
|
26395
26816
|
*
|
|
@@ -26405,62 +26826,54 @@ export namespace discoveryengine_v1alpha {
|
|
|
26405
26826
|
* @param callback - Optional callback that handles the response.
|
|
26406
26827
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
26407
26828
|
*/
|
|
26408
|
-
|
|
26409
|
-
params: Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26829
|
+
mcp(
|
|
26830
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp,
|
|
26410
26831
|
options: StreamMethodOptions
|
|
26411
26832
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
26412
|
-
|
|
26413
|
-
params?: Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26833
|
+
mcp(
|
|
26834
|
+
params?: Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp,
|
|
26414
26835
|
options?: MethodOptions
|
|
26415
|
-
): Promise<
|
|
26416
|
-
|
|
26417
|
-
|
|
26418
|
-
startConnectorRun(
|
|
26419
|
-
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun,
|
|
26836
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleApiHttpBody>>;
|
|
26837
|
+
mcp(
|
|
26838
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp,
|
|
26420
26839
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
26421
26840
|
callback: BodyResponseCallback<Readable>
|
|
26422
26841
|
): void;
|
|
26423
|
-
|
|
26424
|
-
params: Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26425
|
-
options:
|
|
26426
|
-
|
|
26427
|
-
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>,
|
|
26428
|
-
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
26429
|
-
): void;
|
|
26430
|
-
startConnectorRun(
|
|
26431
|
-
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun,
|
|
26432
|
-
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
26842
|
+
mcp(
|
|
26843
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp,
|
|
26844
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleApiHttpBody>,
|
|
26845
|
+
callback: BodyResponseCallback<Schema$GoogleApiHttpBody>
|
|
26433
26846
|
): void;
|
|
26434
|
-
|
|
26435
|
-
|
|
26847
|
+
mcp(
|
|
26848
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp,
|
|
26849
|
+
callback: BodyResponseCallback<Schema$GoogleApiHttpBody>
|
|
26436
26850
|
): void;
|
|
26437
|
-
|
|
26851
|
+
mcp(callback: BodyResponseCallback<Schema$GoogleApiHttpBody>): void;
|
|
26852
|
+
mcp(
|
|
26438
26853
|
paramsOrCallback?:
|
|
26439
|
-
| Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26440
|
-
| BodyResponseCallback<Schema$
|
|
26854
|
+
| Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp
|
|
26855
|
+
| BodyResponseCallback<Schema$GoogleApiHttpBody>
|
|
26441
26856
|
| BodyResponseCallback<Readable>,
|
|
26442
26857
|
optionsOrCallback?:
|
|
26443
26858
|
| MethodOptions
|
|
26444
26859
|
| StreamMethodOptions
|
|
26445
|
-
| BodyResponseCallback<Schema$
|
|
26860
|
+
| BodyResponseCallback<Schema$GoogleApiHttpBody>
|
|
26446
26861
|
| BodyResponseCallback<Readable>,
|
|
26447
26862
|
callback?:
|
|
26448
|
-
| BodyResponseCallback<Schema$
|
|
26863
|
+
| BodyResponseCallback<Schema$GoogleApiHttpBody>
|
|
26449
26864
|
| BodyResponseCallback<Readable>
|
|
26450
26865
|
):
|
|
26451
26866
|
| void
|
|
26452
|
-
| Promise<
|
|
26453
|
-
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
26454
|
-
>
|
|
26867
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleApiHttpBody>>
|
|
26455
26868
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
26456
26869
|
let params = (paramsOrCallback ||
|
|
26457
|
-
{}) as Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26870
|
+
{}) as Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp;
|
|
26458
26871
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
26459
26872
|
|
|
26460
26873
|
if (typeof paramsOrCallback === 'function') {
|
|
26461
26874
|
callback = paramsOrCallback;
|
|
26462
26875
|
params =
|
|
26463
|
-
{} as Params$Resource$Projects$Locations$Collections$Dataconnector$
|
|
26876
|
+
{} as Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp;
|
|
26464
26877
|
options = {};
|
|
26465
26878
|
}
|
|
26466
26879
|
|
|
@@ -26474,102 +26887,289 @@ export namespace discoveryengine_v1alpha {
|
|
|
26474
26887
|
const parameters = {
|
|
26475
26888
|
options: Object.assign(
|
|
26476
26889
|
{
|
|
26477
|
-
url: (
|
|
26478
|
-
|
|
26479
|
-
'
|
|
26480
|
-
),
|
|
26481
|
-
method: '
|
|
26890
|
+
url: (
|
|
26891
|
+
rootUrl +
|
|
26892
|
+
'/v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataConnector/mcp'
|
|
26893
|
+
).replace(/([^:]\/)\/+/g, '$1'),
|
|
26894
|
+
method: 'DELETE',
|
|
26482
26895
|
apiVersion: '',
|
|
26483
26896
|
},
|
|
26484
26897
|
options
|
|
26485
26898
|
),
|
|
26486
26899
|
params,
|
|
26487
|
-
requiredParams: ['
|
|
26488
|
-
pathParams: ['
|
|
26900
|
+
requiredParams: ['projectsId', 'locationsId', 'collectionsId'],
|
|
26901
|
+
pathParams: ['collectionsId', 'locationsId', 'projectsId'],
|
|
26489
26902
|
context: this.context,
|
|
26490
26903
|
};
|
|
26491
26904
|
if (callback) {
|
|
26492
|
-
createAPIRequest<Schema$
|
|
26905
|
+
createAPIRequest<Schema$GoogleApiHttpBody>(
|
|
26493
26906
|
parameters,
|
|
26494
26907
|
callback as BodyResponseCallback<unknown>
|
|
26495
26908
|
);
|
|
26496
26909
|
} else {
|
|
26497
|
-
return createAPIRequest<Schema$
|
|
26498
|
-
parameters
|
|
26499
|
-
);
|
|
26910
|
+
return createAPIRequest<Schema$GoogleApiHttpBody>(parameters);
|
|
26500
26911
|
}
|
|
26501
26912
|
}
|
|
26502
|
-
}
|
|
26503
26913
|
|
|
26504
|
-
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Acquireaccesstoken extends StandardParameters {
|
|
26505
|
-
/**
|
|
26506
|
-
* Required. The resource name of the connector for which a token is queried.
|
|
26507
|
-
*/
|
|
26508
|
-
name?: string;
|
|
26509
|
-
|
|
26510
|
-
/**
|
|
26511
|
-
* Request body metadata
|
|
26512
|
-
*/
|
|
26513
|
-
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaAcquireAccessTokenRequest;
|
|
26514
|
-
}
|
|
26515
|
-
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Checkrefreshtoken extends StandardParameters {
|
|
26516
|
-
/**
|
|
26517
|
-
* Required. The resource name of the connector for which a token is queried.
|
|
26518
|
-
*/
|
|
26519
|
-
name?: string;
|
|
26520
|
-
}
|
|
26521
|
-
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Getconnectorsecret extends StandardParameters {
|
|
26522
|
-
/**
|
|
26523
|
-
* Required. The full resource name of the associated data connector.
|
|
26524
|
-
*/
|
|
26525
|
-
name?: string;
|
|
26526
|
-
}
|
|
26527
|
-
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp extends StandardParameters {
|
|
26528
|
-
/**
|
|
26529
|
-
*
|
|
26530
|
-
*/
|
|
26531
|
-
collectionsId?: string;
|
|
26532
26914
|
/**
|
|
26533
|
-
*
|
|
26534
|
-
|
|
26535
|
-
|
|
26536
|
-
|
|
26537
|
-
*
|
|
26538
|
-
|
|
26539
|
-
|
|
26540
|
-
|
|
26541
|
-
*
|
|
26542
|
-
|
|
26543
|
-
|
|
26544
|
-
|
|
26545
|
-
*
|
|
26546
|
-
|
|
26547
|
-
|
|
26548
|
-
|
|
26549
|
-
*
|
|
26550
|
-
|
|
26551
|
-
|
|
26552
|
-
|
|
26553
|
-
|
|
26554
|
-
|
|
26555
|
-
*
|
|
26556
|
-
|
|
26557
|
-
|
|
26558
|
-
|
|
26559
|
-
|
|
26560
|
-
*
|
|
26561
|
-
|
|
26562
|
-
|
|
26563
|
-
|
|
26564
|
-
|
|
26565
|
-
|
|
26566
|
-
|
|
26567
|
-
|
|
26568
|
-
|
|
26569
|
-
|
|
26570
|
-
|
|
26571
|
-
|
|
26572
|
-
*
|
|
26915
|
+
* Starts an immediate synchronization process for a DataConnector. Third Party Connector Users must specify which entities should be synced. FHIR Connectors must provide a timestamp to indicate the point in time from which data should be synced.
|
|
26916
|
+
* @example
|
|
26917
|
+
* ```js
|
|
26918
|
+
* // Before running the sample:
|
|
26919
|
+
* // - Enable the API at:
|
|
26920
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
26921
|
+
* // - Login into gcloud by running:
|
|
26922
|
+
* // ```sh
|
|
26923
|
+
* // $ gcloud auth application-default login
|
|
26924
|
+
* // ```
|
|
26925
|
+
* // - Install the npm module by running:
|
|
26926
|
+
* // ```sh
|
|
26927
|
+
* // $ npm install googleapis
|
|
26928
|
+
* // ```
|
|
26929
|
+
*
|
|
26930
|
+
* const {google} = require('googleapis');
|
|
26931
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
26932
|
+
*
|
|
26933
|
+
* async function main() {
|
|
26934
|
+
* const auth = new google.auth.GoogleAuth({
|
|
26935
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
26936
|
+
* scopes: [
|
|
26937
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
26938
|
+
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
26939
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
26940
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
26941
|
+
* ],
|
|
26942
|
+
* });
|
|
26943
|
+
*
|
|
26944
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
26945
|
+
* const authClient = await auth.getClient();
|
|
26946
|
+
* google.options({auth: authClient});
|
|
26947
|
+
*
|
|
26948
|
+
* // Do the magic
|
|
26949
|
+
* const res =
|
|
26950
|
+
* await discoveryengine.projects.locations.collections.dataConnector.startConnectorRun(
|
|
26951
|
+
* {
|
|
26952
|
+
* // Required. Connector name of the form `projects/{project\}/locations/{location\}/collections/{collection_id\}/dataConnector`
|
|
26953
|
+
* parent:
|
|
26954
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/dataConnector',
|
|
26955
|
+
*
|
|
26956
|
+
* // Request body metadata
|
|
26957
|
+
* requestBody: {
|
|
26958
|
+
* // request body parameters
|
|
26959
|
+
* // {
|
|
26960
|
+
* // "entities": [],
|
|
26961
|
+
* // "forceRefreshContent": false,
|
|
26962
|
+
* // "healthcareFhirResourceTypes": [],
|
|
26963
|
+
* // "syncIdentity": false,
|
|
26964
|
+
* // "syncSinceTimestamp": "my_syncSinceTimestamp"
|
|
26965
|
+
* // }
|
|
26966
|
+
* },
|
|
26967
|
+
* },
|
|
26968
|
+
* );
|
|
26969
|
+
* console.log(res.data);
|
|
26970
|
+
*
|
|
26971
|
+
* // Example response
|
|
26972
|
+
* // {
|
|
26973
|
+
* // "endTime": "my_endTime",
|
|
26974
|
+
* // "entityRuns": [],
|
|
26975
|
+
* // "errors": [],
|
|
26976
|
+
* // "latestPauseTime": "my_latestPauseTime",
|
|
26977
|
+
* // "name": "my_name",
|
|
26978
|
+
* // "startTime": "my_startTime",
|
|
26979
|
+
* // "state": "my_state",
|
|
26980
|
+
* // "stateUpdateTime": "my_stateUpdateTime",
|
|
26981
|
+
* // "trigger": "my_trigger"
|
|
26982
|
+
* // }
|
|
26983
|
+
* }
|
|
26984
|
+
*
|
|
26985
|
+
* main().catch(e => {
|
|
26986
|
+
* console.error(e);
|
|
26987
|
+
* throw e;
|
|
26988
|
+
* });
|
|
26989
|
+
*
|
|
26990
|
+
* ```
|
|
26991
|
+
*
|
|
26992
|
+
* @param params - Parameters for request
|
|
26993
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
26994
|
+
* @param callback - Optional callback that handles the response.
|
|
26995
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
26996
|
+
*/
|
|
26997
|
+
startConnectorRun(
|
|
26998
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun,
|
|
26999
|
+
options: StreamMethodOptions
|
|
27000
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
27001
|
+
startConnectorRun(
|
|
27002
|
+
params?: Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun,
|
|
27003
|
+
options?: MethodOptions
|
|
27004
|
+
): Promise<
|
|
27005
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
27006
|
+
>;
|
|
27007
|
+
startConnectorRun(
|
|
27008
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun,
|
|
27009
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
27010
|
+
callback: BodyResponseCallback<Readable>
|
|
27011
|
+
): void;
|
|
27012
|
+
startConnectorRun(
|
|
27013
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun,
|
|
27014
|
+
options:
|
|
27015
|
+
| MethodOptions
|
|
27016
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>,
|
|
27017
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
27018
|
+
): void;
|
|
27019
|
+
startConnectorRun(
|
|
27020
|
+
params: Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun,
|
|
27021
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
27022
|
+
): void;
|
|
27023
|
+
startConnectorRun(
|
|
27024
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
27025
|
+
): void;
|
|
27026
|
+
startConnectorRun(
|
|
27027
|
+
paramsOrCallback?:
|
|
27028
|
+
| Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun
|
|
27029
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
27030
|
+
| BodyResponseCallback<Readable>,
|
|
27031
|
+
optionsOrCallback?:
|
|
27032
|
+
| MethodOptions
|
|
27033
|
+
| StreamMethodOptions
|
|
27034
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
27035
|
+
| BodyResponseCallback<Readable>,
|
|
27036
|
+
callback?:
|
|
27037
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
27038
|
+
| BodyResponseCallback<Readable>
|
|
27039
|
+
):
|
|
27040
|
+
| void
|
|
27041
|
+
| Promise<
|
|
27042
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>
|
|
27043
|
+
>
|
|
27044
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
27045
|
+
let params = (paramsOrCallback ||
|
|
27046
|
+
{}) as Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun;
|
|
27047
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
27048
|
+
|
|
27049
|
+
if (typeof paramsOrCallback === 'function') {
|
|
27050
|
+
callback = paramsOrCallback;
|
|
27051
|
+
params =
|
|
27052
|
+
{} as Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun;
|
|
27053
|
+
options = {};
|
|
27054
|
+
}
|
|
27055
|
+
|
|
27056
|
+
if (typeof optionsOrCallback === 'function') {
|
|
27057
|
+
callback = optionsOrCallback;
|
|
27058
|
+
options = {};
|
|
27059
|
+
}
|
|
27060
|
+
|
|
27061
|
+
const rootUrl =
|
|
27062
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
27063
|
+
const parameters = {
|
|
27064
|
+
options: Object.assign(
|
|
27065
|
+
{
|
|
27066
|
+
url: (rootUrl + '/v1alpha/{+parent}:startConnectorRun').replace(
|
|
27067
|
+
/([^:]\/)\/+/g,
|
|
27068
|
+
'$1'
|
|
27069
|
+
),
|
|
27070
|
+
method: 'POST',
|
|
27071
|
+
apiVersion: '',
|
|
27072
|
+
},
|
|
27073
|
+
options
|
|
27074
|
+
),
|
|
27075
|
+
params,
|
|
27076
|
+
requiredParams: ['parent'],
|
|
27077
|
+
pathParams: ['parent'],
|
|
27078
|
+
context: this.context,
|
|
27079
|
+
};
|
|
27080
|
+
if (callback) {
|
|
27081
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>(
|
|
27082
|
+
parameters,
|
|
27083
|
+
callback as BodyResponseCallback<unknown>
|
|
27084
|
+
);
|
|
27085
|
+
} else {
|
|
27086
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaConnectorRun>(
|
|
27087
|
+
parameters
|
|
27088
|
+
);
|
|
27089
|
+
}
|
|
27090
|
+
}
|
|
27091
|
+
}
|
|
27092
|
+
|
|
27093
|
+
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Acquireaccesstoken extends StandardParameters {
|
|
27094
|
+
/**
|
|
27095
|
+
* Required. The resource name of the connector for which a token is queried.
|
|
27096
|
+
*/
|
|
27097
|
+
name?: string;
|
|
27098
|
+
|
|
27099
|
+
/**
|
|
27100
|
+
* Request body metadata
|
|
27101
|
+
*/
|
|
27102
|
+
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaAcquireAccessTokenRequest;
|
|
27103
|
+
}
|
|
27104
|
+
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Checkrefreshtoken extends StandardParameters {
|
|
27105
|
+
/**
|
|
27106
|
+
* Required. The resource name of the connector for which a token is queried.
|
|
27107
|
+
*/
|
|
27108
|
+
name?: string;
|
|
27109
|
+
}
|
|
27110
|
+
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Getconnectorsecret extends StandardParameters {
|
|
27111
|
+
/**
|
|
27112
|
+
* Required. The full resource name of the associated data connector.
|
|
27113
|
+
*/
|
|
27114
|
+
name?: string;
|
|
27115
|
+
}
|
|
27116
|
+
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Invokeconnectormcp extends StandardParameters {
|
|
27117
|
+
/**
|
|
27118
|
+
* Required. DataConnector resource. The data connector used for making the MCP call.
|
|
27119
|
+
*/
|
|
27120
|
+
name?: string;
|
|
27121
|
+
|
|
27122
|
+
/**
|
|
27123
|
+
* Request body metadata
|
|
27124
|
+
*/
|
|
27125
|
+
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaInvokeConnectorMcpRequest;
|
|
27126
|
+
}
|
|
27127
|
+
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Mcp extends StandardParameters {
|
|
27128
|
+
/**
|
|
27129
|
+
*
|
|
27130
|
+
*/
|
|
27131
|
+
collectionsId?: string;
|
|
27132
|
+
/**
|
|
27133
|
+
* The HTTP Content-Type header value specifying the content type of the body.
|
|
27134
|
+
*/
|
|
27135
|
+
contentType?: string;
|
|
27136
|
+
/**
|
|
27137
|
+
* The HTTP request/response body as raw binary.
|
|
27138
|
+
*/
|
|
27139
|
+
data?: string;
|
|
27140
|
+
/**
|
|
27141
|
+
* Application specific response metadata. Must be set in the first response for streaming APIs.
|
|
27142
|
+
*/
|
|
27143
|
+
extensions?: {[key: string]: any}[];
|
|
27144
|
+
/**
|
|
27145
|
+
*
|
|
27146
|
+
*/
|
|
27147
|
+
locationsId?: string;
|
|
27148
|
+
/**
|
|
27149
|
+
*
|
|
27150
|
+
*/
|
|
27151
|
+
projectsId?: string;
|
|
27152
|
+
}
|
|
27153
|
+
export interface Params$Resource$Projects$Locations$Collections$Dataconnector$Startconnectorrun extends StandardParameters {
|
|
27154
|
+
/**
|
|
27155
|
+
* Required. Connector name of the form `projects/{project\}/locations/{location\}/collections/{collection_id\}/dataConnector`
|
|
27156
|
+
*/
|
|
27157
|
+
parent?: string;
|
|
27158
|
+
|
|
27159
|
+
/**
|
|
27160
|
+
* Request body metadata
|
|
27161
|
+
*/
|
|
27162
|
+
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaStartConnectorRunRequest;
|
|
27163
|
+
}
|
|
27164
|
+
|
|
27165
|
+
export class Resource$Projects$Locations$Collections$Dataconnector$Connectorruns {
|
|
27166
|
+
context: APIRequestContext;
|
|
27167
|
+
constructor(context: APIRequestContext) {
|
|
27168
|
+
this.context = context;
|
|
27169
|
+
}
|
|
27170
|
+
|
|
27171
|
+
/**
|
|
27172
|
+
* Lists the ConnectorRuns of a DataConnector.
|
|
26573
27173
|
* @example
|
|
26574
27174
|
* ```js
|
|
26575
27175
|
* // Before running the sample:
|
|
@@ -28516,7 +29116,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
28516
29116
|
}
|
|
28517
29117
|
|
|
28518
29118
|
/**
|
|
28519
|
-
* Gets the
|
|
29119
|
+
* Gets the IAM access control policy for a DataStore. A `NOT_FOUND` error is returned if the resource does not exist. An empty policy is returned if the resource exists but does not have a policy set on it.
|
|
28520
29120
|
* @example
|
|
28521
29121
|
* ```js
|
|
28522
29122
|
* // Before running the sample:
|
|
@@ -28550,17 +29150,22 @@ export namespace discoveryengine_v1alpha {
|
|
|
28550
29150
|
*
|
|
28551
29151
|
* // Do the magic
|
|
28552
29152
|
* const res =
|
|
28553
|
-
* await discoveryengine.projects.locations.collections.dataStores.
|
|
29153
|
+
* await discoveryengine.projects.locations.collections.dataStores.getIamPolicy(
|
|
28554
29154
|
* {
|
|
28555
|
-
* //
|
|
28556
|
-
*
|
|
29155
|
+
* // Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
|
|
29156
|
+
* 'options.requestedPolicyVersion': 'placeholder-value',
|
|
29157
|
+
* // REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
29158
|
+
* resource:
|
|
29159
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/dataStores/my-dataStore',
|
|
28557
29160
|
* },
|
|
28558
29161
|
* );
|
|
28559
29162
|
* console.log(res.data);
|
|
28560
29163
|
*
|
|
28561
29164
|
* // Example response
|
|
28562
29165
|
* // {
|
|
28563
|
-
* // "
|
|
29166
|
+
* // "bindings": [],
|
|
29167
|
+
* // "etag": "my_etag",
|
|
29168
|
+
* // "version": 0
|
|
28564
29169
|
* // }
|
|
28565
29170
|
* }
|
|
28566
29171
|
*
|
|
@@ -28576,62 +29181,56 @@ export namespace discoveryengine_v1alpha {
|
|
|
28576
29181
|
* @param callback - Optional callback that handles the response.
|
|
28577
29182
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
28578
29183
|
*/
|
|
28579
|
-
|
|
28580
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$
|
|
29184
|
+
getIamPolicy(
|
|
29185
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy,
|
|
28581
29186
|
options: StreamMethodOptions
|
|
28582
29187
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
28583
|
-
|
|
28584
|
-
params?: Params$Resource$Projects$Locations$Collections$Datastores$
|
|
29188
|
+
getIamPolicy(
|
|
29189
|
+
params?: Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy,
|
|
28585
29190
|
options?: MethodOptions
|
|
28586
|
-
): Promise<
|
|
28587
|
-
|
|
28588
|
-
|
|
28589
|
-
getSiteSearchEngine(
|
|
28590
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine,
|
|
29191
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>;
|
|
29192
|
+
getIamPolicy(
|
|
29193
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy,
|
|
28591
29194
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
28592
29195
|
callback: BodyResponseCallback<Readable>
|
|
28593
29196
|
): void;
|
|
28594
|
-
|
|
28595
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$
|
|
28596
|
-
options:
|
|
28597
|
-
|
|
28598
|
-
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>,
|
|
28599
|
-
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29197
|
+
getIamPolicy(
|
|
29198
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy,
|
|
29199
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleIamV1Policy>,
|
|
29200
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
28600
29201
|
): void;
|
|
28601
|
-
|
|
28602
|
-
params: Params$Resource$Projects$Locations$Collections$Datastores$
|
|
28603
|
-
callback: BodyResponseCallback<Schema$
|
|
29202
|
+
getIamPolicy(
|
|
29203
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy,
|
|
29204
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
28604
29205
|
): void;
|
|
28605
|
-
|
|
28606
|
-
callback: BodyResponseCallback<Schema$
|
|
29206
|
+
getIamPolicy(
|
|
29207
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
28607
29208
|
): void;
|
|
28608
|
-
|
|
29209
|
+
getIamPolicy(
|
|
28609
29210
|
paramsOrCallback?:
|
|
28610
|
-
| Params$Resource$Projects$Locations$Collections$Datastores$
|
|
28611
|
-
| BodyResponseCallback<Schema$
|
|
29211
|
+
| Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy
|
|
29212
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
28612
29213
|
| BodyResponseCallback<Readable>,
|
|
28613
29214
|
optionsOrCallback?:
|
|
28614
29215
|
| MethodOptions
|
|
28615
29216
|
| StreamMethodOptions
|
|
28616
|
-
| BodyResponseCallback<Schema$
|
|
29217
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
28617
29218
|
| BodyResponseCallback<Readable>,
|
|
28618
29219
|
callback?:
|
|
28619
|
-
| BodyResponseCallback<Schema$
|
|
29220
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
28620
29221
|
| BodyResponseCallback<Readable>
|
|
28621
29222
|
):
|
|
28622
29223
|
| void
|
|
28623
|
-
| Promise<
|
|
28624
|
-
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
28625
|
-
>
|
|
29224
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>
|
|
28626
29225
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
28627
29226
|
let params = (paramsOrCallback ||
|
|
28628
|
-
{}) as Params$Resource$Projects$Locations$Collections$Datastores$
|
|
29227
|
+
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy;
|
|
28629
29228
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
28630
29229
|
|
|
28631
29230
|
if (typeof paramsOrCallback === 'function') {
|
|
28632
29231
|
callback = paramsOrCallback;
|
|
28633
29232
|
params =
|
|
28634
|
-
{} as Params$Resource$Projects$Locations$Collections$Datastores$
|
|
29233
|
+
{} as Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy;
|
|
28635
29234
|
options = {};
|
|
28636
29235
|
}
|
|
28637
29236
|
|
|
@@ -28645,31 +29244,185 @@ export namespace discoveryengine_v1alpha {
|
|
|
28645
29244
|
const parameters = {
|
|
28646
29245
|
options: Object.assign(
|
|
28647
29246
|
{
|
|
28648
|
-
url: (rootUrl + '/v1alpha/{+
|
|
29247
|
+
url: (rootUrl + '/v1alpha/{+resource}:getIamPolicy').replace(
|
|
29248
|
+
/([^:]\/)\/+/g,
|
|
29249
|
+
'$1'
|
|
29250
|
+
),
|
|
28649
29251
|
method: 'GET',
|
|
28650
29252
|
apiVersion: '',
|
|
28651
29253
|
},
|
|
28652
29254
|
options
|
|
28653
29255
|
),
|
|
28654
29256
|
params,
|
|
28655
|
-
requiredParams: ['
|
|
28656
|
-
pathParams: ['
|
|
29257
|
+
requiredParams: ['resource'],
|
|
29258
|
+
pathParams: ['resource'],
|
|
28657
29259
|
context: this.context,
|
|
28658
29260
|
};
|
|
28659
29261
|
if (callback) {
|
|
28660
|
-
createAPIRequest<Schema$
|
|
29262
|
+
createAPIRequest<Schema$GoogleIamV1Policy>(
|
|
28661
29263
|
parameters,
|
|
28662
29264
|
callback as BodyResponseCallback<unknown>
|
|
28663
29265
|
);
|
|
28664
29266
|
} else {
|
|
28665
|
-
return createAPIRequest<Schema$
|
|
28666
|
-
parameters
|
|
28667
|
-
);
|
|
29267
|
+
return createAPIRequest<Schema$GoogleIamV1Policy>(parameters);
|
|
28668
29268
|
}
|
|
28669
29269
|
}
|
|
28670
29270
|
|
|
28671
29271
|
/**
|
|
28672
|
-
*
|
|
29272
|
+
* Gets the SiteSearchEngine.
|
|
29273
|
+
* @example
|
|
29274
|
+
* ```js
|
|
29275
|
+
* // Before running the sample:
|
|
29276
|
+
* // - Enable the API at:
|
|
29277
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
29278
|
+
* // - Login into gcloud by running:
|
|
29279
|
+
* // ```sh
|
|
29280
|
+
* // $ gcloud auth application-default login
|
|
29281
|
+
* // ```
|
|
29282
|
+
* // - Install the npm module by running:
|
|
29283
|
+
* // ```sh
|
|
29284
|
+
* // $ npm install googleapis
|
|
29285
|
+
* // ```
|
|
29286
|
+
*
|
|
29287
|
+
* const {google} = require('googleapis');
|
|
29288
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
29289
|
+
*
|
|
29290
|
+
* async function main() {
|
|
29291
|
+
* const auth = new google.auth.GoogleAuth({
|
|
29292
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
29293
|
+
* scopes: [
|
|
29294
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
29295
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
29296
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
29297
|
+
* ],
|
|
29298
|
+
* });
|
|
29299
|
+
*
|
|
29300
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
29301
|
+
* const authClient = await auth.getClient();
|
|
29302
|
+
* google.options({auth: authClient});
|
|
29303
|
+
*
|
|
29304
|
+
* // Do the magic
|
|
29305
|
+
* const res =
|
|
29306
|
+
* await discoveryengine.projects.locations.collections.dataStores.getSiteSearchEngine(
|
|
29307
|
+
* {
|
|
29308
|
+
* // Required. Resource name of SiteSearchEngine, such as `projects/{project\}/locations/{location\}/collections/{collection\}/dataStores/{data_store\}/siteSearchEngine`. If the caller does not have permission to access the [SiteSearchEngine], regardless of whether or not it exists, a PERMISSION_DENIED error is returned.
|
|
29309
|
+
* name: 'projects/my-project/locations/my-location/collections/my-collection/dataStores/my-dataStore/siteSearchEngine',
|
|
29310
|
+
* },
|
|
29311
|
+
* );
|
|
29312
|
+
* console.log(res.data);
|
|
29313
|
+
*
|
|
29314
|
+
* // Example response
|
|
29315
|
+
* // {
|
|
29316
|
+
* // "name": "my_name"
|
|
29317
|
+
* // }
|
|
29318
|
+
* }
|
|
29319
|
+
*
|
|
29320
|
+
* main().catch(e => {
|
|
29321
|
+
* console.error(e);
|
|
29322
|
+
* throw e;
|
|
29323
|
+
* });
|
|
29324
|
+
*
|
|
29325
|
+
* ```
|
|
29326
|
+
*
|
|
29327
|
+
* @param params - Parameters for request
|
|
29328
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
29329
|
+
* @param callback - Optional callback that handles the response.
|
|
29330
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
29331
|
+
*/
|
|
29332
|
+
getSiteSearchEngine(
|
|
29333
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine,
|
|
29334
|
+
options: StreamMethodOptions
|
|
29335
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
29336
|
+
getSiteSearchEngine(
|
|
29337
|
+
params?: Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine,
|
|
29338
|
+
options?: MethodOptions
|
|
29339
|
+
): Promise<
|
|
29340
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29341
|
+
>;
|
|
29342
|
+
getSiteSearchEngine(
|
|
29343
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine,
|
|
29344
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
29345
|
+
callback: BodyResponseCallback<Readable>
|
|
29346
|
+
): void;
|
|
29347
|
+
getSiteSearchEngine(
|
|
29348
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine,
|
|
29349
|
+
options:
|
|
29350
|
+
| MethodOptions
|
|
29351
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>,
|
|
29352
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29353
|
+
): void;
|
|
29354
|
+
getSiteSearchEngine(
|
|
29355
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine,
|
|
29356
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29357
|
+
): void;
|
|
29358
|
+
getSiteSearchEngine(
|
|
29359
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29360
|
+
): void;
|
|
29361
|
+
getSiteSearchEngine(
|
|
29362
|
+
paramsOrCallback?:
|
|
29363
|
+
| Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine
|
|
29364
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29365
|
+
| BodyResponseCallback<Readable>,
|
|
29366
|
+
optionsOrCallback?:
|
|
29367
|
+
| MethodOptions
|
|
29368
|
+
| StreamMethodOptions
|
|
29369
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29370
|
+
| BodyResponseCallback<Readable>,
|
|
29371
|
+
callback?:
|
|
29372
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29373
|
+
| BodyResponseCallback<Readable>
|
|
29374
|
+
):
|
|
29375
|
+
| void
|
|
29376
|
+
| Promise<
|
|
29377
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>
|
|
29378
|
+
>
|
|
29379
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
29380
|
+
let params = (paramsOrCallback ||
|
|
29381
|
+
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine;
|
|
29382
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
29383
|
+
|
|
29384
|
+
if (typeof paramsOrCallback === 'function') {
|
|
29385
|
+
callback = paramsOrCallback;
|
|
29386
|
+
params =
|
|
29387
|
+
{} as Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine;
|
|
29388
|
+
options = {};
|
|
29389
|
+
}
|
|
29390
|
+
|
|
29391
|
+
if (typeof optionsOrCallback === 'function') {
|
|
29392
|
+
callback = optionsOrCallback;
|
|
29393
|
+
options = {};
|
|
29394
|
+
}
|
|
29395
|
+
|
|
29396
|
+
const rootUrl =
|
|
29397
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
29398
|
+
const parameters = {
|
|
29399
|
+
options: Object.assign(
|
|
29400
|
+
{
|
|
29401
|
+
url: (rootUrl + '/v1alpha/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
29402
|
+
method: 'GET',
|
|
29403
|
+
apiVersion: '',
|
|
29404
|
+
},
|
|
29405
|
+
options
|
|
29406
|
+
),
|
|
29407
|
+
params,
|
|
29408
|
+
requiredParams: ['name'],
|
|
29409
|
+
pathParams: ['name'],
|
|
29410
|
+
context: this.context,
|
|
29411
|
+
};
|
|
29412
|
+
if (callback) {
|
|
29413
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>(
|
|
29414
|
+
parameters,
|
|
29415
|
+
callback as BodyResponseCallback<unknown>
|
|
29416
|
+
);
|
|
29417
|
+
} else {
|
|
29418
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaSiteSearchEngine>(
|
|
29419
|
+
parameters
|
|
29420
|
+
);
|
|
29421
|
+
}
|
|
29422
|
+
}
|
|
29423
|
+
|
|
29424
|
+
/**
|
|
29425
|
+
* Lists all the DataStores associated with the project.
|
|
28673
29426
|
* @example
|
|
28674
29427
|
* ```js
|
|
28675
29428
|
* // Before running the sample:
|
|
@@ -29369,6 +30122,165 @@ export namespace discoveryengine_v1alpha {
|
|
|
29369
30122
|
}
|
|
29370
30123
|
}
|
|
29371
30124
|
|
|
30125
|
+
/**
|
|
30126
|
+
* Sets the IAM access control policy for a DataStore. A `NOT_FOUND` error is returned if the resource does not exist. **Important:** When setting a policy directly on a DataStore resource, the only recommended roles in the bindings are: `roles/discoveryengine.admin` `roles/discoveryengine.agentspaceAdmin` `roles/discoveryengine.viewer` `roles/discoveryengine.agentspaceViewer` `roles/discoveryengine.user` `roles/discoveryengine.agentspaceUser` Attempting to grant any other role will result in a warning in logging.
|
|
30127
|
+
* @example
|
|
30128
|
+
* ```js
|
|
30129
|
+
* // Before running the sample:
|
|
30130
|
+
* // - Enable the API at:
|
|
30131
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
30132
|
+
* // - Login into gcloud by running:
|
|
30133
|
+
* // ```sh
|
|
30134
|
+
* // $ gcloud auth application-default login
|
|
30135
|
+
* // ```
|
|
30136
|
+
* // - Install the npm module by running:
|
|
30137
|
+
* // ```sh
|
|
30138
|
+
* // $ npm install googleapis
|
|
30139
|
+
* // ```
|
|
30140
|
+
*
|
|
30141
|
+
* const {google} = require('googleapis');
|
|
30142
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
30143
|
+
*
|
|
30144
|
+
* async function main() {
|
|
30145
|
+
* const auth = new google.auth.GoogleAuth({
|
|
30146
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
30147
|
+
* scopes: [
|
|
30148
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
30149
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
30150
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
30151
|
+
* ],
|
|
30152
|
+
* });
|
|
30153
|
+
*
|
|
30154
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
30155
|
+
* const authClient = await auth.getClient();
|
|
30156
|
+
* google.options({auth: authClient});
|
|
30157
|
+
*
|
|
30158
|
+
* // Do the magic
|
|
30159
|
+
* const res =
|
|
30160
|
+
* await discoveryengine.projects.locations.collections.dataStores.setIamPolicy(
|
|
30161
|
+
* {
|
|
30162
|
+
* // REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
30163
|
+
* resource:
|
|
30164
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/dataStores/my-dataStore',
|
|
30165
|
+
*
|
|
30166
|
+
* // Request body metadata
|
|
30167
|
+
* requestBody: {
|
|
30168
|
+
* // request body parameters
|
|
30169
|
+
* // {
|
|
30170
|
+
* // "policy": {}
|
|
30171
|
+
* // }
|
|
30172
|
+
* },
|
|
30173
|
+
* },
|
|
30174
|
+
* );
|
|
30175
|
+
* console.log(res.data);
|
|
30176
|
+
*
|
|
30177
|
+
* // Example response
|
|
30178
|
+
* // {
|
|
30179
|
+
* // "bindings": [],
|
|
30180
|
+
* // "etag": "my_etag",
|
|
30181
|
+
* // "version": 0
|
|
30182
|
+
* // }
|
|
30183
|
+
* }
|
|
30184
|
+
*
|
|
30185
|
+
* main().catch(e => {
|
|
30186
|
+
* console.error(e);
|
|
30187
|
+
* throw e;
|
|
30188
|
+
* });
|
|
30189
|
+
*
|
|
30190
|
+
* ```
|
|
30191
|
+
*
|
|
30192
|
+
* @param params - Parameters for request
|
|
30193
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
30194
|
+
* @param callback - Optional callback that handles the response.
|
|
30195
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
30196
|
+
*/
|
|
30197
|
+
setIamPolicy(
|
|
30198
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy,
|
|
30199
|
+
options: StreamMethodOptions
|
|
30200
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
30201
|
+
setIamPolicy(
|
|
30202
|
+
params?: Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy,
|
|
30203
|
+
options?: MethodOptions
|
|
30204
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>;
|
|
30205
|
+
setIamPolicy(
|
|
30206
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy,
|
|
30207
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
30208
|
+
callback: BodyResponseCallback<Readable>
|
|
30209
|
+
): void;
|
|
30210
|
+
setIamPolicy(
|
|
30211
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy,
|
|
30212
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleIamV1Policy>,
|
|
30213
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
30214
|
+
): void;
|
|
30215
|
+
setIamPolicy(
|
|
30216
|
+
params: Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy,
|
|
30217
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
30218
|
+
): void;
|
|
30219
|
+
setIamPolicy(
|
|
30220
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
30221
|
+
): void;
|
|
30222
|
+
setIamPolicy(
|
|
30223
|
+
paramsOrCallback?:
|
|
30224
|
+
| Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy
|
|
30225
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
30226
|
+
| BodyResponseCallback<Readable>,
|
|
30227
|
+
optionsOrCallback?:
|
|
30228
|
+
| MethodOptions
|
|
30229
|
+
| StreamMethodOptions
|
|
30230
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
30231
|
+
| BodyResponseCallback<Readable>,
|
|
30232
|
+
callback?:
|
|
30233
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
30234
|
+
| BodyResponseCallback<Readable>
|
|
30235
|
+
):
|
|
30236
|
+
| void
|
|
30237
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>
|
|
30238
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
30239
|
+
let params = (paramsOrCallback ||
|
|
30240
|
+
{}) as Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy;
|
|
30241
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
30242
|
+
|
|
30243
|
+
if (typeof paramsOrCallback === 'function') {
|
|
30244
|
+
callback = paramsOrCallback;
|
|
30245
|
+
params =
|
|
30246
|
+
{} as Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy;
|
|
30247
|
+
options = {};
|
|
30248
|
+
}
|
|
30249
|
+
|
|
30250
|
+
if (typeof optionsOrCallback === 'function') {
|
|
30251
|
+
callback = optionsOrCallback;
|
|
30252
|
+
options = {};
|
|
30253
|
+
}
|
|
30254
|
+
|
|
30255
|
+
const rootUrl =
|
|
30256
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
30257
|
+
const parameters = {
|
|
30258
|
+
options: Object.assign(
|
|
30259
|
+
{
|
|
30260
|
+
url: (rootUrl + '/v1alpha/{+resource}:setIamPolicy').replace(
|
|
30261
|
+
/([^:]\/)\/+/g,
|
|
30262
|
+
'$1'
|
|
30263
|
+
),
|
|
30264
|
+
method: 'POST',
|
|
30265
|
+
apiVersion: '',
|
|
30266
|
+
},
|
|
30267
|
+
options
|
|
30268
|
+
),
|
|
30269
|
+
params,
|
|
30270
|
+
requiredParams: ['resource'],
|
|
30271
|
+
pathParams: ['resource'],
|
|
30272
|
+
context: this.context,
|
|
30273
|
+
};
|
|
30274
|
+
if (callback) {
|
|
30275
|
+
createAPIRequest<Schema$GoogleIamV1Policy>(
|
|
30276
|
+
parameters,
|
|
30277
|
+
callback as BodyResponseCallback<unknown>
|
|
30278
|
+
);
|
|
30279
|
+
} else {
|
|
30280
|
+
return createAPIRequest<Schema$GoogleIamV1Policy>(parameters);
|
|
30281
|
+
}
|
|
30282
|
+
}
|
|
30283
|
+
|
|
29372
30284
|
/**
|
|
29373
30285
|
* Trains a custom model.
|
|
29374
30286
|
* @example
|
|
@@ -29988,6 +30900,16 @@ export namespace discoveryengine_v1alpha {
|
|
|
29988
30900
|
*/
|
|
29989
30901
|
name?: string;
|
|
29990
30902
|
}
|
|
30903
|
+
export interface Params$Resource$Projects$Locations$Collections$Datastores$Getiampolicy extends StandardParameters {
|
|
30904
|
+
/**
|
|
30905
|
+
* Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
|
|
30906
|
+
*/
|
|
30907
|
+
'options.requestedPolicyVersion'?: number;
|
|
30908
|
+
/**
|
|
30909
|
+
* REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
30910
|
+
*/
|
|
30911
|
+
resource?: string;
|
|
30912
|
+
}
|
|
29991
30913
|
export interface Params$Resource$Projects$Locations$Collections$Datastores$Getsitesearchengine extends StandardParameters {
|
|
29992
30914
|
/**
|
|
29993
30915
|
* Required. Resource name of SiteSearchEngine, such as `projects/{project\}/locations/{location\}/collections/{collection\}/dataStores/{data_store\}/siteSearchEngine`. If the caller does not have permission to access the [SiteSearchEngine], regardless of whether or not it exists, a PERMISSION_DENIED error is returned.
|
|
@@ -30053,6 +30975,17 @@ export namespace discoveryengine_v1alpha {
|
|
|
30053
30975
|
*/
|
|
30054
30976
|
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaReplacePatientFilterRequest;
|
|
30055
30977
|
}
|
|
30978
|
+
export interface Params$Resource$Projects$Locations$Collections$Datastores$Setiampolicy extends StandardParameters {
|
|
30979
|
+
/**
|
|
30980
|
+
* REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
30981
|
+
*/
|
|
30982
|
+
resource?: string;
|
|
30983
|
+
|
|
30984
|
+
/**
|
|
30985
|
+
* Request body metadata
|
|
30986
|
+
*/
|
|
30987
|
+
requestBody?: Schema$GoogleIamV1SetIamPolicyRequest;
|
|
30988
|
+
}
|
|
30056
30989
|
export interface Params$Resource$Projects$Locations$Collections$Datastores$Traincustommodel extends StandardParameters {
|
|
30057
30990
|
/**
|
|
30058
30991
|
* Required. The resource name of the Data Store, such as `projects/x/locations/global/collections/default_collection/dataStores/default_data_store`. This field is used to identify the data store where to train the models.
|
|
@@ -49605,6 +50538,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
49605
50538
|
* // request body parameters
|
|
49606
50539
|
* // {
|
|
49607
50540
|
* // "actionSpec": {},
|
|
50541
|
+
* // "agentsSpec": {},
|
|
49608
50542
|
* // "generationSpec": {},
|
|
49609
50543
|
* // "query": {},
|
|
49610
50544
|
* // "session": "my_session",
|
|
@@ -62506,6 +63440,156 @@ export namespace discoveryengine_v1alpha {
|
|
|
62506
63440
|
}
|
|
62507
63441
|
}
|
|
62508
63442
|
|
|
63443
|
+
/**
|
|
63444
|
+
* Gets the IAM access control policy for a DataStore. A `NOT_FOUND` error is returned if the resource does not exist. An empty policy is returned if the resource exists but does not have a policy set on it.
|
|
63445
|
+
* @example
|
|
63446
|
+
* ```js
|
|
63447
|
+
* // Before running the sample:
|
|
63448
|
+
* // - Enable the API at:
|
|
63449
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
63450
|
+
* // - Login into gcloud by running:
|
|
63451
|
+
* // ```sh
|
|
63452
|
+
* // $ gcloud auth application-default login
|
|
63453
|
+
* // ```
|
|
63454
|
+
* // - Install the npm module by running:
|
|
63455
|
+
* // ```sh
|
|
63456
|
+
* // $ npm install googleapis
|
|
63457
|
+
* // ```
|
|
63458
|
+
*
|
|
63459
|
+
* const {google} = require('googleapis');
|
|
63460
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
63461
|
+
*
|
|
63462
|
+
* async function main() {
|
|
63463
|
+
* const auth = new google.auth.GoogleAuth({
|
|
63464
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
63465
|
+
* scopes: [
|
|
63466
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
63467
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
63468
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
63469
|
+
* ],
|
|
63470
|
+
* });
|
|
63471
|
+
*
|
|
63472
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
63473
|
+
* const authClient = await auth.getClient();
|
|
63474
|
+
* google.options({auth: authClient});
|
|
63475
|
+
*
|
|
63476
|
+
* // Do the magic
|
|
63477
|
+
* const res = await discoveryengine.projects.locations.dataStores.getIamPolicy({
|
|
63478
|
+
* // Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
|
|
63479
|
+
* 'options.requestedPolicyVersion': 'placeholder-value',
|
|
63480
|
+
* // REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
63481
|
+
* resource:
|
|
63482
|
+
* 'projects/my-project/locations/my-location/dataStores/my-dataStore',
|
|
63483
|
+
* });
|
|
63484
|
+
* console.log(res.data);
|
|
63485
|
+
*
|
|
63486
|
+
* // Example response
|
|
63487
|
+
* // {
|
|
63488
|
+
* // "bindings": [],
|
|
63489
|
+
* // "etag": "my_etag",
|
|
63490
|
+
* // "version": 0
|
|
63491
|
+
* // }
|
|
63492
|
+
* }
|
|
63493
|
+
*
|
|
63494
|
+
* main().catch(e => {
|
|
63495
|
+
* console.error(e);
|
|
63496
|
+
* throw e;
|
|
63497
|
+
* });
|
|
63498
|
+
*
|
|
63499
|
+
* ```
|
|
63500
|
+
*
|
|
63501
|
+
* @param params - Parameters for request
|
|
63502
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
63503
|
+
* @param callback - Optional callback that handles the response.
|
|
63504
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
63505
|
+
*/
|
|
63506
|
+
getIamPolicy(
|
|
63507
|
+
params: Params$Resource$Projects$Locations$Datastores$Getiampolicy,
|
|
63508
|
+
options: StreamMethodOptions
|
|
63509
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
63510
|
+
getIamPolicy(
|
|
63511
|
+
params?: Params$Resource$Projects$Locations$Datastores$Getiampolicy,
|
|
63512
|
+
options?: MethodOptions
|
|
63513
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>;
|
|
63514
|
+
getIamPolicy(
|
|
63515
|
+
params: Params$Resource$Projects$Locations$Datastores$Getiampolicy,
|
|
63516
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
63517
|
+
callback: BodyResponseCallback<Readable>
|
|
63518
|
+
): void;
|
|
63519
|
+
getIamPolicy(
|
|
63520
|
+
params: Params$Resource$Projects$Locations$Datastores$Getiampolicy,
|
|
63521
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleIamV1Policy>,
|
|
63522
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63523
|
+
): void;
|
|
63524
|
+
getIamPolicy(
|
|
63525
|
+
params: Params$Resource$Projects$Locations$Datastores$Getiampolicy,
|
|
63526
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63527
|
+
): void;
|
|
63528
|
+
getIamPolicy(
|
|
63529
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63530
|
+
): void;
|
|
63531
|
+
getIamPolicy(
|
|
63532
|
+
paramsOrCallback?:
|
|
63533
|
+
| Params$Resource$Projects$Locations$Datastores$Getiampolicy
|
|
63534
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63535
|
+
| BodyResponseCallback<Readable>,
|
|
63536
|
+
optionsOrCallback?:
|
|
63537
|
+
| MethodOptions
|
|
63538
|
+
| StreamMethodOptions
|
|
63539
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63540
|
+
| BodyResponseCallback<Readable>,
|
|
63541
|
+
callback?:
|
|
63542
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63543
|
+
| BodyResponseCallback<Readable>
|
|
63544
|
+
):
|
|
63545
|
+
| void
|
|
63546
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>
|
|
63547
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
63548
|
+
let params = (paramsOrCallback ||
|
|
63549
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Getiampolicy;
|
|
63550
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
63551
|
+
|
|
63552
|
+
if (typeof paramsOrCallback === 'function') {
|
|
63553
|
+
callback = paramsOrCallback;
|
|
63554
|
+
params =
|
|
63555
|
+
{} as Params$Resource$Projects$Locations$Datastores$Getiampolicy;
|
|
63556
|
+
options = {};
|
|
63557
|
+
}
|
|
63558
|
+
|
|
63559
|
+
if (typeof optionsOrCallback === 'function') {
|
|
63560
|
+
callback = optionsOrCallback;
|
|
63561
|
+
options = {};
|
|
63562
|
+
}
|
|
63563
|
+
|
|
63564
|
+
const rootUrl =
|
|
63565
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
63566
|
+
const parameters = {
|
|
63567
|
+
options: Object.assign(
|
|
63568
|
+
{
|
|
63569
|
+
url: (rootUrl + '/v1alpha/{+resource}:getIamPolicy').replace(
|
|
63570
|
+
/([^:]\/)\/+/g,
|
|
63571
|
+
'$1'
|
|
63572
|
+
),
|
|
63573
|
+
method: 'GET',
|
|
63574
|
+
apiVersion: '',
|
|
63575
|
+
},
|
|
63576
|
+
options
|
|
63577
|
+
),
|
|
63578
|
+
params,
|
|
63579
|
+
requiredParams: ['resource'],
|
|
63580
|
+
pathParams: ['resource'],
|
|
63581
|
+
context: this.context,
|
|
63582
|
+
};
|
|
63583
|
+
if (callback) {
|
|
63584
|
+
createAPIRequest<Schema$GoogleIamV1Policy>(
|
|
63585
|
+
parameters,
|
|
63586
|
+
callback as BodyResponseCallback<unknown>
|
|
63587
|
+
);
|
|
63588
|
+
} else {
|
|
63589
|
+
return createAPIRequest<Schema$GoogleIamV1Policy>(parameters);
|
|
63590
|
+
}
|
|
63591
|
+
}
|
|
63592
|
+
|
|
62509
63593
|
/**
|
|
62510
63594
|
* Gets the SiteSearchEngine.
|
|
62511
63595
|
* @example
|
|
@@ -63063,190 +64147,346 @@ export namespace discoveryengine_v1alpha {
|
|
|
63063
64147
|
* google.options({auth: authClient});
|
|
63064
64148
|
*
|
|
63065
64149
|
* // Do the magic
|
|
63066
|
-
* const res =
|
|
63067
|
-
* await discoveryengine.projects.locations.dataStores.removePatientFilter({
|
|
63068
|
-
* // Required. Full resource name of DataStore, such as `projects/{project\}/locations/{location\}/collections/{collection_id\}/dataStores/{data_store_id\}`. If the caller does not have permission to access the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataStore does not exist, a NOT_FOUND error is returned. If the requested DataStore does not have a patient filter, a NOT_FOUND error will be returned
|
|
63069
|
-
* dataStore:
|
|
63070
|
-
* 'projects/my-project/locations/my-location/dataStores/my-dataStore',
|
|
63071
|
-
*
|
|
63072
|
-
* // Request body metadata
|
|
63073
|
-
* requestBody: {
|
|
63074
|
-
* // request body parameters
|
|
63075
|
-
* // {
|
|
63076
|
-
* // "dataStore": "my_dataStore",
|
|
63077
|
-
* // "filterGroups": []
|
|
63078
|
-
* // }
|
|
63079
|
-
* },
|
|
63080
|
-
* });
|
|
63081
|
-
* console.log(res.data);
|
|
63082
|
-
*
|
|
63083
|
-
* // Example response
|
|
63084
|
-
* // {
|
|
63085
|
-
* // "done": false,
|
|
63086
|
-
* // "error": {},
|
|
63087
|
-
* // "metadata": {},
|
|
63088
|
-
* // "name": "my_name",
|
|
63089
|
-
* // "response": {}
|
|
63090
|
-
* // }
|
|
63091
|
-
* }
|
|
63092
|
-
*
|
|
63093
|
-
* main().catch(e => {
|
|
63094
|
-
* console.error(e);
|
|
63095
|
-
* throw e;
|
|
63096
|
-
* });
|
|
63097
|
-
*
|
|
63098
|
-
* ```
|
|
63099
|
-
*
|
|
63100
|
-
* @param params - Parameters for request
|
|
63101
|
-
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
63102
|
-
* @param callback - Optional callback that handles the response.
|
|
63103
|
-
* @returns A promise if used with async/await, or void if used with a callback.
|
|
63104
|
-
*/
|
|
63105
|
-
removePatientFilter(
|
|
63106
|
-
params: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
63107
|
-
options: StreamMethodOptions
|
|
63108
|
-
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
63109
|
-
removePatientFilter(
|
|
63110
|
-
params?: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
63111
|
-
options?: MethodOptions
|
|
63112
|
-
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>;
|
|
63113
|
-
removePatientFilter(
|
|
63114
|
-
params: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
63115
|
-
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
63116
|
-
callback: BodyResponseCallback<Readable>
|
|
63117
|
-
): void;
|
|
63118
|
-
removePatientFilter(
|
|
63119
|
-
params: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
63120
|
-
options:
|
|
63121
|
-
MethodOptions | BodyResponseCallback<Schema$GoogleLongrunningOperation>,
|
|
63122
|
-
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
63123
|
-
): void;
|
|
63124
|
-
removePatientFilter(
|
|
63125
|
-
params: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
63126
|
-
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
63127
|
-
): void;
|
|
63128
|
-
removePatientFilter(
|
|
63129
|
-
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
63130
|
-
): void;
|
|
63131
|
-
removePatientFilter(
|
|
63132
|
-
paramsOrCallback?:
|
|
63133
|
-
| Params$Resource$Projects$Locations$Datastores$Removepatientfilter
|
|
63134
|
-
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
63135
|
-
| BodyResponseCallback<Readable>,
|
|
63136
|
-
optionsOrCallback?:
|
|
63137
|
-
| MethodOptions
|
|
63138
|
-
| StreamMethodOptions
|
|
63139
|
-
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
63140
|
-
| BodyResponseCallback<Readable>,
|
|
63141
|
-
callback?:
|
|
63142
|
-
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
63143
|
-
| BodyResponseCallback<Readable>
|
|
63144
|
-
):
|
|
63145
|
-
| void
|
|
63146
|
-
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>
|
|
63147
|
-
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
63148
|
-
let params = (paramsOrCallback ||
|
|
63149
|
-
{}) as Params$Resource$Projects$Locations$Datastores$Removepatientfilter;
|
|
63150
|
-
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
63151
|
-
|
|
63152
|
-
if (typeof paramsOrCallback === 'function') {
|
|
63153
|
-
callback = paramsOrCallback;
|
|
63154
|
-
params =
|
|
63155
|
-
{} as Params$Resource$Projects$Locations$Datastores$Removepatientfilter;
|
|
63156
|
-
options = {};
|
|
63157
|
-
}
|
|
63158
|
-
|
|
63159
|
-
if (typeof optionsOrCallback === 'function') {
|
|
63160
|
-
callback = optionsOrCallback;
|
|
63161
|
-
options = {};
|
|
63162
|
-
}
|
|
63163
|
-
|
|
63164
|
-
const rootUrl =
|
|
63165
|
-
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
63166
|
-
const parameters = {
|
|
63167
|
-
options: Object.assign(
|
|
63168
|
-
{
|
|
63169
|
-
url: (
|
|
63170
|
-
rootUrl + '/v1alpha/{+dataStore}:removePatientFilter'
|
|
63171
|
-
).replace(/([^:]\/)\/+/g, '$1'),
|
|
63172
|
-
method: 'POST',
|
|
63173
|
-
apiVersion: '',
|
|
63174
|
-
},
|
|
63175
|
-
options
|
|
63176
|
-
),
|
|
63177
|
-
params,
|
|
63178
|
-
requiredParams: ['dataStore'],
|
|
63179
|
-
pathParams: ['dataStore'],
|
|
63180
|
-
context: this.context,
|
|
63181
|
-
};
|
|
63182
|
-
if (callback) {
|
|
63183
|
-
createAPIRequest<Schema$GoogleLongrunningOperation>(
|
|
63184
|
-
parameters,
|
|
63185
|
-
callback as BodyResponseCallback<unknown>
|
|
63186
|
-
);
|
|
63187
|
-
} else {
|
|
63188
|
-
return createAPIRequest<Schema$GoogleLongrunningOperation>(parameters);
|
|
63189
|
-
}
|
|
63190
|
-
}
|
|
63191
|
-
|
|
63192
|
-
/**
|
|
63193
|
-
* Replaces the patient filter for the data store. This method is essentially a combination of DeletePatientFilters and AddPatientFilter. Patient filters are empty by default when a data store is created, and are stored in a separate table. The data store must first be created, and must be a healthcare data store. This method will fail if the data store does not have a patient filter. The filter group must be a FHIR resource name of type Group, and the new filter will be constructed from the direct members of the group which are Patient resources.
|
|
63194
|
-
* @example
|
|
63195
|
-
* ```js
|
|
63196
|
-
* // Before running the sample:
|
|
63197
|
-
* // - Enable the API at:
|
|
63198
|
-
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
63199
|
-
* // - Login into gcloud by running:
|
|
63200
|
-
* // ```sh
|
|
63201
|
-
* // $ gcloud auth application-default login
|
|
63202
|
-
* // ```
|
|
63203
|
-
* // - Install the npm module by running:
|
|
63204
|
-
* // ```sh
|
|
63205
|
-
* // $ npm install googleapis
|
|
63206
|
-
* // ```
|
|
63207
|
-
*
|
|
63208
|
-
* const {google} = require('googleapis');
|
|
63209
|
-
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
64150
|
+
* const res =
|
|
64151
|
+
* await discoveryengine.projects.locations.dataStores.removePatientFilter({
|
|
64152
|
+
* // Required. Full resource name of DataStore, such as `projects/{project\}/locations/{location\}/collections/{collection_id\}/dataStores/{data_store_id\}`. If the caller does not have permission to access the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataStore does not exist, a NOT_FOUND error is returned. If the requested DataStore does not have a patient filter, a NOT_FOUND error will be returned
|
|
64153
|
+
* dataStore:
|
|
64154
|
+
* 'projects/my-project/locations/my-location/dataStores/my-dataStore',
|
|
64155
|
+
*
|
|
64156
|
+
* // Request body metadata
|
|
64157
|
+
* requestBody: {
|
|
64158
|
+
* // request body parameters
|
|
64159
|
+
* // {
|
|
64160
|
+
* // "dataStore": "my_dataStore",
|
|
64161
|
+
* // "filterGroups": []
|
|
64162
|
+
* // }
|
|
64163
|
+
* },
|
|
64164
|
+
* });
|
|
64165
|
+
* console.log(res.data);
|
|
64166
|
+
*
|
|
64167
|
+
* // Example response
|
|
64168
|
+
* // {
|
|
64169
|
+
* // "done": false,
|
|
64170
|
+
* // "error": {},
|
|
64171
|
+
* // "metadata": {},
|
|
64172
|
+
* // "name": "my_name",
|
|
64173
|
+
* // "response": {}
|
|
64174
|
+
* // }
|
|
64175
|
+
* }
|
|
64176
|
+
*
|
|
64177
|
+
* main().catch(e => {
|
|
64178
|
+
* console.error(e);
|
|
64179
|
+
* throw e;
|
|
64180
|
+
* });
|
|
64181
|
+
*
|
|
64182
|
+
* ```
|
|
64183
|
+
*
|
|
64184
|
+
* @param params - Parameters for request
|
|
64185
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
64186
|
+
* @param callback - Optional callback that handles the response.
|
|
64187
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
64188
|
+
*/
|
|
64189
|
+
removePatientFilter(
|
|
64190
|
+
params: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
64191
|
+
options: StreamMethodOptions
|
|
64192
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
64193
|
+
removePatientFilter(
|
|
64194
|
+
params?: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
64195
|
+
options?: MethodOptions
|
|
64196
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>;
|
|
64197
|
+
removePatientFilter(
|
|
64198
|
+
params: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
64199
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
64200
|
+
callback: BodyResponseCallback<Readable>
|
|
64201
|
+
): void;
|
|
64202
|
+
removePatientFilter(
|
|
64203
|
+
params: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
64204
|
+
options:
|
|
64205
|
+
MethodOptions | BodyResponseCallback<Schema$GoogleLongrunningOperation>,
|
|
64206
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64207
|
+
): void;
|
|
64208
|
+
removePatientFilter(
|
|
64209
|
+
params: Params$Resource$Projects$Locations$Datastores$Removepatientfilter,
|
|
64210
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64211
|
+
): void;
|
|
64212
|
+
removePatientFilter(
|
|
64213
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64214
|
+
): void;
|
|
64215
|
+
removePatientFilter(
|
|
64216
|
+
paramsOrCallback?:
|
|
64217
|
+
| Params$Resource$Projects$Locations$Datastores$Removepatientfilter
|
|
64218
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64219
|
+
| BodyResponseCallback<Readable>,
|
|
64220
|
+
optionsOrCallback?:
|
|
64221
|
+
| MethodOptions
|
|
64222
|
+
| StreamMethodOptions
|
|
64223
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64224
|
+
| BodyResponseCallback<Readable>,
|
|
64225
|
+
callback?:
|
|
64226
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64227
|
+
| BodyResponseCallback<Readable>
|
|
64228
|
+
):
|
|
64229
|
+
| void
|
|
64230
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>
|
|
64231
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
64232
|
+
let params = (paramsOrCallback ||
|
|
64233
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Removepatientfilter;
|
|
64234
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
64235
|
+
|
|
64236
|
+
if (typeof paramsOrCallback === 'function') {
|
|
64237
|
+
callback = paramsOrCallback;
|
|
64238
|
+
params =
|
|
64239
|
+
{} as Params$Resource$Projects$Locations$Datastores$Removepatientfilter;
|
|
64240
|
+
options = {};
|
|
64241
|
+
}
|
|
64242
|
+
|
|
64243
|
+
if (typeof optionsOrCallback === 'function') {
|
|
64244
|
+
callback = optionsOrCallback;
|
|
64245
|
+
options = {};
|
|
64246
|
+
}
|
|
64247
|
+
|
|
64248
|
+
const rootUrl =
|
|
64249
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
64250
|
+
const parameters = {
|
|
64251
|
+
options: Object.assign(
|
|
64252
|
+
{
|
|
64253
|
+
url: (
|
|
64254
|
+
rootUrl + '/v1alpha/{+dataStore}:removePatientFilter'
|
|
64255
|
+
).replace(/([^:]\/)\/+/g, '$1'),
|
|
64256
|
+
method: 'POST',
|
|
64257
|
+
apiVersion: '',
|
|
64258
|
+
},
|
|
64259
|
+
options
|
|
64260
|
+
),
|
|
64261
|
+
params,
|
|
64262
|
+
requiredParams: ['dataStore'],
|
|
64263
|
+
pathParams: ['dataStore'],
|
|
64264
|
+
context: this.context,
|
|
64265
|
+
};
|
|
64266
|
+
if (callback) {
|
|
64267
|
+
createAPIRequest<Schema$GoogleLongrunningOperation>(
|
|
64268
|
+
parameters,
|
|
64269
|
+
callback as BodyResponseCallback<unknown>
|
|
64270
|
+
);
|
|
64271
|
+
} else {
|
|
64272
|
+
return createAPIRequest<Schema$GoogleLongrunningOperation>(parameters);
|
|
64273
|
+
}
|
|
64274
|
+
}
|
|
64275
|
+
|
|
64276
|
+
/**
|
|
64277
|
+
* Replaces the patient filter for the data store. This method is essentially a combination of DeletePatientFilters and AddPatientFilter. Patient filters are empty by default when a data store is created, and are stored in a separate table. The data store must first be created, and must be a healthcare data store. This method will fail if the data store does not have a patient filter. The filter group must be a FHIR resource name of type Group, and the new filter will be constructed from the direct members of the group which are Patient resources.
|
|
64278
|
+
* @example
|
|
64279
|
+
* ```js
|
|
64280
|
+
* // Before running the sample:
|
|
64281
|
+
* // - Enable the API at:
|
|
64282
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
64283
|
+
* // - Login into gcloud by running:
|
|
64284
|
+
* // ```sh
|
|
64285
|
+
* // $ gcloud auth application-default login
|
|
64286
|
+
* // ```
|
|
64287
|
+
* // - Install the npm module by running:
|
|
64288
|
+
* // ```sh
|
|
64289
|
+
* // $ npm install googleapis
|
|
64290
|
+
* // ```
|
|
64291
|
+
*
|
|
64292
|
+
* const {google} = require('googleapis');
|
|
64293
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
64294
|
+
*
|
|
64295
|
+
* async function main() {
|
|
64296
|
+
* const auth = new google.auth.GoogleAuth({
|
|
64297
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
64298
|
+
* scopes: [
|
|
64299
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
64300
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
64301
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
64302
|
+
* ],
|
|
64303
|
+
* });
|
|
64304
|
+
*
|
|
64305
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
64306
|
+
* const authClient = await auth.getClient();
|
|
64307
|
+
* google.options({auth: authClient});
|
|
64308
|
+
*
|
|
64309
|
+
* // Do the magic
|
|
64310
|
+
* const res =
|
|
64311
|
+
* await discoveryengine.projects.locations.dataStores.replacePatientFilter({
|
|
64312
|
+
* // Required. Full resource name of DataStore, such as `projects/{project\}/locations/{location\}/collections/{collection_id\}/dataStores/{data_store_id\}`. If the caller does not have permission to access the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataStore does not exist, a NOT_FOUND error is returned. If the requested DataStore already has a patient filter, an ALREADY_EXISTS error will be returned.
|
|
64313
|
+
* dataStore:
|
|
64314
|
+
* 'projects/my-project/locations/my-location/dataStores/my-dataStore',
|
|
64315
|
+
*
|
|
64316
|
+
* // Request body metadata
|
|
64317
|
+
* requestBody: {
|
|
64318
|
+
* // request body parameters
|
|
64319
|
+
* // {
|
|
64320
|
+
* // "dataStore": "my_dataStore",
|
|
64321
|
+
* // "filterGroups": []
|
|
64322
|
+
* // }
|
|
64323
|
+
* },
|
|
64324
|
+
* });
|
|
64325
|
+
* console.log(res.data);
|
|
64326
|
+
*
|
|
64327
|
+
* // Example response
|
|
64328
|
+
* // {
|
|
64329
|
+
* // "done": false,
|
|
64330
|
+
* // "error": {},
|
|
64331
|
+
* // "metadata": {},
|
|
64332
|
+
* // "name": "my_name",
|
|
64333
|
+
* // "response": {}
|
|
64334
|
+
* // }
|
|
64335
|
+
* }
|
|
64336
|
+
*
|
|
64337
|
+
* main().catch(e => {
|
|
64338
|
+
* console.error(e);
|
|
64339
|
+
* throw e;
|
|
64340
|
+
* });
|
|
64341
|
+
*
|
|
64342
|
+
* ```
|
|
64343
|
+
*
|
|
64344
|
+
* @param params - Parameters for request
|
|
64345
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
64346
|
+
* @param callback - Optional callback that handles the response.
|
|
64347
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
64348
|
+
*/
|
|
64349
|
+
replacePatientFilter(
|
|
64350
|
+
params: Params$Resource$Projects$Locations$Datastores$Replacepatientfilter,
|
|
64351
|
+
options: StreamMethodOptions
|
|
64352
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
64353
|
+
replacePatientFilter(
|
|
64354
|
+
params?: Params$Resource$Projects$Locations$Datastores$Replacepatientfilter,
|
|
64355
|
+
options?: MethodOptions
|
|
64356
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>;
|
|
64357
|
+
replacePatientFilter(
|
|
64358
|
+
params: Params$Resource$Projects$Locations$Datastores$Replacepatientfilter,
|
|
64359
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
64360
|
+
callback: BodyResponseCallback<Readable>
|
|
64361
|
+
): void;
|
|
64362
|
+
replacePatientFilter(
|
|
64363
|
+
params: Params$Resource$Projects$Locations$Datastores$Replacepatientfilter,
|
|
64364
|
+
options:
|
|
64365
|
+
MethodOptions | BodyResponseCallback<Schema$GoogleLongrunningOperation>,
|
|
64366
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64367
|
+
): void;
|
|
64368
|
+
replacePatientFilter(
|
|
64369
|
+
params: Params$Resource$Projects$Locations$Datastores$Replacepatientfilter,
|
|
64370
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64371
|
+
): void;
|
|
64372
|
+
replacePatientFilter(
|
|
64373
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64374
|
+
): void;
|
|
64375
|
+
replacePatientFilter(
|
|
64376
|
+
paramsOrCallback?:
|
|
64377
|
+
| Params$Resource$Projects$Locations$Datastores$Replacepatientfilter
|
|
64378
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64379
|
+
| BodyResponseCallback<Readable>,
|
|
64380
|
+
optionsOrCallback?:
|
|
64381
|
+
| MethodOptions
|
|
64382
|
+
| StreamMethodOptions
|
|
64383
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64384
|
+
| BodyResponseCallback<Readable>,
|
|
64385
|
+
callback?:
|
|
64386
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64387
|
+
| BodyResponseCallback<Readable>
|
|
64388
|
+
):
|
|
64389
|
+
| void
|
|
64390
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>
|
|
64391
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
64392
|
+
let params = (paramsOrCallback ||
|
|
64393
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Replacepatientfilter;
|
|
64394
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
64395
|
+
|
|
64396
|
+
if (typeof paramsOrCallback === 'function') {
|
|
64397
|
+
callback = paramsOrCallback;
|
|
64398
|
+
params =
|
|
64399
|
+
{} as Params$Resource$Projects$Locations$Datastores$Replacepatientfilter;
|
|
64400
|
+
options = {};
|
|
64401
|
+
}
|
|
64402
|
+
|
|
64403
|
+
if (typeof optionsOrCallback === 'function') {
|
|
64404
|
+
callback = optionsOrCallback;
|
|
64405
|
+
options = {};
|
|
64406
|
+
}
|
|
64407
|
+
|
|
64408
|
+
const rootUrl =
|
|
64409
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
64410
|
+
const parameters = {
|
|
64411
|
+
options: Object.assign(
|
|
64412
|
+
{
|
|
64413
|
+
url: (
|
|
64414
|
+
rootUrl + '/v1alpha/{+dataStore}:replacePatientFilter'
|
|
64415
|
+
).replace(/([^:]\/)\/+/g, '$1'),
|
|
64416
|
+
method: 'POST',
|
|
64417
|
+
apiVersion: '',
|
|
64418
|
+
},
|
|
64419
|
+
options
|
|
64420
|
+
),
|
|
64421
|
+
params,
|
|
64422
|
+
requiredParams: ['dataStore'],
|
|
64423
|
+
pathParams: ['dataStore'],
|
|
64424
|
+
context: this.context,
|
|
64425
|
+
};
|
|
64426
|
+
if (callback) {
|
|
64427
|
+
createAPIRequest<Schema$GoogleLongrunningOperation>(
|
|
64428
|
+
parameters,
|
|
64429
|
+
callback as BodyResponseCallback<unknown>
|
|
64430
|
+
);
|
|
64431
|
+
} else {
|
|
64432
|
+
return createAPIRequest<Schema$GoogleLongrunningOperation>(parameters);
|
|
64433
|
+
}
|
|
64434
|
+
}
|
|
64435
|
+
|
|
64436
|
+
/**
|
|
64437
|
+
* Sets the IAM access control policy for a DataStore. A `NOT_FOUND` error is returned if the resource does not exist. **Important:** When setting a policy directly on a DataStore resource, the only recommended roles in the bindings are: `roles/discoveryengine.admin` `roles/discoveryengine.agentspaceAdmin` `roles/discoveryengine.viewer` `roles/discoveryengine.agentspaceViewer` `roles/discoveryengine.user` `roles/discoveryengine.agentspaceUser` Attempting to grant any other role will result in a warning in logging.
|
|
64438
|
+
* @example
|
|
64439
|
+
* ```js
|
|
64440
|
+
* // Before running the sample:
|
|
64441
|
+
* // - Enable the API at:
|
|
64442
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
64443
|
+
* // - Login into gcloud by running:
|
|
64444
|
+
* // ```sh
|
|
64445
|
+
* // $ gcloud auth application-default login
|
|
64446
|
+
* // ```
|
|
64447
|
+
* // - Install the npm module by running:
|
|
64448
|
+
* // ```sh
|
|
64449
|
+
* // $ npm install googleapis
|
|
64450
|
+
* // ```
|
|
64451
|
+
*
|
|
64452
|
+
* const {google} = require('googleapis');
|
|
64453
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
64454
|
+
*
|
|
64455
|
+
* async function main() {
|
|
64456
|
+
* const auth = new google.auth.GoogleAuth({
|
|
64457
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
64458
|
+
* scopes: [
|
|
64459
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
64460
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
64461
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
64462
|
+
* ],
|
|
64463
|
+
* });
|
|
64464
|
+
*
|
|
64465
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
64466
|
+
* const authClient = await auth.getClient();
|
|
64467
|
+
* google.options({auth: authClient});
|
|
64468
|
+
*
|
|
64469
|
+
* // Do the magic
|
|
64470
|
+
* const res = await discoveryengine.projects.locations.dataStores.setIamPolicy({
|
|
64471
|
+
* // REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
64472
|
+
* resource:
|
|
64473
|
+
* 'projects/my-project/locations/my-location/dataStores/my-dataStore',
|
|
63210
64474
|
*
|
|
63211
|
-
*
|
|
63212
|
-
*
|
|
63213
|
-
*
|
|
63214
|
-
*
|
|
63215
|
-
*
|
|
63216
|
-
*
|
|
63217
|
-
*
|
|
63218
|
-
* ],
|
|
64475
|
+
* // Request body metadata
|
|
64476
|
+
* requestBody: {
|
|
64477
|
+
* // request body parameters
|
|
64478
|
+
* // {
|
|
64479
|
+
* // "policy": {}
|
|
64480
|
+
* // }
|
|
64481
|
+
* },
|
|
63219
64482
|
* });
|
|
63220
|
-
*
|
|
63221
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
63222
|
-
* const authClient = await auth.getClient();
|
|
63223
|
-
* google.options({auth: authClient});
|
|
63224
|
-
*
|
|
63225
|
-
* // Do the magic
|
|
63226
|
-
* const res =
|
|
63227
|
-
* await discoveryengine.projects.locations.dataStores.replacePatientFilter({
|
|
63228
|
-
* // Required. Full resource name of DataStore, such as `projects/{project\}/locations/{location\}/collections/{collection_id\}/dataStores/{data_store_id\}`. If the caller does not have permission to access the DataStore, regardless of whether or not it exists, a PERMISSION_DENIED error is returned. If the requested DataStore does not exist, a NOT_FOUND error is returned. If the requested DataStore already has a patient filter, an ALREADY_EXISTS error will be returned.
|
|
63229
|
-
* dataStore:
|
|
63230
|
-
* 'projects/my-project/locations/my-location/dataStores/my-dataStore',
|
|
63231
|
-
*
|
|
63232
|
-
* // Request body metadata
|
|
63233
|
-
* requestBody: {
|
|
63234
|
-
* // request body parameters
|
|
63235
|
-
* // {
|
|
63236
|
-
* // "dataStore": "my_dataStore",
|
|
63237
|
-
* // "filterGroups": []
|
|
63238
|
-
* // }
|
|
63239
|
-
* },
|
|
63240
|
-
* });
|
|
63241
64483
|
* console.log(res.data);
|
|
63242
64484
|
*
|
|
63243
64485
|
* // Example response
|
|
63244
64486
|
* // {
|
|
63245
|
-
* // "
|
|
63246
|
-
* // "
|
|
63247
|
-
* // "
|
|
63248
|
-
* // "name": "my_name",
|
|
63249
|
-
* // "response": {}
|
|
64487
|
+
* // "bindings": [],
|
|
64488
|
+
* // "etag": "my_etag",
|
|
64489
|
+
* // "version": 0
|
|
63250
64490
|
* // }
|
|
63251
64491
|
* }
|
|
63252
64492
|
*
|
|
@@ -63262,57 +64502,56 @@ export namespace discoveryengine_v1alpha {
|
|
|
63262
64502
|
* @param callback - Optional callback that handles the response.
|
|
63263
64503
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
63264
64504
|
*/
|
|
63265
|
-
|
|
63266
|
-
params: Params$Resource$Projects$Locations$Datastores$
|
|
64505
|
+
setIamPolicy(
|
|
64506
|
+
params: Params$Resource$Projects$Locations$Datastores$Setiampolicy,
|
|
63267
64507
|
options: StreamMethodOptions
|
|
63268
64508
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
63269
|
-
|
|
63270
|
-
params?: Params$Resource$Projects$Locations$Datastores$
|
|
64509
|
+
setIamPolicy(
|
|
64510
|
+
params?: Params$Resource$Projects$Locations$Datastores$Setiampolicy,
|
|
63271
64511
|
options?: MethodOptions
|
|
63272
|
-
): Promise<GaxiosResponseWithHTTP2<Schema$
|
|
63273
|
-
|
|
63274
|
-
params: Params$Resource$Projects$Locations$Datastores$
|
|
64512
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>;
|
|
64513
|
+
setIamPolicy(
|
|
64514
|
+
params: Params$Resource$Projects$Locations$Datastores$Setiampolicy,
|
|
63275
64515
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
63276
64516
|
callback: BodyResponseCallback<Readable>
|
|
63277
64517
|
): void;
|
|
63278
|
-
|
|
63279
|
-
params: Params$Resource$Projects$Locations$Datastores$
|
|
63280
|
-
options:
|
|
63281
|
-
|
|
63282
|
-
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
64518
|
+
setIamPolicy(
|
|
64519
|
+
params: Params$Resource$Projects$Locations$Datastores$Setiampolicy,
|
|
64520
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleIamV1Policy>,
|
|
64521
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63283
64522
|
): void;
|
|
63284
|
-
|
|
63285
|
-
params: Params$Resource$Projects$Locations$Datastores$
|
|
63286
|
-
callback: BodyResponseCallback<Schema$
|
|
64523
|
+
setIamPolicy(
|
|
64524
|
+
params: Params$Resource$Projects$Locations$Datastores$Setiampolicy,
|
|
64525
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63287
64526
|
): void;
|
|
63288
|
-
|
|
63289
|
-
callback: BodyResponseCallback<Schema$
|
|
64527
|
+
setIamPolicy(
|
|
64528
|
+
callback: BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63290
64529
|
): void;
|
|
63291
|
-
|
|
64530
|
+
setIamPolicy(
|
|
63292
64531
|
paramsOrCallback?:
|
|
63293
|
-
| Params$Resource$Projects$Locations$Datastores$
|
|
63294
|
-
| BodyResponseCallback<Schema$
|
|
64532
|
+
| Params$Resource$Projects$Locations$Datastores$Setiampolicy
|
|
64533
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63295
64534
|
| BodyResponseCallback<Readable>,
|
|
63296
64535
|
optionsOrCallback?:
|
|
63297
64536
|
| MethodOptions
|
|
63298
64537
|
| StreamMethodOptions
|
|
63299
|
-
| BodyResponseCallback<Schema$
|
|
64538
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63300
64539
|
| BodyResponseCallback<Readable>,
|
|
63301
64540
|
callback?:
|
|
63302
|
-
| BodyResponseCallback<Schema$
|
|
64541
|
+
| BodyResponseCallback<Schema$GoogleIamV1Policy>
|
|
63303
64542
|
| BodyResponseCallback<Readable>
|
|
63304
64543
|
):
|
|
63305
64544
|
| void
|
|
63306
|
-
| Promise<GaxiosResponseWithHTTP2<Schema$
|
|
64545
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleIamV1Policy>>
|
|
63307
64546
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
63308
64547
|
let params = (paramsOrCallback ||
|
|
63309
|
-
{}) as Params$Resource$Projects$Locations$Datastores$
|
|
64548
|
+
{}) as Params$Resource$Projects$Locations$Datastores$Setiampolicy;
|
|
63310
64549
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
63311
64550
|
|
|
63312
64551
|
if (typeof paramsOrCallback === 'function') {
|
|
63313
64552
|
callback = paramsOrCallback;
|
|
63314
64553
|
params =
|
|
63315
|
-
{} as Params$Resource$Projects$Locations$Datastores$
|
|
64554
|
+
{} as Params$Resource$Projects$Locations$Datastores$Setiampolicy;
|
|
63316
64555
|
options = {};
|
|
63317
64556
|
}
|
|
63318
64557
|
|
|
@@ -63326,26 +64565,27 @@ export namespace discoveryengine_v1alpha {
|
|
|
63326
64565
|
const parameters = {
|
|
63327
64566
|
options: Object.assign(
|
|
63328
64567
|
{
|
|
63329
|
-
url: (
|
|
63330
|
-
|
|
63331
|
-
|
|
64568
|
+
url: (rootUrl + '/v1alpha/{+resource}:setIamPolicy').replace(
|
|
64569
|
+
/([^:]\/)\/+/g,
|
|
64570
|
+
'$1'
|
|
64571
|
+
),
|
|
63332
64572
|
method: 'POST',
|
|
63333
64573
|
apiVersion: '',
|
|
63334
64574
|
},
|
|
63335
64575
|
options
|
|
63336
64576
|
),
|
|
63337
64577
|
params,
|
|
63338
|
-
requiredParams: ['
|
|
63339
|
-
pathParams: ['
|
|
64578
|
+
requiredParams: ['resource'],
|
|
64579
|
+
pathParams: ['resource'],
|
|
63340
64580
|
context: this.context,
|
|
63341
64581
|
};
|
|
63342
64582
|
if (callback) {
|
|
63343
|
-
createAPIRequest<Schema$
|
|
64583
|
+
createAPIRequest<Schema$GoogleIamV1Policy>(
|
|
63344
64584
|
parameters,
|
|
63345
64585
|
callback as BodyResponseCallback<unknown>
|
|
63346
64586
|
);
|
|
63347
64587
|
} else {
|
|
63348
|
-
return createAPIRequest<Schema$
|
|
64588
|
+
return createAPIRequest<Schema$GoogleIamV1Policy>(parameters);
|
|
63349
64589
|
}
|
|
63350
64590
|
}
|
|
63351
64591
|
|
|
@@ -63801,6 +65041,16 @@ export namespace discoveryengine_v1alpha {
|
|
|
63801
65041
|
*/
|
|
63802
65042
|
name?: string;
|
|
63803
65043
|
}
|
|
65044
|
+
export interface Params$Resource$Projects$Locations$Datastores$Getiampolicy extends StandardParameters {
|
|
65045
|
+
/**
|
|
65046
|
+
* Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
|
|
65047
|
+
*/
|
|
65048
|
+
'options.requestedPolicyVersion'?: number;
|
|
65049
|
+
/**
|
|
65050
|
+
* REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
65051
|
+
*/
|
|
65052
|
+
resource?: string;
|
|
65053
|
+
}
|
|
63804
65054
|
export interface Params$Resource$Projects$Locations$Datastores$Getsitesearchengine extends StandardParameters {
|
|
63805
65055
|
/**
|
|
63806
65056
|
* Required. Resource name of SiteSearchEngine, such as `projects/{project\}/locations/{location\}/collections/{collection\}/dataStores/{data_store\}/siteSearchEngine`. If the caller does not have permission to access the [SiteSearchEngine], regardless of whether or not it exists, a PERMISSION_DENIED error is returned.
|
|
@@ -63866,6 +65116,17 @@ export namespace discoveryengine_v1alpha {
|
|
|
63866
65116
|
*/
|
|
63867
65117
|
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaReplacePatientFilterRequest;
|
|
63868
65118
|
}
|
|
65119
|
+
export interface Params$Resource$Projects$Locations$Datastores$Setiampolicy extends StandardParameters {
|
|
65120
|
+
/**
|
|
65121
|
+
* REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.
|
|
65122
|
+
*/
|
|
65123
|
+
resource?: string;
|
|
65124
|
+
|
|
65125
|
+
/**
|
|
65126
|
+
* Request body metadata
|
|
65127
|
+
*/
|
|
65128
|
+
requestBody?: Schema$GoogleIamV1SetIamPolicyRequest;
|
|
65129
|
+
}
|
|
63869
65130
|
export interface Params$Resource$Projects$Locations$Datastores$Updatecompletionconfig extends StandardParameters {
|
|
63870
65131
|
/**
|
|
63871
65132
|
* Required. Immutable. Fully qualified name `projects/x/locations/x/dataStores/x/completionConfig` `projects/x/locations/x/collections/x/dataStores/x/completionConfig` `projects/x/locations/x/collections/x/engines/x/completionConfig`
|