@googleapis/discoveryengine 37.0.0 → 37.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/build/index.js +0 -1
- package/build/index.js.map +1 -1
- package/build/tsconfig.tsbuildinfo +1 -1
- package/build/v1.d.ts +148 -5
- package/build/v1.js.map +1 -1
- package/build/v1alpha.d.ts +1434 -31
- package/build/v1alpha.js +331 -0
- package/build/v1alpha.js.map +1 -1
- package/build/v1beta.d.ts +119 -5
- package/build/v1beta.js.map +1 -1
- package/index.ts +0 -1
- package/package.json +1 -1
- package/tsconfig.build.json +10 -0
- package/v1.ts +144 -5
- package/v1alpha.ts +2447 -262
- package/v1beta.ts +115 -5
package/v1alpha.ts
CHANGED
|
@@ -2403,6 +2403,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
2403
2403
|
* Reasons for not answering the assist call.
|
|
2404
2404
|
*/
|
|
2405
2405
|
assistSkippedReasons?: string[] | null;
|
|
2406
|
+
/**
|
|
2407
|
+
* Output only. Maps an internal connector agent name (the machine identifier embedded in tool names, e.g. `custom_mcp__agent`) to the connector's human-readable display name. Populated at serving time for custom MCP / agent gateway connectors so user-facing surfaces (e.g. the tool-call chip) can show the connector name instead of its internal identifier. Empty when there are no such connectors.
|
|
2408
|
+
*/
|
|
2409
|
+
connectorDisplayNames?: {[key: string]: string} | null;
|
|
2406
2410
|
/**
|
|
2407
2411
|
* Optional. The field contains information about the various policy checks' results like the banned phrases or the Model Armor checks. This field is populated only if the assist call was skipped due to a policy violation.
|
|
2408
2412
|
*/
|
|
@@ -2528,7 +2532,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
2528
2532
|
*/
|
|
2529
2533
|
generationConfig?: Schema$GoogleCloudDiscoveryengineV1alphaAssistantGenerationConfig;
|
|
2530
2534
|
/**
|
|
2531
|
-
* Optional. Indicates whether Knowledge Catalog is enabled for this specific assistant. When enabled, it powers discovery context using organizational data.
|
|
2535
|
+
* Optional. Indicates whether Knowledge Catalog is enabled for this specific assistant. When enabled, it powers discovery context using organizational data. If unspecified, defaults to true.
|
|
2532
2536
|
*/
|
|
2533
2537
|
knowledgeCatalogEnabled?: boolean | null;
|
|
2534
2538
|
/**
|
|
@@ -2902,6 +2906,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
2902
2906
|
* Required. The URI the user is directed to when they need to authorize. Should include everything required for a successful authorization: OAuth ID, extra flags, etc. Example: `https://accounts.google.com/o/oauth2/v2/auth?client_id=OAUTH_ID&scope=https://www.googleapis.com/auth/calendar.events&response_type=code&access_type=offline&prompt=consent` The `redirect_uri` parameter will be overwritten by the Vertex AI Search frontend.
|
|
2903
2907
|
*/
|
|
2904
2908
|
authorizationUri?: string | null;
|
|
2909
|
+
/**
|
|
2910
|
+
* Optional. Whether the OAuth token exchange uses HTTP Basic authentication (`client_secret_basic`) instead of sending the client credentials in the request body (`client_secret_post`). When `true`, the credentials (`client_id:client_secret`) are Base64 encoded and sent in the `Authorization` header. Some OAuth providers (e.g. Splunk) require `client_secret_basic`. When `false` or unset, the default `client_secret_post` is used.
|
|
2911
|
+
*/
|
|
2912
|
+
basicAuthenticationEnabled?: boolean | null;
|
|
2905
2913
|
/**
|
|
2906
2914
|
* Required. The OAuth2 client ID.
|
|
2907
2915
|
*/
|
|
@@ -3894,7 +3902,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
3894
3902
|
*/
|
|
3895
3903
|
selectedPosition?: number | null;
|
|
3896
3904
|
/**
|
|
3897
|
-
* End user selected CompleteQueryResponse.QuerySuggestion.suggestion.
|
|
3905
|
+
* Optional. End user selected CompleteQueryResponse.QuerySuggestion.suggestion.
|
|
3898
3906
|
*/
|
|
3899
3907
|
selectedSuggestion?: string | null;
|
|
3900
3908
|
}
|
|
@@ -4702,7 +4710,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
4702
4710
|
*/
|
|
4703
4711
|
syncMode?: string | null;
|
|
4704
4712
|
/**
|
|
4705
|
-
* Optional. Immutable. User-facing, version-independent label for this connector. May be shared by multiple connectors under the same (project, location, collection, data_source); tag-based lookup returns the one with the greatest create_time. Optional at Create time. Agent Designer resolves connectors via (data_source, tag) when set, falling back to the legacy resource-name lookup when unset, so connectors created before the tag-write launch continue to work without a backfill.
|
|
4713
|
+
* Optional. Immutable. User-facing, version-independent label for this connector. May be shared by multiple connectors under the same (project, location, collection, data_source); tag-based lookup returns the one with the greatest create_time. Optional at Create time. If the caller omits `tag`, the server auto-derives one from the collection_id (falling back to data_source, else a time-based `t-` sentinel). The auto-derived tag is subject to the same immutability guarantee as a caller-supplied one, so callers who care about the exact tag value should provide it explicitly rather than relying on the server default. Agent Designer resolves connectors via (data_source, tag) when set, falling back to the legacy resource-name lookup when unset, so connectors created before the tag-write launch continue to work without a backfill.
|
|
4706
4714
|
*/
|
|
4707
4715
|
tag?: string | null;
|
|
4708
4716
|
/**
|
|
@@ -6174,6 +6182,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
6174
6182
|
* Required. The output location of the data.
|
|
6175
6183
|
*/
|
|
6176
6184
|
outputConfig?: Schema$GoogleCloudDiscoveryengineV1alphaOutputConfig;
|
|
6185
|
+
/**
|
|
6186
|
+
* Optional. The earliest date (inclusive), interpreted in the UTC time zone, whose metrics are included in the export. If unset, defaults to 30 days before the current UTC date. The value must be a valid calendar date that is not in the future and not older than 180 days (the source data retention window); otherwise the request fails with `INVALID_ARGUMENT`.
|
|
6187
|
+
*/
|
|
6188
|
+
startDate?: Schema$GoogleTypeDate;
|
|
6177
6189
|
}
|
|
6178
6190
|
/**
|
|
6179
6191
|
* Response of the ExportMetricsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field.
|
|
@@ -7308,6 +7320,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
7308
7320
|
* Optional. Whether the license config should be auto renewed when it reaches the end date.
|
|
7309
7321
|
*/
|
|
7310
7322
|
autoRenew?: boolean | null;
|
|
7323
|
+
/**
|
|
7324
|
+
* Output only. The name of the BillingAccountLicenseConfig from which this LicenseConfig is assigned, if this field is set.
|
|
7325
|
+
*/
|
|
7326
|
+
billingAccountLicenseConfig?: string | null;
|
|
7311
7327
|
/**
|
|
7312
7328
|
* Output only. Indication of whether the subscription is terminated earlier than the expiration date. This is usually terminated by pipeline once the subscription gets terminated from subsv3.
|
|
7313
7329
|
*/
|
|
@@ -8128,6 +8144,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
8128
8144
|
* Optional. Configuration for NotebookLM settings.
|
|
8129
8145
|
*/
|
|
8130
8146
|
notebooklmConfig?: Schema$GoogleCloudDiscoveryengineV1alphaProjectCustomerProvidedConfigNotebooklmConfig;
|
|
8147
|
+
/**
|
|
8148
|
+
* Optional. Resource-level access control config for Gemini Enterprise users.
|
|
8149
|
+
*/
|
|
8150
|
+
resourceAccessControlConfig?: Schema$GoogleCloudDiscoveryengineV1alphaProjectCustomerProvidedConfigResourceAccessControlConfig;
|
|
8131
8151
|
}
|
|
8132
8152
|
/**
|
|
8133
8153
|
* Configuration for NotebookLM.
|
|
@@ -8181,6 +8201,15 @@ export namespace discoveryengine_v1alpha {
|
|
|
8181
8201
|
*/
|
|
8182
8202
|
userPromptTemplate?: string | null;
|
|
8183
8203
|
}
|
|
8204
|
+
/**
|
|
8205
|
+
* Controls resource-level access control for Gemini Enterprise users.
|
|
8206
|
+
*/
|
|
8207
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaProjectCustomerProvidedConfigResourceAccessControlConfig {
|
|
8208
|
+
/**
|
|
8209
|
+
* Optional. If `true`, the data stores and data connectors shown to Gemini Enterprise users are filtered to those the user has the required resource-level `.get` IAM permission on.
|
|
8210
|
+
*/
|
|
8211
|
+
dataStoreAccessControlEnabled?: boolean | null;
|
|
8212
|
+
}
|
|
8184
8213
|
/**
|
|
8185
8214
|
* Metadata about the terms of service.
|
|
8186
8215
|
*/
|
|
@@ -8584,6 +8613,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
8584
8613
|
* This field is expected to be a ui message in JSON format. As of Q1 2026, ui_json_payload is only supported for A2UI messages.
|
|
8585
8614
|
*/
|
|
8586
8615
|
uiJsonPayload?: string | null;
|
|
8616
|
+
/**
|
|
8617
|
+
* Reference to a user-supplied file attached to a long-running-agent (Sobi) task. See `UserSuppliedSobiArtifactReference` above.
|
|
8618
|
+
*/
|
|
8619
|
+
userSuppliedSobiArtifactReference?: Schema$GoogleCloudDiscoveryengineV1alphaQueryPartUserSuppliedSobiArtifactReference;
|
|
8587
8620
|
}
|
|
8588
8621
|
/**
|
|
8589
8622
|
* Represents a document reference.
|
|
@@ -8676,6 +8709,19 @@ export namespace discoveryengine_v1alpha {
|
|
|
8676
8709
|
*/
|
|
8677
8710
|
personId?: string | null;
|
|
8678
8711
|
}
|
|
8712
|
+
/**
|
|
8713
|
+
* Reference to a user-supplied file attached to a long-running-agent (Sobi) task. Rendered by the client as an attachment chip on the user turn's bubble. The file itself is stored on the task's `AgentArtifact` list; the client resolves full metadata (source URI, size, ...) for download or preview by calling `GetTask` on the Sobi Task API and matching `AgentArtifact.name` against `file_name`. Only `file_name` and `mime_type` appear on this wire deliberately: the backing `gs://` or Drive URI is not exposed to conversation-history readers. Same variant is used for both byte-uploaded and Drive-picked files -- "user attached a file" is one concept regardless of source.
|
|
8714
|
+
*/
|
|
8715
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaQueryPartUserSuppliedSobiArtifactReference {
|
|
8716
|
+
/**
|
|
8717
|
+
* Required. Client-supplied filename. Unique per task within the user-supplied artifact set (UI dedupes before upload). Doubles as the artifact identifier used to look up the artifact on `Task.artifacts`. The `_name` suffix is deliberate and the AIP-122 lint is suppressed: this field is not a resource name (which is what AIP-122 reserves the bare `name` for). It is the literal filename, and it serves as the join key against `AgentArtifact.name` on the backing Sobi task -- a structural role that `title` or `display_name` would not communicate to a client picking what to send. The internal mirror (`cloud/ml/discoveryengine/schema/assistant.proto`) uses the same field name so the round-trip converter stays name-for-name.
|
|
8718
|
+
*/
|
|
8719
|
+
fileName?: string | null;
|
|
8720
|
+
/**
|
|
8721
|
+
* Optional. IANA MIME type. Used for icon/preview rendering.
|
|
8722
|
+
*/
|
|
8723
|
+
mimeType?: string | null;
|
|
8724
|
+
}
|
|
8679
8725
|
/**
|
|
8680
8726
|
* Record message for RankService.Rank method.
|
|
8681
8727
|
*/
|
|
@@ -9352,7 +9398,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
9352
9398
|
*/
|
|
9353
9399
|
orderBy?: string | null;
|
|
9354
9400
|
/**
|
|
9355
|
-
* The user's search query. See SearchRequest.query for definition. The value must be a UTF-8 encoded string with a length limit of 5,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. At least one of search_query or PageInfo.page_category is required for `search` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
9401
|
+
* Optional. The user's search query. See SearchRequest.query for definition. The value must be a UTF-8 encoded string with a length limit of 5,000 characters. Otherwise, an `INVALID_ARGUMENT` error is returned. At least one of search_query or PageInfo.page_category is required for `search` events. Other event types should not set this field. Otherwise, an `INVALID_ARGUMENT` error is returned.
|
|
9356
9402
|
*/
|
|
9357
9403
|
searchQuery?: string | null;
|
|
9358
9404
|
}
|
|
@@ -10030,6 +10076,27 @@ export namespace discoveryengine_v1alpha {
|
|
|
10030
10076
|
* The condition under which search as you type should occur. Default to Condition.DISABLED.
|
|
10031
10077
|
*/
|
|
10032
10078
|
condition?: string | null;
|
|
10079
|
+
/**
|
|
10080
|
+
* Optional. The list of fields to be used for Search As You Type scoring.
|
|
10081
|
+
*/
|
|
10082
|
+
fields?: Schema$GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpecField[];
|
|
10083
|
+
/**
|
|
10084
|
+
* Optional. Search As You Type score threshold for filtering purpose. We keep the result if `score` \>= `score_threshold`.
|
|
10085
|
+
*/
|
|
10086
|
+
scoreThreshold?: number | null;
|
|
10087
|
+
}
|
|
10088
|
+
/**
|
|
10089
|
+
* A schema field to be used for Search As You Type scoring on this request. Overrides any data-store-level Search As You Type field configuration for the duration of the request.
|
|
10090
|
+
*/
|
|
10091
|
+
export interface Schema$GoogleCloudDiscoveryengineV1alphaSearchRequestSearchAsYouTypeSpecField {
|
|
10092
|
+
/**
|
|
10093
|
+
* Required. A field key that has been indexed for Search As You Type.
|
|
10094
|
+
*/
|
|
10095
|
+
key?: string | null;
|
|
10096
|
+
/**
|
|
10097
|
+
* Optional. Weight for scores from this field. Defaults to 1.0 if not specified.
|
|
10098
|
+
*/
|
|
10099
|
+
weight?: number | null;
|
|
10033
10100
|
}
|
|
10034
10101
|
/**
|
|
10035
10102
|
* Session specification.
|
|
@@ -11578,7 +11645,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
11578
11645
|
*/
|
|
11579
11646
|
export interface Schema$GoogleCloudDiscoveryengineV1alphaUserEvent {
|
|
11580
11647
|
/**
|
|
11581
|
-
* Extra user event features to include in the recommendation model. These attributes must NOT contain data that needs to be parsed or processed further, e.g. JSON or other encodings. If you provide custom attributes for ingested user events, also include them in the user events that you associate with prediction requests. Custom attribute formatting must be consistent between imported events and events provided with prediction requests. This lets the Discovery Engine API use those custom attributes when training models and serving predictions, which helps improve recommendation quality. This field needs to pass all below criteria, otherwise an `INVALID_ARGUMENT` error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendations, an example of extra user information is `traffic_channel`, which is how a user arrives at the site. Users can arrive at the site by coming to the site directly, coming through Google search, or in other ways.
|
|
11648
|
+
* Optional. Extra user event features to include in the recommendation model. These attributes must NOT contain data that needs to be parsed or processed further, e.g. JSON or other encodings. If you provide custom attributes for ingested user events, also include them in the user events that you associate with prediction requests. Custom attribute formatting must be consistent between imported events and events provided with prediction requests. This lets the Discovery Engine API use those custom attributes when training models and serving predictions, which helps improve recommendation quality. This field needs to pass all below criteria, otherwise an `INVALID_ARGUMENT` error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendations, an example of extra user information is `traffic_channel`, which is how a user arrives at the site. Users can arrive at the site by coming to the site directly, coming through Google search, or in other ways.
|
|
11582
11649
|
*/
|
|
11583
11650
|
attributes?: {
|
|
11584
11651
|
[key: string]: Schema$GoogleCloudDiscoveryengineV1alphaCustomAttribute;
|
|
@@ -12081,6 +12148,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
12081
12148
|
* The name of the collection. It should be collection resource name. Format: `projects/{project\}/locations/{location\}/collections/{collection_id\}`. For APIs under WidgetService, such as WidgetService.LookupWidgetConfig, the project number and location part is erased in this field. For synthetic placeholder entries (see message-level comment) this carries a synthetic placeholder collection id that does not correspond to a real collection. Callers must not attempt to resolve / GET this resource until the user authorizes the connector.
|
|
12082
12149
|
*/
|
|
12083
12150
|
name?: string | null;
|
|
12151
|
+
/**
|
|
12152
|
+
* Output only. The version-independent label of the connector backing this collection, mirroring `DataConnector.tag`. Unlike the version-pinned data store id it survives a connector version upgrade, so an upgraded connector keeps the same tag. Not a unique key. As `DataConnector.tag` documents, several connectors may share a tag under the same (project, location, collection, data_source), and tag-based lookup resolves to the one with the greatest create_time. Clients must not treat this as a connector identifier. Empty when the connector was created before the tag-write launch, and for synthetic placeholder entries, which have no underlying `DataConnector`. Populated only when `ConnectorsFeature.enable_connector_tag` is on.
|
|
12153
|
+
*/
|
|
12154
|
+
tag?: string | null;
|
|
12084
12155
|
}
|
|
12085
12156
|
/**
|
|
12086
12157
|
* Read-only connector in CollectionComponent auth state.
|
|
@@ -12432,6 +12503,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
12432
12503
|
* Output only. Localized display name of the model (e.g. `Gemini 3.1 Pro`). Localized server-side based on the LookupWidgetConfigRequest.language_code and LookupWidgetConfigRequest.region_code of the request.
|
|
12433
12504
|
*/
|
|
12434
12505
|
displayName?: string | null;
|
|
12506
|
+
/**
|
|
12507
|
+
* Output only. Groups models that render together in the selector. Models sharing a value form one group; empty means the model belongs to no group. Compared for equality only -- never parsed, and never shown to a user, so it is not localized.
|
|
12508
|
+
*/
|
|
12509
|
+
family?: string | null;
|
|
12435
12510
|
/**
|
|
12436
12511
|
* Output only. GM3-compatible icon token associated with the model (e.g. `rocket_launch`, `bolt`, `graph_5`).
|
|
12437
12512
|
*/
|
|
@@ -14595,6 +14670,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
14595
14670
|
* Optional. Configuration for NotebookLM settings.
|
|
14596
14671
|
*/
|
|
14597
14672
|
notebooklmConfig?: Schema$GoogleCloudDiscoveryengineV1betaProjectCustomerProvidedConfigNotebooklmConfig;
|
|
14673
|
+
/**
|
|
14674
|
+
* Optional. Resource-level access control config for Gemini Enterprise users.
|
|
14675
|
+
*/
|
|
14676
|
+
resourceAccessControlConfig?: Schema$GoogleCloudDiscoveryengineV1betaProjectCustomerProvidedConfigResourceAccessControlConfig;
|
|
14598
14677
|
}
|
|
14599
14678
|
/**
|
|
14600
14679
|
* Configuration for NotebookLM.
|
|
@@ -14648,6 +14727,15 @@ export namespace discoveryengine_v1alpha {
|
|
|
14648
14727
|
*/
|
|
14649
14728
|
userPromptTemplate?: string | null;
|
|
14650
14729
|
}
|
|
14730
|
+
/**
|
|
14731
|
+
* Controls resource-level access control for Gemini Enterprise users.
|
|
14732
|
+
*/
|
|
14733
|
+
export interface Schema$GoogleCloudDiscoveryengineV1betaProjectCustomerProvidedConfigResourceAccessControlConfig {
|
|
14734
|
+
/**
|
|
14735
|
+
* Optional. If `true`, the data stores and data connectors shown to Gemini Enterprise users are filtered to those the user has the required resource-level `.get` IAM permission on.
|
|
14736
|
+
*/
|
|
14737
|
+
dataStoreAccessControlEnabled?: boolean | null;
|
|
14738
|
+
}
|
|
14651
14739
|
/**
|
|
14652
14740
|
* Metadata about the terms of service.
|
|
14653
14741
|
*/
|
|
@@ -15496,6 +15584,27 @@ export namespace discoveryengine_v1alpha {
|
|
|
15496
15584
|
* The condition under which search as you type should occur. Default to Condition.DISABLED.
|
|
15497
15585
|
*/
|
|
15498
15586
|
condition?: string | null;
|
|
15587
|
+
/**
|
|
15588
|
+
* Optional. The list of fields to be used for Search As You Type scoring.
|
|
15589
|
+
*/
|
|
15590
|
+
fields?: Schema$GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpecField[];
|
|
15591
|
+
/**
|
|
15592
|
+
* Optional. Search As You Type score threshold for filtering purpose. We keep the result if `score` \>= `score_threshold`.
|
|
15593
|
+
*/
|
|
15594
|
+
scoreThreshold?: number | null;
|
|
15595
|
+
}
|
|
15596
|
+
/**
|
|
15597
|
+
* A schema field to be used for Search As You Type scoring on this request. Overrides any data-store-level Search As You Type field configuration for the duration of the request.
|
|
15598
|
+
*/
|
|
15599
|
+
export interface Schema$GoogleCloudDiscoveryengineV1betaSearchRequestSearchAsYouTypeSpecField {
|
|
15600
|
+
/**
|
|
15601
|
+
* Required. A field key that has been indexed for Search As You Type.
|
|
15602
|
+
*/
|
|
15603
|
+
key?: string | null;
|
|
15604
|
+
/**
|
|
15605
|
+
* Optional. Weight for scores from this field. Defaults to 1.0 if not specified.
|
|
15606
|
+
*/
|
|
15607
|
+
weight?: number | null;
|
|
15499
15608
|
}
|
|
15500
15609
|
/**
|
|
15501
15610
|
* Session specification.
|
|
@@ -16367,7 +16476,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
16367
16476
|
*/
|
|
16368
16477
|
syncMode?: string | null;
|
|
16369
16478
|
/**
|
|
16370
|
-
* Optional. Immutable. User-facing, version-independent label for this connector. May be shared by multiple connectors under the same (project, location, collection, data_source); tag-based lookup returns the one with the greatest create_time. Optional at Create time. Agent Designer resolves connectors via (data_source, tag) when set, falling back to the legacy resource-name lookup when unset, so connectors created before the tag-write launch continue to work without a backfill.
|
|
16479
|
+
* Optional. Immutable. User-facing, version-independent label for this connector. May be shared by multiple connectors under the same (project, location, collection, data_source); tag-based lookup returns the one with the greatest create_time. Optional at Create time. If the caller omits `tag`, the server auto-derives one from the collection_id (falling back to data_source, else a time-based `t-` sentinel). The auto-derived tag is subject to the same immutability guarantee as a caller-supplied one, so callers who care about the exact tag value should provide it explicitly rather than relying on the server default. Agent Designer resolves connectors via (data_source, tag) when set, falling back to the legacy resource-name lookup when unset, so connectors created before the tag-write launch continue to work without a backfill.
|
|
16371
16480
|
*/
|
|
16372
16481
|
tag?: string | null;
|
|
16373
16482
|
/**
|
|
@@ -17779,6 +17888,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
17779
17888
|
* Optional. Configuration for NotebookLM settings.
|
|
17780
17889
|
*/
|
|
17781
17890
|
notebooklmConfig?: Schema$GoogleCloudDiscoveryengineV1ProjectCustomerProvidedConfigNotebooklmConfig;
|
|
17891
|
+
/**
|
|
17892
|
+
* Optional. Resource-level access control config for Gemini Enterprise users.
|
|
17893
|
+
*/
|
|
17894
|
+
resourceAccessControlConfig?: Schema$GoogleCloudDiscoveryengineV1ProjectCustomerProvidedConfigResourceAccessControlConfig;
|
|
17782
17895
|
}
|
|
17783
17896
|
/**
|
|
17784
17897
|
* Configuration for NotebookLM.
|
|
@@ -17832,6 +17945,15 @@ export namespace discoveryengine_v1alpha {
|
|
|
17832
17945
|
*/
|
|
17833
17946
|
userPromptTemplate?: string | null;
|
|
17834
17947
|
}
|
|
17948
|
+
/**
|
|
17949
|
+
* Controls resource-level access control for Gemini Enterprise users.
|
|
17950
|
+
*/
|
|
17951
|
+
export interface Schema$GoogleCloudDiscoveryengineV1ProjectCustomerProvidedConfigResourceAccessControlConfig {
|
|
17952
|
+
/**
|
|
17953
|
+
* Optional. If `true`, the data stores and data connectors shown to Gemini Enterprise users are filtered to those the user has the required resource-level `.get` IAM permission on.
|
|
17954
|
+
*/
|
|
17955
|
+
dataStoreAccessControlEnabled?: boolean | null;
|
|
17956
|
+
}
|
|
17835
17957
|
/**
|
|
17836
17958
|
* Metadata about the terms of service.
|
|
17837
17959
|
*/
|
|
@@ -18560,6 +18682,32 @@ export namespace discoveryengine_v1alpha {
|
|
|
18560
18682
|
*/
|
|
18561
18683
|
type?: string | null;
|
|
18562
18684
|
}
|
|
18685
|
+
/**
|
|
18686
|
+
* Account and role information.
|
|
18687
|
+
*/
|
|
18688
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaAccountAndRole {
|
|
18689
|
+
/**
|
|
18690
|
+
* Required. The email address associated with the account.
|
|
18691
|
+
*/
|
|
18692
|
+
email?: string | null;
|
|
18693
|
+
/**
|
|
18694
|
+
* Required. The role in the notebook.
|
|
18695
|
+
*/
|
|
18696
|
+
role?: string | null;
|
|
18697
|
+
}
|
|
18698
|
+
/**
|
|
18699
|
+
* Metadata about an agentspace source.
|
|
18700
|
+
*/
|
|
18701
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaAgentspaceMetadata {
|
|
18702
|
+
/**
|
|
18703
|
+
* Output only. The full document name in Agentspace.
|
|
18704
|
+
*/
|
|
18705
|
+
documentName?: string | null;
|
|
18706
|
+
/**
|
|
18707
|
+
* Output only. The title of the document.
|
|
18708
|
+
*/
|
|
18709
|
+
documentTitle?: string | null;
|
|
18710
|
+
}
|
|
18563
18711
|
/**
|
|
18564
18712
|
* An audio overview of a notebook. This is a summary of the notebook in audio format.
|
|
18565
18713
|
*/
|
|
@@ -18606,6 +18754,51 @@ export namespace discoveryengine_v1alpha {
|
|
|
18606
18754
|
*/
|
|
18607
18755
|
sourceIds?: Schema$GoogleCloudNotebooklmV1alphaSourceId[];
|
|
18608
18756
|
}
|
|
18757
|
+
/**
|
|
18758
|
+
* Request for SourceService.BatchCreateSources method.
|
|
18759
|
+
*/
|
|
18760
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest {
|
|
18761
|
+
/**
|
|
18762
|
+
* Required. The UserContents to be uploaded.
|
|
18763
|
+
*/
|
|
18764
|
+
userContents?: Schema$GoogleCloudNotebooklmV1alphaUserContent[];
|
|
18765
|
+
}
|
|
18766
|
+
/**
|
|
18767
|
+
* Response for SourceService.BatchCreateSources method.
|
|
18768
|
+
*/
|
|
18769
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse {
|
|
18770
|
+
/**
|
|
18771
|
+
* The Sources.
|
|
18772
|
+
*/
|
|
18773
|
+
sources?: Schema$GoogleCloudNotebooklmV1alphaSource[];
|
|
18774
|
+
}
|
|
18775
|
+
/**
|
|
18776
|
+
* Request for NotebookService.BatchDeleteNotebooks method.
|
|
18777
|
+
*/
|
|
18778
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaBatchDeleteNotebooksRequest {
|
|
18779
|
+
/**
|
|
18780
|
+
* Required. Full resource names of Notebook, such as `projects/{project\}/locations/{location\}/notebooks/{notebook_id\}`.
|
|
18781
|
+
*/
|
|
18782
|
+
names?: string[] | null;
|
|
18783
|
+
}
|
|
18784
|
+
/**
|
|
18785
|
+
* Request for BatchDeleteSourcesRequest method.
|
|
18786
|
+
*/
|
|
18787
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaBatchDeleteSourcesRequest {
|
|
18788
|
+
/**
|
|
18789
|
+
* Required. Names of sources to be deleted. Format: projects/{project\}/locations/{location\}/notebooks/{notebook\}/sources/{source\}
|
|
18790
|
+
*/
|
|
18791
|
+
names?: string[] | null;
|
|
18792
|
+
}
|
|
18793
|
+
/**
|
|
18794
|
+
* Customer-managed encryption configuration for Notebooks.
|
|
18795
|
+
*/
|
|
18796
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaCmekConfig {
|
|
18797
|
+
/**
|
|
18798
|
+
* Required. KMS key resource name which will be used to encrypt resources `projects/{project\}/locations/{location\}/keyRings/{keyRing\}/cryptoKeys/{keyId\}`.
|
|
18799
|
+
*/
|
|
18800
|
+
kmsKey?: string | null;
|
|
18801
|
+
}
|
|
18609
18802
|
/**
|
|
18610
18803
|
* Request for AudioOverviewService.CreateAudioOverview method.
|
|
18611
18804
|
*/
|
|
@@ -18624,6 +18817,294 @@ export namespace discoveryengine_v1alpha {
|
|
|
18624
18817
|
*/
|
|
18625
18818
|
audioOverview?: Schema$GoogleCloudNotebooklmV1alphaAudioOverview;
|
|
18626
18819
|
}
|
|
18820
|
+
/**
|
|
18821
|
+
* Failure reason containing details about why a source failed to ingest.
|
|
18822
|
+
*/
|
|
18823
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReason {
|
|
18824
|
+
/**
|
|
18825
|
+
* An audio file transcription specific error.
|
|
18826
|
+
*/
|
|
18827
|
+
audioTranscriptionError?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonAudioTranscriptionError;
|
|
18828
|
+
/**
|
|
18829
|
+
* Error if the user tries to add a source from a blocked domain.
|
|
18830
|
+
*/
|
|
18831
|
+
domainBlocked?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonDomainBlocked;
|
|
18832
|
+
/**
|
|
18833
|
+
* A google drive specific error.
|
|
18834
|
+
*/
|
|
18835
|
+
googleDriveError?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonGoogleDriveError;
|
|
18836
|
+
/**
|
|
18837
|
+
* Indicates an error occurred while ingesting the source.
|
|
18838
|
+
*/
|
|
18839
|
+
ingestionError?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonIngestionError;
|
|
18840
|
+
/**
|
|
18841
|
+
* Indicates that the source MIME type is blocked.
|
|
18842
|
+
*/
|
|
18843
|
+
mimeTypeBlocked?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonMimeTypeBlocked;
|
|
18844
|
+
/**
|
|
18845
|
+
* Indicates that the source is paywalled and cannot be ingested.
|
|
18846
|
+
*/
|
|
18847
|
+
paywallError?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonPaywallError;
|
|
18848
|
+
/**
|
|
18849
|
+
* Indicates that the policy check failed.
|
|
18850
|
+
*/
|
|
18851
|
+
policyCheckFailed?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonPolicyCheckFailed;
|
|
18852
|
+
/**
|
|
18853
|
+
* Indicates that the source is empty.
|
|
18854
|
+
*/
|
|
18855
|
+
sourceEmpty?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonSourceEmpty;
|
|
18856
|
+
/**
|
|
18857
|
+
* Error if the user tries to update beyond their limits.
|
|
18858
|
+
*/
|
|
18859
|
+
sourceLimitExceeded?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonSourceLimitExceeded;
|
|
18860
|
+
/**
|
|
18861
|
+
* Indicates source word count exceeded the user's limit.
|
|
18862
|
+
*/
|
|
18863
|
+
sourceTooLong?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonSourceTooLong;
|
|
18864
|
+
/**
|
|
18865
|
+
* Indicates that the source is unreachable.
|
|
18866
|
+
*/
|
|
18867
|
+
sourceUnreachable?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonSourceUnreachable;
|
|
18868
|
+
/**
|
|
18869
|
+
* Indicates an unknown error occurred.
|
|
18870
|
+
*/
|
|
18871
|
+
unknown?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonUnknown;
|
|
18872
|
+
/**
|
|
18873
|
+
* Indicates an error occurred while uploading the source.
|
|
18874
|
+
*/
|
|
18875
|
+
uploadError?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonUploadError;
|
|
18876
|
+
/**
|
|
18877
|
+
* A youtube specific error.
|
|
18878
|
+
*/
|
|
18879
|
+
youtubeError?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonYoutubeError;
|
|
18880
|
+
}
|
|
18881
|
+
/**
|
|
18882
|
+
* An audio file transcription specific error.
|
|
18883
|
+
*/
|
|
18884
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonAudioTranscriptionError {
|
|
18885
|
+
/**
|
|
18886
|
+
* Could not detect language of the file (it may not be speech).
|
|
18887
|
+
*/
|
|
18888
|
+
languageDetectionFailed?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonAudioTranscriptionErrorLanguageDetectionFailed;
|
|
18889
|
+
/**
|
|
18890
|
+
* No audio was detected in the input file (it may have been a video).
|
|
18891
|
+
*/
|
|
18892
|
+
noAudioDetected?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonAudioTranscriptionErrorNoAudioDetected;
|
|
18893
|
+
}
|
|
18894
|
+
/**
|
|
18895
|
+
* Could not detect language of the file (it may not be speech).
|
|
18896
|
+
*/
|
|
18897
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonAudioTranscriptionErrorLanguageDetectionFailed {}
|
|
18898
|
+
/**
|
|
18899
|
+
* No audio was detected in the input file.
|
|
18900
|
+
*/
|
|
18901
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonAudioTranscriptionErrorNoAudioDetected {}
|
|
18902
|
+
/**
|
|
18903
|
+
* Error to indicate that the source was removed because the domain was blocked.
|
|
18904
|
+
*/
|
|
18905
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonDomainBlocked {}
|
|
18906
|
+
/**
|
|
18907
|
+
* A google drive specific error.
|
|
18908
|
+
*/
|
|
18909
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonGoogleDriveError {
|
|
18910
|
+
/**
|
|
18911
|
+
* The user was prevented from downloading the file.
|
|
18912
|
+
*/
|
|
18913
|
+
downloadPrevented?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonGoogleDriveErrorDownloadPrevented;
|
|
18914
|
+
}
|
|
18915
|
+
/**
|
|
18916
|
+
* The user was prevented from downloading the file.
|
|
18917
|
+
*/
|
|
18918
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonGoogleDriveErrorDownloadPrevented {}
|
|
18919
|
+
/**
|
|
18920
|
+
* Indicates an error occurred while ingesting the source.
|
|
18921
|
+
*/
|
|
18922
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonIngestionError {}
|
|
18923
|
+
/**
|
|
18924
|
+
* Indicates that the source MIME type is blocked.
|
|
18925
|
+
*/
|
|
18926
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonMimeTypeBlocked {}
|
|
18927
|
+
/**
|
|
18928
|
+
* Indicates that the source is paywalled and cannot be ingested.
|
|
18929
|
+
*/
|
|
18930
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonPaywallError {}
|
|
18931
|
+
/**
|
|
18932
|
+
* Indicates that the policy check failed.
|
|
18933
|
+
*/
|
|
18934
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonPolicyCheckFailed {}
|
|
18935
|
+
/**
|
|
18936
|
+
* Indicates that the source is empty.
|
|
18937
|
+
*/
|
|
18938
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonSourceEmpty {}
|
|
18939
|
+
/**
|
|
18940
|
+
* Indicates that the user does not have space for this source.
|
|
18941
|
+
*/
|
|
18942
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonSourceLimitExceeded {}
|
|
18943
|
+
/**
|
|
18944
|
+
* Indicates source word count exceeded the user's limit.
|
|
18945
|
+
*/
|
|
18946
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonSourceTooLong {
|
|
18947
|
+
/**
|
|
18948
|
+
* The number of words in the source.
|
|
18949
|
+
*/
|
|
18950
|
+
wordCount?: number | null;
|
|
18951
|
+
/**
|
|
18952
|
+
* The word count limit for the current user at the time of the upload.
|
|
18953
|
+
*/
|
|
18954
|
+
wordLimit?: number | null;
|
|
18955
|
+
}
|
|
18956
|
+
/**
|
|
18957
|
+
* Indicates that the source is unreachable. This is primarily used for sources that are added via URL.
|
|
18958
|
+
*/
|
|
18959
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonSourceUnreachable {
|
|
18960
|
+
/**
|
|
18961
|
+
* Describes why the source is unreachable.
|
|
18962
|
+
*/
|
|
18963
|
+
errorDetails?: string | null;
|
|
18964
|
+
}
|
|
18965
|
+
/**
|
|
18966
|
+
* Indicates an unknown error occurred.
|
|
18967
|
+
*/
|
|
18968
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonUnknown {}
|
|
18969
|
+
/**
|
|
18970
|
+
* Indicates an error occurred while uploading the source.
|
|
18971
|
+
*/
|
|
18972
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonUploadError {}
|
|
18973
|
+
/**
|
|
18974
|
+
* A youtube specific error.
|
|
18975
|
+
*/
|
|
18976
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonYoutubeError {
|
|
18977
|
+
/**
|
|
18978
|
+
* Error to indicate that the source was removed because the video was deleted.
|
|
18979
|
+
*/
|
|
18980
|
+
videoDeleted?: Schema$GoogleCloudNotebooklmV1alphaFailureReasonYoutubeErrorVideoDeleted;
|
|
18981
|
+
}
|
|
18982
|
+
/**
|
|
18983
|
+
* Error to indicate that the source was removed because the video was deleted.
|
|
18984
|
+
*/
|
|
18985
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaFailureReasonYoutubeErrorVideoDeleted {}
|
|
18986
|
+
/**
|
|
18987
|
+
* Metadata about a google doc source.
|
|
18988
|
+
*/
|
|
18989
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaGoogleDocsSourceMetadata {
|
|
18990
|
+
/**
|
|
18991
|
+
* Output only. The document id of the google doc.
|
|
18992
|
+
*/
|
|
18993
|
+
documentId?: string | null;
|
|
18994
|
+
/**
|
|
18995
|
+
* Output only. Revision id for the doc.
|
|
18996
|
+
*/
|
|
18997
|
+
revisionId?: string | null;
|
|
18998
|
+
}
|
|
18999
|
+
/**
|
|
19000
|
+
* Response for NotebookService.ListRecentlyViewedNotebooks method.
|
|
19001
|
+
*/
|
|
19002
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse {
|
|
19003
|
+
/**
|
|
19004
|
+
* The page token, provide this to retrieve the subsequent page.
|
|
19005
|
+
*/
|
|
19006
|
+
nextPageToken?: string | null;
|
|
19007
|
+
/**
|
|
19008
|
+
* The list of recently viewed notebooks.
|
|
19009
|
+
*/
|
|
19010
|
+
notebooks?: Schema$GoogleCloudNotebooklmV1alphaNotebook[];
|
|
19011
|
+
}
|
|
19012
|
+
/**
|
|
19013
|
+
* Notebook is a resource where users can store their content (as sources) and interacts with the content.
|
|
19014
|
+
*/
|
|
19015
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaNotebook {
|
|
19016
|
+
/**
|
|
19017
|
+
* Output only. CMEK-related information for the Notebook.
|
|
19018
|
+
*/
|
|
19019
|
+
cmekConfig?: Schema$GoogleCloudNotebooklmV1alphaCmekConfig;
|
|
19020
|
+
/**
|
|
19021
|
+
* Output only. The emoji of the notebook.
|
|
19022
|
+
*/
|
|
19023
|
+
emoji?: string | null;
|
|
19024
|
+
/**
|
|
19025
|
+
* Output only. The metadata of the notebook.
|
|
19026
|
+
*/
|
|
19027
|
+
metadata?: Schema$GoogleCloudNotebooklmV1alphaNotebookMetadata;
|
|
19028
|
+
/**
|
|
19029
|
+
* Identifier. The identifier of the notebook. Format: `projects/{project\}/locations/{location\}/notebooks/{notebook_id\}`. This field must be a UTF-8 encoded string.
|
|
19030
|
+
*/
|
|
19031
|
+
name?: string | null;
|
|
19032
|
+
/**
|
|
19033
|
+
* Output only. Notebook id, which is the last segment of the notebook's resource name.
|
|
19034
|
+
*/
|
|
19035
|
+
notebookId?: string | null;
|
|
19036
|
+
/**
|
|
19037
|
+
* Output only. List of sources in the notebook. This is an output only field.
|
|
19038
|
+
*/
|
|
19039
|
+
sources?: Schema$GoogleCloudNotebooklmV1alphaSource[];
|
|
19040
|
+
/**
|
|
19041
|
+
* Optional. The title of the notebook.
|
|
19042
|
+
*/
|
|
19043
|
+
title?: string | null;
|
|
19044
|
+
}
|
|
19045
|
+
/**
|
|
19046
|
+
* Metadata for a notebook.
|
|
19047
|
+
*/
|
|
19048
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaNotebookMetadata {
|
|
19049
|
+
/**
|
|
19050
|
+
* The time at which this project was created.
|
|
19051
|
+
*/
|
|
19052
|
+
createTime?: string | null;
|
|
19053
|
+
/**
|
|
19054
|
+
* True if the project is shareable.
|
|
19055
|
+
*/
|
|
19056
|
+
isShareable?: boolean | null;
|
|
19057
|
+
/**
|
|
19058
|
+
* True if this project is currently shared with other people, false otherwise.
|
|
19059
|
+
*/
|
|
19060
|
+
isShared?: boolean | null;
|
|
19061
|
+
/**
|
|
19062
|
+
* A timestamp indicating the time that the current in session user has last viewed the project.
|
|
19063
|
+
*/
|
|
19064
|
+
lastViewed?: string | null;
|
|
19065
|
+
}
|
|
19066
|
+
/**
|
|
19067
|
+
* Request for NotebookService.ShareNotebook method.
|
|
19068
|
+
*/
|
|
19069
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaShareNotebookRequest {
|
|
19070
|
+
/**
|
|
19071
|
+
* Required. The list of accounts and roles to share the notebook with.
|
|
19072
|
+
*/
|
|
19073
|
+
accountAndRoles?: Schema$GoogleCloudNotebooklmV1alphaAccountAndRole[];
|
|
19074
|
+
/**
|
|
19075
|
+
* Required. Whether to notify the shared users via email.
|
|
19076
|
+
*/
|
|
19077
|
+
notifyViaEmail?: boolean | null;
|
|
19078
|
+
}
|
|
19079
|
+
/**
|
|
19080
|
+
* Response for NotebookService.ShareNotebook method.
|
|
19081
|
+
*/
|
|
19082
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse {}
|
|
19083
|
+
/**
|
|
19084
|
+
* Source represents a single source of content.
|
|
19085
|
+
*/
|
|
19086
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaSource {
|
|
19087
|
+
/**
|
|
19088
|
+
* Output only. Metadata about the source.
|
|
19089
|
+
*/
|
|
19090
|
+
metadata?: Schema$GoogleCloudNotebooklmV1alphaSourceMetadata;
|
|
19091
|
+
/**
|
|
19092
|
+
* Identifier. The full resource name of the source. Format: `projects/{project\}/locations/{location\}/notebooks/{notebook\}/sources/{source_id\}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.
|
|
19093
|
+
*/
|
|
19094
|
+
name?: string | null;
|
|
19095
|
+
/**
|
|
19096
|
+
* Output only. Status of the source, and any failure reasons.
|
|
19097
|
+
*/
|
|
19098
|
+
settings?: Schema$GoogleCloudNotebooklmV1alphaSourceSettings;
|
|
19099
|
+
/**
|
|
19100
|
+
* Optional. Output only. Source id, which is the last segment of the source's resource name.
|
|
19101
|
+
*/
|
|
19102
|
+
sourceId?: Schema$GoogleCloudNotebooklmV1alphaSourceId;
|
|
19103
|
+
/**
|
|
19104
|
+
* Optional. Title of the source.
|
|
19105
|
+
*/
|
|
19106
|
+
title?: string | null;
|
|
19107
|
+
}
|
|
18627
19108
|
/**
|
|
18628
19109
|
* SourceId is the last segment of the source's resource name.
|
|
18629
19110
|
*/
|
|
@@ -18633,6 +19114,155 @@ export namespace discoveryengine_v1alpha {
|
|
|
18633
19114
|
*/
|
|
18634
19115
|
id?: string | null;
|
|
18635
19116
|
}
|
|
19117
|
+
/**
|
|
19118
|
+
* Represents the metadata of a source and some additional information.
|
|
19119
|
+
*/
|
|
19120
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaSourceMetadata {
|
|
19121
|
+
/**
|
|
19122
|
+
* Metadata for an agentspace source.
|
|
19123
|
+
*/
|
|
19124
|
+
agentspaceMetadata?: Schema$GoogleCloudNotebooklmV1alphaAgentspaceMetadata;
|
|
19125
|
+
/**
|
|
19126
|
+
* Metadata for a google doc source.
|
|
19127
|
+
*/
|
|
19128
|
+
googleDocsMetadata?: Schema$GoogleCloudNotebooklmV1alphaGoogleDocsSourceMetadata;
|
|
19129
|
+
/**
|
|
19130
|
+
* The timestamp the source was added.
|
|
19131
|
+
*/
|
|
19132
|
+
sourceAddedTimestamp?: string | null;
|
|
19133
|
+
/**
|
|
19134
|
+
* The number of tokens in the source.
|
|
19135
|
+
*/
|
|
19136
|
+
tokenCount?: number | null;
|
|
19137
|
+
/**
|
|
19138
|
+
* The word count of the source.
|
|
19139
|
+
*/
|
|
19140
|
+
wordCount?: number | null;
|
|
19141
|
+
/**
|
|
19142
|
+
* Metadata for a youtube video source.
|
|
19143
|
+
*/
|
|
19144
|
+
youtubeMetadata?: Schema$GoogleCloudNotebooklmV1alphaYoutubeMetadata;
|
|
19145
|
+
}
|
|
19146
|
+
/**
|
|
19147
|
+
* Allows extension of Source Settings in the BatchCreateSources (Formerly AddSource request).
|
|
19148
|
+
*/
|
|
19149
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaSourceSettings {
|
|
19150
|
+
/**
|
|
19151
|
+
* Failure reason containing details about why a source failed to ingest.
|
|
19152
|
+
*/
|
|
19153
|
+
failureReason?: Schema$GoogleCloudNotebooklmV1alphaFailureReason;
|
|
19154
|
+
/**
|
|
19155
|
+
* Status of the source.
|
|
19156
|
+
*/
|
|
19157
|
+
status?: string | null;
|
|
19158
|
+
}
|
|
19159
|
+
/**
|
|
19160
|
+
* The "Content" messages refer to data the user wants to upload.
|
|
19161
|
+
*/
|
|
19162
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaUserContent {
|
|
19163
|
+
/**
|
|
19164
|
+
* Agentspace content uploaded as source.
|
|
19165
|
+
*/
|
|
19166
|
+
agentspaceContent?: Schema$GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent;
|
|
19167
|
+
/**
|
|
19168
|
+
* The content from Google Drive.
|
|
19169
|
+
*/
|
|
19170
|
+
googleDriveContent?: Schema$GoogleCloudNotebooklmV1alphaUserContentGoogleDriveContent;
|
|
19171
|
+
/**
|
|
19172
|
+
* The text content uploaded as source.
|
|
19173
|
+
*/
|
|
19174
|
+
textContent?: Schema$GoogleCloudNotebooklmV1alphaUserContentTextContent;
|
|
19175
|
+
/**
|
|
19176
|
+
* The video content uploaded as source.
|
|
19177
|
+
*/
|
|
19178
|
+
videoContent?: Schema$GoogleCloudNotebooklmV1alphaUserContentVideoContent;
|
|
19179
|
+
/**
|
|
19180
|
+
* The web content uploaded as source.
|
|
19181
|
+
*/
|
|
19182
|
+
webContent?: Schema$GoogleCloudNotebooklmV1alphaUserContentWebContent;
|
|
19183
|
+
}
|
|
19184
|
+
/**
|
|
19185
|
+
* Agentspace content uploaded as source.
|
|
19186
|
+
*/
|
|
19187
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaUserContentAgentspaceContent {
|
|
19188
|
+
/**
|
|
19189
|
+
* Optional. The full resource name of the Agentspace document. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/dataStores/{data_store\}/branches/{branch\}/documents/{document_id\}`.
|
|
19190
|
+
*/
|
|
19191
|
+
documentName?: string | null;
|
|
19192
|
+
/**
|
|
19193
|
+
* Optional. Engine to verify the permission of the document. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}`.
|
|
19194
|
+
*/
|
|
19195
|
+
engineName?: string | null;
|
|
19196
|
+
/**
|
|
19197
|
+
* Optional. Resource name of the idea forge instance. Format: `projects/{project\}/locations/{location\}/collections/{collection\}/engines/{engine\}/sessions/{session\}/ideaForgeInstances/{instance\}`
|
|
19198
|
+
*/
|
|
19199
|
+
ideaforgeIdeaName?: string | null;
|
|
19200
|
+
}
|
|
19201
|
+
/**
|
|
19202
|
+
* The content from Google Drive.
|
|
19203
|
+
*/
|
|
19204
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaUserContentGoogleDriveContent {
|
|
19205
|
+
/**
|
|
19206
|
+
* The document id of the selected document.
|
|
19207
|
+
*/
|
|
19208
|
+
documentId?: string | null;
|
|
19209
|
+
/**
|
|
19210
|
+
* The mime type of the selected document. This can be used to differentiate type of content selected in the drive picker. Use application/vnd.google-apps.document for Google Docs or application/vnd.google-apps.presentation for Google Slides.
|
|
19211
|
+
*/
|
|
19212
|
+
mimeType?: string | null;
|
|
19213
|
+
/**
|
|
19214
|
+
* The name to be displayed for the source.
|
|
19215
|
+
*/
|
|
19216
|
+
sourceName?: string | null;
|
|
19217
|
+
}
|
|
19218
|
+
/**
|
|
19219
|
+
* The text content uploaded as source.
|
|
19220
|
+
*/
|
|
19221
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaUserContentTextContent {
|
|
19222
|
+
/**
|
|
19223
|
+
* The name to be displayed for the source.
|
|
19224
|
+
*/
|
|
19225
|
+
content?: string | null;
|
|
19226
|
+
/**
|
|
19227
|
+
* The display name of the text source.
|
|
19228
|
+
*/
|
|
19229
|
+
sourceName?: string | null;
|
|
19230
|
+
}
|
|
19231
|
+
/**
|
|
19232
|
+
* Video content uploaded as source.
|
|
19233
|
+
*/
|
|
19234
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaUserContentVideoContent {
|
|
19235
|
+
/**
|
|
19236
|
+
* The youtube url of the video content.
|
|
19237
|
+
*/
|
|
19238
|
+
youtubeUrl?: string | null;
|
|
19239
|
+
}
|
|
19240
|
+
/**
|
|
19241
|
+
* The web content uploaded as source.
|
|
19242
|
+
*/
|
|
19243
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaUserContentWebContent {
|
|
19244
|
+
/**
|
|
19245
|
+
* The name to be displayed for the source.
|
|
19246
|
+
*/
|
|
19247
|
+
sourceName?: string | null;
|
|
19248
|
+
/**
|
|
19249
|
+
* If URL is supplied, will fetch the webpage in the backend.
|
|
19250
|
+
*/
|
|
19251
|
+
url?: string | null;
|
|
19252
|
+
}
|
|
19253
|
+
/**
|
|
19254
|
+
* Metadata about a youtube video source.
|
|
19255
|
+
*/
|
|
19256
|
+
export interface Schema$GoogleCloudNotebooklmV1alphaYoutubeMetadata {
|
|
19257
|
+
/**
|
|
19258
|
+
* Output only. The channel name of the youtube video.
|
|
19259
|
+
*/
|
|
19260
|
+
channelName?: string | null;
|
|
19261
|
+
/**
|
|
19262
|
+
* Output only. The id of the youtube video.
|
|
19263
|
+
*/
|
|
19264
|
+
videoId?: string | null;
|
|
19265
|
+
}
|
|
18636
19266
|
/**
|
|
18637
19267
|
* Associates `members`, or principals, with a `role`.
|
|
18638
19268
|
*/
|
|
@@ -46336,6 +46966,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
46336
46966
|
context: APIRequestContext;
|
|
46337
46967
|
analytics: Resource$Projects$Locations$Collections$Engines$Analytics;
|
|
46338
46968
|
assistants: Resource$Projects$Locations$Collections$Engines$Assistants;
|
|
46969
|
+
collaborativeProjects: Resource$Projects$Locations$Collections$Engines$Collaborativeprojects;
|
|
46339
46970
|
completionConfig: Resource$Projects$Locations$Collections$Engines$Completionconfig;
|
|
46340
46971
|
controls: Resource$Projects$Locations$Collections$Engines$Controls;
|
|
46341
46972
|
conversations: Resource$Projects$Locations$Collections$Engines$Conversations;
|
|
@@ -46353,6 +46984,10 @@ export namespace discoveryengine_v1alpha {
|
|
|
46353
46984
|
new Resource$Projects$Locations$Collections$Engines$Assistants(
|
|
46354
46985
|
this.context
|
|
46355
46986
|
);
|
|
46987
|
+
this.collaborativeProjects =
|
|
46988
|
+
new Resource$Projects$Locations$Collections$Engines$Collaborativeprojects(
|
|
46989
|
+
this.context
|
|
46990
|
+
);
|
|
46356
46991
|
this.completionConfig =
|
|
46357
46992
|
new Resource$Projects$Locations$Collections$Engines$Completionconfig(
|
|
46358
46993
|
this.context
|
|
@@ -48809,7 +49444,8 @@ export namespace discoveryengine_v1alpha {
|
|
|
48809
49444
|
* requestBody: {
|
|
48810
49445
|
* // request body parameters
|
|
48811
49446
|
* // {
|
|
48812
|
-
* // "outputConfig": {}
|
|
49447
|
+
* // "outputConfig": {},
|
|
49448
|
+
* // "startDate": {}
|
|
48813
49449
|
* // }
|
|
48814
49450
|
* },
|
|
48815
49451
|
* },
|
|
@@ -52607,192 +53243,38 @@ export namespace discoveryengine_v1alpha {
|
|
|
52607
53243
|
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaCannedQuery;
|
|
52608
53244
|
}
|
|
52609
53245
|
|
|
52610
|
-
export class Resource$Projects$Locations$Collections$Engines$
|
|
53246
|
+
export class Resource$Projects$Locations$Collections$Engines$Collaborativeprojects {
|
|
52611
53247
|
context: APIRequestContext;
|
|
53248
|
+
knowledgeSpaces: Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces;
|
|
52612
53249
|
constructor(context: APIRequestContext) {
|
|
52613
53250
|
this.context = context;
|
|
53251
|
+
this.knowledgeSpaces =
|
|
53252
|
+
new Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces(
|
|
53253
|
+
this.context
|
|
53254
|
+
);
|
|
52614
53255
|
}
|
|
53256
|
+
}
|
|
52615
53257
|
|
|
52616
|
-
|
|
52617
|
-
|
|
52618
|
-
|
|
52619
|
-
|
|
52620
|
-
|
|
52621
|
-
|
|
52622
|
-
|
|
52623
|
-
|
|
52624
|
-
* // ```sh
|
|
52625
|
-
* // $ gcloud auth application-default login
|
|
52626
|
-
* // ```
|
|
52627
|
-
* // - Install the npm module by running:
|
|
52628
|
-
* // ```sh
|
|
52629
|
-
* // $ npm install googleapis
|
|
52630
|
-
* // ```
|
|
52631
|
-
*
|
|
52632
|
-
* const {google} = require('googleapis');
|
|
52633
|
-
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
52634
|
-
*
|
|
52635
|
-
* async function main() {
|
|
52636
|
-
* const auth = new google.auth.GoogleAuth({
|
|
52637
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
52638
|
-
* scopes: [
|
|
52639
|
-
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
52640
|
-
* 'https://www.googleapis.com/auth/cloud_search.query',
|
|
52641
|
-
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
52642
|
-
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
52643
|
-
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
52644
|
-
* ],
|
|
52645
|
-
* });
|
|
52646
|
-
*
|
|
52647
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
52648
|
-
* const authClient = await auth.getClient();
|
|
52649
|
-
* google.options({auth: authClient});
|
|
52650
|
-
*
|
|
52651
|
-
* // Do the magic
|
|
52652
|
-
* const res =
|
|
52653
|
-
* await discoveryengine.projects.locations.collections.engines.completionConfig.completeQuery(
|
|
52654
|
-
* {
|
|
52655
|
-
* // Required. The completion_config of the parent dataStore or engine resource name for which the completion is performed, such as `projects/x/locations/global/collections/default_collection/dataStores/x/completionConfig` `projects/x/locations/global/collections/default_collection/engines/x/completionConfig`.
|
|
52656
|
-
* completionConfig:
|
|
52657
|
-
* 'projects/my-project/locations/my-location/collections/my-collection/engines/my-engine/completionConfig',
|
|
52658
|
-
*
|
|
52659
|
-
* // Request body metadata
|
|
52660
|
-
* requestBody: {
|
|
52661
|
-
* // request body parameters
|
|
52662
|
-
* // {
|
|
52663
|
-
* // "boostSpec": {},
|
|
52664
|
-
* // "experimentIds": [],
|
|
52665
|
-
* // "includeTailSuggestions": false,
|
|
52666
|
-
* // "query": "my_query",
|
|
52667
|
-
* // "queryModel": "my_queryModel",
|
|
52668
|
-
* // "suggestionTypeSpecs": [],
|
|
52669
|
-
* // "suggestionTypes": [],
|
|
52670
|
-
* // "userInfo": {},
|
|
52671
|
-
* // "userPseudoId": "my_userPseudoId"
|
|
52672
|
-
* // }
|
|
52673
|
-
* },
|
|
52674
|
-
* },
|
|
52675
|
-
* );
|
|
52676
|
-
* console.log(res.data);
|
|
52677
|
-
*
|
|
52678
|
-
* // Example response
|
|
52679
|
-
* // {
|
|
52680
|
-
* // "contentSuggestions": [],
|
|
52681
|
-
* // "peopleSuggestions": [],
|
|
52682
|
-
* // "querySuggestions": [],
|
|
52683
|
-
* // "recentSearchSuggestions": [],
|
|
52684
|
-
* // "tailMatchTriggered": false
|
|
52685
|
-
* // }
|
|
52686
|
-
* }
|
|
52687
|
-
*
|
|
52688
|
-
* main().catch(e => {
|
|
52689
|
-
* console.error(e);
|
|
52690
|
-
* throw e;
|
|
52691
|
-
* });
|
|
52692
|
-
*
|
|
52693
|
-
* ```
|
|
52694
|
-
*
|
|
52695
|
-
* @param params - Parameters for request
|
|
52696
|
-
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
52697
|
-
* @param callback - Optional callback that handles the response.
|
|
52698
|
-
* @returns A promise if used with async/await, or void if used with a callback.
|
|
52699
|
-
*/
|
|
52700
|
-
completeQuery(
|
|
52701
|
-
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
52702
|
-
options: StreamMethodOptions
|
|
52703
|
-
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
52704
|
-
completeQuery(
|
|
52705
|
-
params?: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
52706
|
-
options?: MethodOptions
|
|
52707
|
-
): Promise<
|
|
52708
|
-
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
52709
|
-
>;
|
|
52710
|
-
completeQuery(
|
|
52711
|
-
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
52712
|
-
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
52713
|
-
callback: BodyResponseCallback<Readable>
|
|
52714
|
-
): void;
|
|
52715
|
-
completeQuery(
|
|
52716
|
-
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
52717
|
-
options:
|
|
52718
|
-
| MethodOptions
|
|
52719
|
-
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>,
|
|
52720
|
-
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
52721
|
-
): void;
|
|
52722
|
-
completeQuery(
|
|
52723
|
-
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
52724
|
-
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
52725
|
-
): void;
|
|
52726
|
-
completeQuery(
|
|
52727
|
-
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
52728
|
-
): void;
|
|
52729
|
-
completeQuery(
|
|
52730
|
-
paramsOrCallback?:
|
|
52731
|
-
| Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery
|
|
52732
|
-
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
52733
|
-
| BodyResponseCallback<Readable>,
|
|
52734
|
-
optionsOrCallback?:
|
|
52735
|
-
| MethodOptions
|
|
52736
|
-
| StreamMethodOptions
|
|
52737
|
-
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
52738
|
-
| BodyResponseCallback<Readable>,
|
|
52739
|
-
callback?:
|
|
52740
|
-
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
52741
|
-
| BodyResponseCallback<Readable>
|
|
52742
|
-
):
|
|
52743
|
-
| void
|
|
52744
|
-
| Promise<
|
|
52745
|
-
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
52746
|
-
>
|
|
52747
|
-
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
52748
|
-
let params = (paramsOrCallback ||
|
|
52749
|
-
{}) as Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery;
|
|
52750
|
-
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
52751
|
-
|
|
52752
|
-
if (typeof paramsOrCallback === 'function') {
|
|
52753
|
-
callback = paramsOrCallback;
|
|
52754
|
-
params =
|
|
52755
|
-
{} as Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery;
|
|
52756
|
-
options = {};
|
|
52757
|
-
}
|
|
52758
|
-
|
|
52759
|
-
if (typeof optionsOrCallback === 'function') {
|
|
52760
|
-
callback = optionsOrCallback;
|
|
52761
|
-
options = {};
|
|
52762
|
-
}
|
|
52763
|
-
|
|
52764
|
-
const rootUrl =
|
|
52765
|
-
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
52766
|
-
const parameters = {
|
|
52767
|
-
options: Object.assign(
|
|
52768
|
-
{
|
|
52769
|
-
url: (
|
|
52770
|
-
rootUrl + '/v1alpha/{+completionConfig}:completeQuery'
|
|
52771
|
-
).replace(/([^:]\/)\/+/g, '$1'),
|
|
52772
|
-
method: 'POST',
|
|
52773
|
-
apiVersion: '',
|
|
52774
|
-
},
|
|
52775
|
-
options
|
|
52776
|
-
),
|
|
52777
|
-
params,
|
|
52778
|
-
requiredParams: ['completionConfig'],
|
|
52779
|
-
pathParams: ['completionConfig'],
|
|
52780
|
-
context: this.context,
|
|
52781
|
-
};
|
|
52782
|
-
if (callback) {
|
|
52783
|
-
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>(
|
|
52784
|
-
parameters,
|
|
52785
|
-
callback as BodyResponseCallback<unknown>
|
|
52786
|
-
);
|
|
52787
|
-
} else {
|
|
52788
|
-
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>(
|
|
52789
|
-
parameters
|
|
53258
|
+
export class Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces {
|
|
53259
|
+
context: APIRequestContext;
|
|
53260
|
+
operations: Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations;
|
|
53261
|
+
constructor(context: APIRequestContext) {
|
|
53262
|
+
this.context = context;
|
|
53263
|
+
this.operations =
|
|
53264
|
+
new Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations(
|
|
53265
|
+
this.context
|
|
52790
53266
|
);
|
|
52791
|
-
|
|
53267
|
+
}
|
|
53268
|
+
}
|
|
53269
|
+
|
|
53270
|
+
export class Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations {
|
|
53271
|
+
context: APIRequestContext;
|
|
53272
|
+
constructor(context: APIRequestContext) {
|
|
53273
|
+
this.context = context;
|
|
52792
53274
|
}
|
|
52793
53275
|
|
|
52794
53276
|
/**
|
|
52795
|
-
*
|
|
53277
|
+
* Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.
|
|
52796
53278
|
* @example
|
|
52797
53279
|
* ```js
|
|
52798
53280
|
* // Before running the sample:
|
|
@@ -52815,7 +53297,6 @@ export namespace discoveryengine_v1alpha {
|
|
|
52815
53297
|
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
52816
53298
|
* scopes: [
|
|
52817
53299
|
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
52818
|
-
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
52819
53300
|
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
52820
53301
|
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
52821
53302
|
* ],
|
|
@@ -52827,29 +53308,22 @@ export namespace discoveryengine_v1alpha {
|
|
|
52827
53308
|
*
|
|
52828
53309
|
* // Do the magic
|
|
52829
53310
|
* const res =
|
|
52830
|
-
* await discoveryengine.projects.locations.collections.engines.
|
|
53311
|
+
* await discoveryengine.projects.locations.collections.engines.collaborativeProjects.knowledgeSpaces.operations.get(
|
|
52831
53312
|
* {
|
|
52832
|
-
* //
|
|
52833
|
-
*
|
|
52834
|
-
* 'projects/my-project/locations/my-location/collections/my-collection/engines/my-engine/completionConfig',
|
|
52835
|
-
*
|
|
52836
|
-
* // Request body metadata
|
|
52837
|
-
* requestBody: {
|
|
52838
|
-
* // request body parameters
|
|
52839
|
-
* // {
|
|
52840
|
-
* // "removeAllSearchHistorySuggestions": false,
|
|
52841
|
-
* // "removeTime": "my_removeTime",
|
|
52842
|
-
* // "searchHistorySuggestion": "my_searchHistorySuggestion",
|
|
52843
|
-
* // "userInfo": {},
|
|
52844
|
-
* // "userPseudoId": "my_userPseudoId"
|
|
52845
|
-
* // }
|
|
52846
|
-
* },
|
|
53313
|
+
* // The name of the operation resource.
|
|
53314
|
+
* name: 'projects/my-project/locations/my-location/collections/my-collection/engines/my-engine/collaborativeProjects/my-collaborativeProject/knowledgeSpaces/my-knowledgeSpace/operations/my-operation',
|
|
52847
53315
|
* },
|
|
52848
53316
|
* );
|
|
52849
53317
|
* console.log(res.data);
|
|
52850
53318
|
*
|
|
52851
53319
|
* // Example response
|
|
52852
|
-
* // {
|
|
53320
|
+
* // {
|
|
53321
|
+
* // "done": false,
|
|
53322
|
+
* // "error": {},
|
|
53323
|
+
* // "metadata": {},
|
|
53324
|
+
* // "name": "my_name",
|
|
53325
|
+
* // "response": {}
|
|
53326
|
+
* // }
|
|
52853
53327
|
* }
|
|
52854
53328
|
*
|
|
52855
53329
|
* main().catch(e => {
|
|
@@ -52864,62 +53338,57 @@ export namespace discoveryengine_v1alpha {
|
|
|
52864
53338
|
* @param callback - Optional callback that handles the response.
|
|
52865
53339
|
* @returns A promise if used with async/await, or void if used with a callback.
|
|
52866
53340
|
*/
|
|
52867
|
-
|
|
52868
|
-
params: Params$Resource$Projects$Locations$Collections$Engines$
|
|
53341
|
+
get(
|
|
53342
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get,
|
|
52869
53343
|
options: StreamMethodOptions
|
|
52870
53344
|
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
52871
|
-
|
|
52872
|
-
params?: Params$Resource$Projects$Locations$Collections$Engines$
|
|
53345
|
+
get(
|
|
53346
|
+
params?: Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get,
|
|
52873
53347
|
options?: MethodOptions
|
|
52874
|
-
): Promise<
|
|
52875
|
-
|
|
52876
|
-
|
|
52877
|
-
removeSuggestion(
|
|
52878
|
-
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion,
|
|
53348
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>;
|
|
53349
|
+
get(
|
|
53350
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get,
|
|
52879
53351
|
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
52880
53352
|
callback: BodyResponseCallback<Readable>
|
|
52881
53353
|
): void;
|
|
52882
|
-
|
|
52883
|
-
params: Params$Resource$Projects$Locations$Collections$Engines$
|
|
53354
|
+
get(
|
|
53355
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get,
|
|
52884
53356
|
options:
|
|
52885
|
-
|
|
|
52886
|
-
|
|
52887
|
-
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53357
|
+
MethodOptions | BodyResponseCallback<Schema$GoogleLongrunningOperation>,
|
|
53358
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
52888
53359
|
): void;
|
|
52889
|
-
|
|
52890
|
-
params: Params$Resource$Projects$Locations$Collections$Engines$
|
|
52891
|
-
callback: BodyResponseCallback<Schema$
|
|
53360
|
+
get(
|
|
53361
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get,
|
|
53362
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
52892
53363
|
): void;
|
|
52893
|
-
|
|
52894
|
-
callback: BodyResponseCallback<Schema$
|
|
53364
|
+
get(
|
|
53365
|
+
callback: BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
52895
53366
|
): void;
|
|
52896
|
-
|
|
53367
|
+
get(
|
|
52897
53368
|
paramsOrCallback?:
|
|
52898
|
-
| Params$Resource$Projects$Locations$Collections$Engines$
|
|
52899
|
-
| BodyResponseCallback<Schema$
|
|
53369
|
+
| Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get
|
|
53370
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
52900
53371
|
| BodyResponseCallback<Readable>,
|
|
52901
53372
|
optionsOrCallback?:
|
|
52902
53373
|
| MethodOptions
|
|
52903
53374
|
| StreamMethodOptions
|
|
52904
|
-
| BodyResponseCallback<Schema$
|
|
53375
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
52905
53376
|
| BodyResponseCallback<Readable>,
|
|
52906
53377
|
callback?:
|
|
52907
|
-
| BodyResponseCallback<Schema$
|
|
53378
|
+
| BodyResponseCallback<Schema$GoogleLongrunningOperation>
|
|
52908
53379
|
| BodyResponseCallback<Readable>
|
|
52909
53380
|
):
|
|
52910
53381
|
| void
|
|
52911
|
-
| Promise<
|
|
52912
|
-
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
52913
|
-
>
|
|
53382
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleLongrunningOperation>>
|
|
52914
53383
|
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
52915
53384
|
let params = (paramsOrCallback ||
|
|
52916
|
-
{}) as Params$Resource$Projects$Locations$Collections$Engines$
|
|
53385
|
+
{}) as Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get;
|
|
52917
53386
|
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
52918
53387
|
|
|
52919
53388
|
if (typeof paramsOrCallback === 'function') {
|
|
52920
53389
|
callback = paramsOrCallback;
|
|
52921
53390
|
params =
|
|
52922
|
-
{} as Params$Resource$Projects$Locations$Collections$Engines$
|
|
53391
|
+
{} as Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get;
|
|
52923
53392
|
options = {};
|
|
52924
53393
|
}
|
|
52925
53394
|
|
|
@@ -52933,63 +53402,418 @@ export namespace discoveryengine_v1alpha {
|
|
|
52933
53402
|
const parameters = {
|
|
52934
53403
|
options: Object.assign(
|
|
52935
53404
|
{
|
|
52936
|
-
url: (
|
|
52937
|
-
|
|
52938
|
-
).replace(/([^:]\/)\/+/g, '$1'),
|
|
52939
|
-
method: 'POST',
|
|
53405
|
+
url: (rootUrl + '/v1alpha/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
53406
|
+
method: 'GET',
|
|
52940
53407
|
apiVersion: '',
|
|
52941
53408
|
},
|
|
52942
53409
|
options
|
|
52943
53410
|
),
|
|
52944
53411
|
params,
|
|
52945
|
-
requiredParams: ['
|
|
52946
|
-
pathParams: ['
|
|
53412
|
+
requiredParams: ['name'],
|
|
53413
|
+
pathParams: ['name'],
|
|
52947
53414
|
context: this.context,
|
|
52948
53415
|
};
|
|
52949
53416
|
if (callback) {
|
|
52950
|
-
createAPIRequest<Schema$
|
|
53417
|
+
createAPIRequest<Schema$GoogleLongrunningOperation>(
|
|
52951
53418
|
parameters,
|
|
52952
53419
|
callback as BodyResponseCallback<unknown>
|
|
52953
53420
|
);
|
|
52954
53421
|
} else {
|
|
52955
|
-
return createAPIRequest<Schema$
|
|
52956
|
-
parameters
|
|
52957
|
-
);
|
|
53422
|
+
return createAPIRequest<Schema$GoogleLongrunningOperation>(parameters);
|
|
52958
53423
|
}
|
|
52959
53424
|
}
|
|
52960
53425
|
}
|
|
52961
53426
|
|
|
52962
|
-
export interface Params$Resource$Projects$Locations$Collections$Engines$
|
|
52963
|
-
/**
|
|
52964
|
-
* Required. The completion_config of the parent dataStore or engine resource name for which the completion is performed, such as `projects/x/locations/global/collections/default_collection/dataStores/x/completionConfig` `projects/x/locations/global/collections/default_collection/engines/x/completionConfig`.
|
|
52965
|
-
*/
|
|
52966
|
-
completionConfig?: string;
|
|
52967
|
-
|
|
52968
|
-
/**
|
|
52969
|
-
* Request body metadata
|
|
52970
|
-
*/
|
|
52971
|
-
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequest;
|
|
52972
|
-
}
|
|
52973
|
-
export interface Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion extends StandardParameters {
|
|
52974
|
-
/**
|
|
52975
|
-
* Required. The completion_config of the parent engine resource name for which the search history suggestion is to be removed, such as `projects/x/locations/global/collections/default_collection/engines/x/completionConfig`.
|
|
52976
|
-
*/
|
|
52977
|
-
completionConfig?: string;
|
|
52978
|
-
|
|
53427
|
+
export interface Params$Resource$Projects$Locations$Collections$Engines$Collaborativeprojects$Knowledgespaces$Operations$Get extends StandardParameters {
|
|
52979
53428
|
/**
|
|
52980
|
-
*
|
|
53429
|
+
* The name of the operation resource.
|
|
52981
53430
|
*/
|
|
52982
|
-
|
|
53431
|
+
name?: string;
|
|
52983
53432
|
}
|
|
52984
53433
|
|
|
52985
|
-
export class Resource$Projects$Locations$Collections$Engines$
|
|
53434
|
+
export class Resource$Projects$Locations$Collections$Engines$Completionconfig {
|
|
52986
53435
|
context: APIRequestContext;
|
|
52987
53436
|
constructor(context: APIRequestContext) {
|
|
52988
53437
|
this.context = context;
|
|
52989
53438
|
}
|
|
52990
53439
|
|
|
52991
53440
|
/**
|
|
52992
|
-
*
|
|
53441
|
+
* Completes the user input with advanced keyword suggestions.
|
|
53442
|
+
* @example
|
|
53443
|
+
* ```js
|
|
53444
|
+
* // Before running the sample:
|
|
53445
|
+
* // - Enable the API at:
|
|
53446
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
53447
|
+
* // - Login into gcloud by running:
|
|
53448
|
+
* // ```sh
|
|
53449
|
+
* // $ gcloud auth application-default login
|
|
53450
|
+
* // ```
|
|
53451
|
+
* // - Install the npm module by running:
|
|
53452
|
+
* // ```sh
|
|
53453
|
+
* // $ npm install googleapis
|
|
53454
|
+
* // ```
|
|
53455
|
+
*
|
|
53456
|
+
* const {google} = require('googleapis');
|
|
53457
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
53458
|
+
*
|
|
53459
|
+
* async function main() {
|
|
53460
|
+
* const auth = new google.auth.GoogleAuth({
|
|
53461
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
53462
|
+
* scopes: [
|
|
53463
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
53464
|
+
* 'https://www.googleapis.com/auth/cloud_search.query',
|
|
53465
|
+
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
53466
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
53467
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
53468
|
+
* ],
|
|
53469
|
+
* });
|
|
53470
|
+
*
|
|
53471
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
53472
|
+
* const authClient = await auth.getClient();
|
|
53473
|
+
* google.options({auth: authClient});
|
|
53474
|
+
*
|
|
53475
|
+
* // Do the magic
|
|
53476
|
+
* const res =
|
|
53477
|
+
* await discoveryengine.projects.locations.collections.engines.completionConfig.completeQuery(
|
|
53478
|
+
* {
|
|
53479
|
+
* // Required. The completion_config of the parent dataStore or engine resource name for which the completion is performed, such as `projects/x/locations/global/collections/default_collection/dataStores/x/completionConfig` `projects/x/locations/global/collections/default_collection/engines/x/completionConfig`.
|
|
53480
|
+
* completionConfig:
|
|
53481
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/engines/my-engine/completionConfig',
|
|
53482
|
+
*
|
|
53483
|
+
* // Request body metadata
|
|
53484
|
+
* requestBody: {
|
|
53485
|
+
* // request body parameters
|
|
53486
|
+
* // {
|
|
53487
|
+
* // "boostSpec": {},
|
|
53488
|
+
* // "experimentIds": [],
|
|
53489
|
+
* // "includeTailSuggestions": false,
|
|
53490
|
+
* // "query": "my_query",
|
|
53491
|
+
* // "queryModel": "my_queryModel",
|
|
53492
|
+
* // "suggestionTypeSpecs": [],
|
|
53493
|
+
* // "suggestionTypes": [],
|
|
53494
|
+
* // "userInfo": {},
|
|
53495
|
+
* // "userPseudoId": "my_userPseudoId"
|
|
53496
|
+
* // }
|
|
53497
|
+
* },
|
|
53498
|
+
* },
|
|
53499
|
+
* );
|
|
53500
|
+
* console.log(res.data);
|
|
53501
|
+
*
|
|
53502
|
+
* // Example response
|
|
53503
|
+
* // {
|
|
53504
|
+
* // "contentSuggestions": [],
|
|
53505
|
+
* // "peopleSuggestions": [],
|
|
53506
|
+
* // "querySuggestions": [],
|
|
53507
|
+
* // "recentSearchSuggestions": [],
|
|
53508
|
+
* // "tailMatchTriggered": false
|
|
53509
|
+
* // }
|
|
53510
|
+
* }
|
|
53511
|
+
*
|
|
53512
|
+
* main().catch(e => {
|
|
53513
|
+
* console.error(e);
|
|
53514
|
+
* throw e;
|
|
53515
|
+
* });
|
|
53516
|
+
*
|
|
53517
|
+
* ```
|
|
53518
|
+
*
|
|
53519
|
+
* @param params - Parameters for request
|
|
53520
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
53521
|
+
* @param callback - Optional callback that handles the response.
|
|
53522
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
53523
|
+
*/
|
|
53524
|
+
completeQuery(
|
|
53525
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
53526
|
+
options: StreamMethodOptions
|
|
53527
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
53528
|
+
completeQuery(
|
|
53529
|
+
params?: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
53530
|
+
options?: MethodOptions
|
|
53531
|
+
): Promise<
|
|
53532
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
53533
|
+
>;
|
|
53534
|
+
completeQuery(
|
|
53535
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
53536
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
53537
|
+
callback: BodyResponseCallback<Readable>
|
|
53538
|
+
): void;
|
|
53539
|
+
completeQuery(
|
|
53540
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
53541
|
+
options:
|
|
53542
|
+
| MethodOptions
|
|
53543
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>,
|
|
53544
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
53545
|
+
): void;
|
|
53546
|
+
completeQuery(
|
|
53547
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery,
|
|
53548
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
53549
|
+
): void;
|
|
53550
|
+
completeQuery(
|
|
53551
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
53552
|
+
): void;
|
|
53553
|
+
completeQuery(
|
|
53554
|
+
paramsOrCallback?:
|
|
53555
|
+
| Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery
|
|
53556
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
53557
|
+
| BodyResponseCallback<Readable>,
|
|
53558
|
+
optionsOrCallback?:
|
|
53559
|
+
| MethodOptions
|
|
53560
|
+
| StreamMethodOptions
|
|
53561
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
53562
|
+
| BodyResponseCallback<Readable>,
|
|
53563
|
+
callback?:
|
|
53564
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
53565
|
+
| BodyResponseCallback<Readable>
|
|
53566
|
+
):
|
|
53567
|
+
| void
|
|
53568
|
+
| Promise<
|
|
53569
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>
|
|
53570
|
+
>
|
|
53571
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
53572
|
+
let params = (paramsOrCallback ||
|
|
53573
|
+
{}) as Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery;
|
|
53574
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
53575
|
+
|
|
53576
|
+
if (typeof paramsOrCallback === 'function') {
|
|
53577
|
+
callback = paramsOrCallback;
|
|
53578
|
+
params =
|
|
53579
|
+
{} as Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery;
|
|
53580
|
+
options = {};
|
|
53581
|
+
}
|
|
53582
|
+
|
|
53583
|
+
if (typeof optionsOrCallback === 'function') {
|
|
53584
|
+
callback = optionsOrCallback;
|
|
53585
|
+
options = {};
|
|
53586
|
+
}
|
|
53587
|
+
|
|
53588
|
+
const rootUrl =
|
|
53589
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
53590
|
+
const parameters = {
|
|
53591
|
+
options: Object.assign(
|
|
53592
|
+
{
|
|
53593
|
+
url: (
|
|
53594
|
+
rootUrl + '/v1alpha/{+completionConfig}:completeQuery'
|
|
53595
|
+
).replace(/([^:]\/)\/+/g, '$1'),
|
|
53596
|
+
method: 'POST',
|
|
53597
|
+
apiVersion: '',
|
|
53598
|
+
},
|
|
53599
|
+
options
|
|
53600
|
+
),
|
|
53601
|
+
params,
|
|
53602
|
+
requiredParams: ['completionConfig'],
|
|
53603
|
+
pathParams: ['completionConfig'],
|
|
53604
|
+
context: this.context,
|
|
53605
|
+
};
|
|
53606
|
+
if (callback) {
|
|
53607
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>(
|
|
53608
|
+
parameters,
|
|
53609
|
+
callback as BodyResponseCallback<unknown>
|
|
53610
|
+
);
|
|
53611
|
+
} else {
|
|
53612
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryResponse>(
|
|
53613
|
+
parameters
|
|
53614
|
+
);
|
|
53615
|
+
}
|
|
53616
|
+
}
|
|
53617
|
+
|
|
53618
|
+
/**
|
|
53619
|
+
* Removes the search history suggestion in an engine for a user. This will remove the suggestion from being returned in the AdvancedCompleteQueryResponse.recent_search_suggestions for this user. If the user searches the same suggestion again, the new history will override and suggest this suggestion again.
|
|
53620
|
+
* @example
|
|
53621
|
+
* ```js
|
|
53622
|
+
* // Before running the sample:
|
|
53623
|
+
* // - Enable the API at:
|
|
53624
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
53625
|
+
* // - Login into gcloud by running:
|
|
53626
|
+
* // ```sh
|
|
53627
|
+
* // $ gcloud auth application-default login
|
|
53628
|
+
* // ```
|
|
53629
|
+
* // - Install the npm module by running:
|
|
53630
|
+
* // ```sh
|
|
53631
|
+
* // $ npm install googleapis
|
|
53632
|
+
* // ```
|
|
53633
|
+
*
|
|
53634
|
+
* const {google} = require('googleapis');
|
|
53635
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
53636
|
+
*
|
|
53637
|
+
* async function main() {
|
|
53638
|
+
* const auth = new google.auth.GoogleAuth({
|
|
53639
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
53640
|
+
* scopes: [
|
|
53641
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
53642
|
+
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
53643
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
53644
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
53645
|
+
* ],
|
|
53646
|
+
* });
|
|
53647
|
+
*
|
|
53648
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
53649
|
+
* const authClient = await auth.getClient();
|
|
53650
|
+
* google.options({auth: authClient});
|
|
53651
|
+
*
|
|
53652
|
+
* // Do the magic
|
|
53653
|
+
* const res =
|
|
53654
|
+
* await discoveryengine.projects.locations.collections.engines.completionConfig.removeSuggestion(
|
|
53655
|
+
* {
|
|
53656
|
+
* // Required. The completion_config of the parent engine resource name for which the search history suggestion is to be removed, such as `projects/x/locations/global/collections/default_collection/engines/x/completionConfig`.
|
|
53657
|
+
* completionConfig:
|
|
53658
|
+
* 'projects/my-project/locations/my-location/collections/my-collection/engines/my-engine/completionConfig',
|
|
53659
|
+
*
|
|
53660
|
+
* // Request body metadata
|
|
53661
|
+
* requestBody: {
|
|
53662
|
+
* // request body parameters
|
|
53663
|
+
* // {
|
|
53664
|
+
* // "removeAllSearchHistorySuggestions": false,
|
|
53665
|
+
* // "removeTime": "my_removeTime",
|
|
53666
|
+
* // "searchHistorySuggestion": "my_searchHistorySuggestion",
|
|
53667
|
+
* // "userInfo": {},
|
|
53668
|
+
* // "userPseudoId": "my_userPseudoId"
|
|
53669
|
+
* // }
|
|
53670
|
+
* },
|
|
53671
|
+
* },
|
|
53672
|
+
* );
|
|
53673
|
+
* console.log(res.data);
|
|
53674
|
+
*
|
|
53675
|
+
* // Example response
|
|
53676
|
+
* // {}
|
|
53677
|
+
* }
|
|
53678
|
+
*
|
|
53679
|
+
* main().catch(e => {
|
|
53680
|
+
* console.error(e);
|
|
53681
|
+
* throw e;
|
|
53682
|
+
* });
|
|
53683
|
+
*
|
|
53684
|
+
* ```
|
|
53685
|
+
*
|
|
53686
|
+
* @param params - Parameters for request
|
|
53687
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
53688
|
+
* @param callback - Optional callback that handles the response.
|
|
53689
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
53690
|
+
*/
|
|
53691
|
+
removeSuggestion(
|
|
53692
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion,
|
|
53693
|
+
options: StreamMethodOptions
|
|
53694
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
53695
|
+
removeSuggestion(
|
|
53696
|
+
params?: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion,
|
|
53697
|
+
options?: MethodOptions
|
|
53698
|
+
): Promise<
|
|
53699
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53700
|
+
>;
|
|
53701
|
+
removeSuggestion(
|
|
53702
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion,
|
|
53703
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
53704
|
+
callback: BodyResponseCallback<Readable>
|
|
53705
|
+
): void;
|
|
53706
|
+
removeSuggestion(
|
|
53707
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion,
|
|
53708
|
+
options:
|
|
53709
|
+
| MethodOptions
|
|
53710
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>,
|
|
53711
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53712
|
+
): void;
|
|
53713
|
+
removeSuggestion(
|
|
53714
|
+
params: Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion,
|
|
53715
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53716
|
+
): void;
|
|
53717
|
+
removeSuggestion(
|
|
53718
|
+
callback: BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53719
|
+
): void;
|
|
53720
|
+
removeSuggestion(
|
|
53721
|
+
paramsOrCallback?:
|
|
53722
|
+
| Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion
|
|
53723
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53724
|
+
| BodyResponseCallback<Readable>,
|
|
53725
|
+
optionsOrCallback?:
|
|
53726
|
+
| MethodOptions
|
|
53727
|
+
| StreamMethodOptions
|
|
53728
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53729
|
+
| BodyResponseCallback<Readable>,
|
|
53730
|
+
callback?:
|
|
53731
|
+
| BodyResponseCallback<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53732
|
+
| BodyResponseCallback<Readable>
|
|
53733
|
+
):
|
|
53734
|
+
| void
|
|
53735
|
+
| Promise<
|
|
53736
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>
|
|
53737
|
+
>
|
|
53738
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
53739
|
+
let params = (paramsOrCallback ||
|
|
53740
|
+
{}) as Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion;
|
|
53741
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
53742
|
+
|
|
53743
|
+
if (typeof paramsOrCallback === 'function') {
|
|
53744
|
+
callback = paramsOrCallback;
|
|
53745
|
+
params =
|
|
53746
|
+
{} as Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion;
|
|
53747
|
+
options = {};
|
|
53748
|
+
}
|
|
53749
|
+
|
|
53750
|
+
if (typeof optionsOrCallback === 'function') {
|
|
53751
|
+
callback = optionsOrCallback;
|
|
53752
|
+
options = {};
|
|
53753
|
+
}
|
|
53754
|
+
|
|
53755
|
+
const rootUrl =
|
|
53756
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
53757
|
+
const parameters = {
|
|
53758
|
+
options: Object.assign(
|
|
53759
|
+
{
|
|
53760
|
+
url: (
|
|
53761
|
+
rootUrl + '/v1alpha/{+completionConfig}:removeSuggestion'
|
|
53762
|
+
).replace(/([^:]\/)\/+/g, '$1'),
|
|
53763
|
+
method: 'POST',
|
|
53764
|
+
apiVersion: '',
|
|
53765
|
+
},
|
|
53766
|
+
options
|
|
53767
|
+
),
|
|
53768
|
+
params,
|
|
53769
|
+
requiredParams: ['completionConfig'],
|
|
53770
|
+
pathParams: ['completionConfig'],
|
|
53771
|
+
context: this.context,
|
|
53772
|
+
};
|
|
53773
|
+
if (callback) {
|
|
53774
|
+
createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>(
|
|
53775
|
+
parameters,
|
|
53776
|
+
callback as BodyResponseCallback<unknown>
|
|
53777
|
+
);
|
|
53778
|
+
} else {
|
|
53779
|
+
return createAPIRequest<Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionResponse>(
|
|
53780
|
+
parameters
|
|
53781
|
+
);
|
|
53782
|
+
}
|
|
53783
|
+
}
|
|
53784
|
+
}
|
|
53785
|
+
|
|
53786
|
+
export interface Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Completequery extends StandardParameters {
|
|
53787
|
+
/**
|
|
53788
|
+
* Required. The completion_config of the parent dataStore or engine resource name for which the completion is performed, such as `projects/x/locations/global/collections/default_collection/dataStores/x/completionConfig` `projects/x/locations/global/collections/default_collection/engines/x/completionConfig`.
|
|
53789
|
+
*/
|
|
53790
|
+
completionConfig?: string;
|
|
53791
|
+
|
|
53792
|
+
/**
|
|
53793
|
+
* Request body metadata
|
|
53794
|
+
*/
|
|
53795
|
+
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaAdvancedCompleteQueryRequest;
|
|
53796
|
+
}
|
|
53797
|
+
export interface Params$Resource$Projects$Locations$Collections$Engines$Completionconfig$Removesuggestion extends StandardParameters {
|
|
53798
|
+
/**
|
|
53799
|
+
* Required. The completion_config of the parent engine resource name for which the search history suggestion is to be removed, such as `projects/x/locations/global/collections/default_collection/engines/x/completionConfig`.
|
|
53800
|
+
*/
|
|
53801
|
+
completionConfig?: string;
|
|
53802
|
+
|
|
53803
|
+
/**
|
|
53804
|
+
* Request body metadata
|
|
53805
|
+
*/
|
|
53806
|
+
requestBody?: Schema$GoogleCloudDiscoveryengineV1alphaRemoveSuggestionRequest;
|
|
53807
|
+
}
|
|
53808
|
+
|
|
53809
|
+
export class Resource$Projects$Locations$Collections$Engines$Controls {
|
|
53810
|
+
context: APIRequestContext;
|
|
53811
|
+
constructor(context: APIRequestContext) {
|
|
53812
|
+
this.context = context;
|
|
53813
|
+
}
|
|
53814
|
+
|
|
53815
|
+
/**
|
|
53816
|
+
* Creates a Control. By default 1000 controls are allowed for a data store. A request can be submitted to adjust this limit. If the Control to create already exists, an ALREADY_EXISTS error is returned.
|
|
52993
53817
|
* @example
|
|
52994
53818
|
* ```js
|
|
52995
53819
|
* // Before running the sample:
|
|
@@ -81127,6 +81951,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
81127
81951
|
* // {
|
|
81128
81952
|
* // "alertPolicyResourceConfig": {},
|
|
81129
81953
|
* // "autoRenew": false,
|
|
81954
|
+
* // "billingAccountLicenseConfig": "my_billingAccountLicenseConfig",
|
|
81130
81955
|
* // "earlyTerminated": false,
|
|
81131
81956
|
* // "earlyTerminationDate": {},
|
|
81132
81957
|
* // "endDate": {},
|
|
@@ -81148,6 +81973,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
81148
81973
|
* // {
|
|
81149
81974
|
* // "alertPolicyResourceConfig": {},
|
|
81150
81975
|
* // "autoRenew": false,
|
|
81976
|
+
* // "billingAccountLicenseConfig": "my_billingAccountLicenseConfig",
|
|
81151
81977
|
* // "earlyTerminated": false,
|
|
81152
81978
|
* // "earlyTerminationDate": {},
|
|
81153
81979
|
* // "endDate": {},
|
|
@@ -81313,6 +82139,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
81313
82139
|
* // {
|
|
81314
82140
|
* // "alertPolicyResourceConfig": {},
|
|
81315
82141
|
* // "autoRenew": false,
|
|
82142
|
+
* // "billingAccountLicenseConfig": "my_billingAccountLicenseConfig",
|
|
81316
82143
|
* // "earlyTerminated": false,
|
|
81317
82144
|
* // "earlyTerminationDate": {},
|
|
81318
82145
|
* // "endDate": {},
|
|
@@ -81636,6 +82463,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
81636
82463
|
* // {
|
|
81637
82464
|
* // "alertPolicyResourceConfig": {},
|
|
81638
82465
|
* // "autoRenew": false,
|
|
82466
|
+
* // "billingAccountLicenseConfig": "my_billingAccountLicenseConfig",
|
|
81639
82467
|
* // "earlyTerminated": false,
|
|
81640
82468
|
* // "earlyTerminationDate": {},
|
|
81641
82469
|
* // "endDate": {},
|
|
@@ -81657,6 +82485,7 @@ export namespace discoveryengine_v1alpha {
|
|
|
81657
82485
|
* // {
|
|
81658
82486
|
* // "alertPolicyResourceConfig": {},
|
|
81659
82487
|
* // "autoRenew": false,
|
|
82488
|
+
* // "billingAccountLicenseConfig": "my_billingAccountLicenseConfig",
|
|
81660
82489
|
* // "earlyTerminated": false,
|
|
81661
82490
|
* // "earlyTerminationDate": {},
|
|
81662
82491
|
* // "endDate": {},
|
|
@@ -81834,13 +82663,865 @@ export namespace discoveryengine_v1alpha {
|
|
|
81834
82663
|
export class Resource$Projects$Locations$Notebooks {
|
|
81835
82664
|
context: APIRequestContext;
|
|
81836
82665
|
audioOverviews: Resource$Projects$Locations$Notebooks$Audiooverviews;
|
|
82666
|
+
sources: Resource$Projects$Locations$Notebooks$Sources;
|
|
81837
82667
|
constructor(context: APIRequestContext) {
|
|
81838
82668
|
this.context = context;
|
|
81839
82669
|
this.audioOverviews =
|
|
81840
82670
|
new Resource$Projects$Locations$Notebooks$Audiooverviews(this.context);
|
|
82671
|
+
this.sources = new Resource$Projects$Locations$Notebooks$Sources(
|
|
82672
|
+
this.context
|
|
82673
|
+
);
|
|
82674
|
+
}
|
|
82675
|
+
|
|
82676
|
+
/**
|
|
82677
|
+
* Batch deletes Notebooks.
|
|
82678
|
+
* @example
|
|
82679
|
+
* ```js
|
|
82680
|
+
* // Before running the sample:
|
|
82681
|
+
* // - Enable the API at:
|
|
82682
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
82683
|
+
* // - Login into gcloud by running:
|
|
82684
|
+
* // ```sh
|
|
82685
|
+
* // $ gcloud auth application-default login
|
|
82686
|
+
* // ```
|
|
82687
|
+
* // - Install the npm module by running:
|
|
82688
|
+
* // ```sh
|
|
82689
|
+
* // $ npm install googleapis
|
|
82690
|
+
* // ```
|
|
82691
|
+
*
|
|
82692
|
+
* const {google} = require('googleapis');
|
|
82693
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
82694
|
+
*
|
|
82695
|
+
* async function main() {
|
|
82696
|
+
* const auth = new google.auth.GoogleAuth({
|
|
82697
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
82698
|
+
* scopes: [
|
|
82699
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
82700
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
82701
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
82702
|
+
* ],
|
|
82703
|
+
* });
|
|
82704
|
+
*
|
|
82705
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
82706
|
+
* const authClient = await auth.getClient();
|
|
82707
|
+
* google.options({auth: authClient});
|
|
82708
|
+
*
|
|
82709
|
+
* // Do the magic
|
|
82710
|
+
* const res = await discoveryengine.projects.locations.notebooks.batchDelete({
|
|
82711
|
+
* // Required. The parent branch resource name, such as `projects/{project\}/locations/{location\}`.
|
|
82712
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
82713
|
+
*
|
|
82714
|
+
* // Request body metadata
|
|
82715
|
+
* requestBody: {
|
|
82716
|
+
* // request body parameters
|
|
82717
|
+
* // {
|
|
82718
|
+
* // "names": []
|
|
82719
|
+
* // }
|
|
82720
|
+
* },
|
|
82721
|
+
* });
|
|
82722
|
+
* console.log(res.data);
|
|
82723
|
+
*
|
|
82724
|
+
* // Example response
|
|
82725
|
+
* // {}
|
|
82726
|
+
* }
|
|
82727
|
+
*
|
|
82728
|
+
* main().catch(e => {
|
|
82729
|
+
* console.error(e);
|
|
82730
|
+
* throw e;
|
|
82731
|
+
* });
|
|
82732
|
+
*
|
|
82733
|
+
* ```
|
|
82734
|
+
*
|
|
82735
|
+
* @param params - Parameters for request
|
|
82736
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
82737
|
+
* @param callback - Optional callback that handles the response.
|
|
82738
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
82739
|
+
*/
|
|
82740
|
+
batchDelete(
|
|
82741
|
+
params: Params$Resource$Projects$Locations$Notebooks$Batchdelete,
|
|
82742
|
+
options: StreamMethodOptions
|
|
82743
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
82744
|
+
batchDelete(
|
|
82745
|
+
params?: Params$Resource$Projects$Locations$Notebooks$Batchdelete,
|
|
82746
|
+
options?: MethodOptions
|
|
82747
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleProtobufEmpty>>;
|
|
82748
|
+
batchDelete(
|
|
82749
|
+
params: Params$Resource$Projects$Locations$Notebooks$Batchdelete,
|
|
82750
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
82751
|
+
callback: BodyResponseCallback<Readable>
|
|
82752
|
+
): void;
|
|
82753
|
+
batchDelete(
|
|
82754
|
+
params: Params$Resource$Projects$Locations$Notebooks$Batchdelete,
|
|
82755
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleProtobufEmpty>,
|
|
82756
|
+
callback: BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
82757
|
+
): void;
|
|
82758
|
+
batchDelete(
|
|
82759
|
+
params: Params$Resource$Projects$Locations$Notebooks$Batchdelete,
|
|
82760
|
+
callback: BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
82761
|
+
): void;
|
|
82762
|
+
batchDelete(
|
|
82763
|
+
callback: BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
82764
|
+
): void;
|
|
82765
|
+
batchDelete(
|
|
82766
|
+
paramsOrCallback?:
|
|
82767
|
+
| Params$Resource$Projects$Locations$Notebooks$Batchdelete
|
|
82768
|
+
| BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
82769
|
+
| BodyResponseCallback<Readable>,
|
|
82770
|
+
optionsOrCallback?:
|
|
82771
|
+
| MethodOptions
|
|
82772
|
+
| StreamMethodOptions
|
|
82773
|
+
| BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
82774
|
+
| BodyResponseCallback<Readable>,
|
|
82775
|
+
callback?:
|
|
82776
|
+
| BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
82777
|
+
| BodyResponseCallback<Readable>
|
|
82778
|
+
):
|
|
82779
|
+
| void
|
|
82780
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleProtobufEmpty>>
|
|
82781
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
82782
|
+
let params = (paramsOrCallback ||
|
|
82783
|
+
{}) as Params$Resource$Projects$Locations$Notebooks$Batchdelete;
|
|
82784
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
82785
|
+
|
|
82786
|
+
if (typeof paramsOrCallback === 'function') {
|
|
82787
|
+
callback = paramsOrCallback;
|
|
82788
|
+
params = {} as Params$Resource$Projects$Locations$Notebooks$Batchdelete;
|
|
82789
|
+
options = {};
|
|
82790
|
+
}
|
|
82791
|
+
|
|
82792
|
+
if (typeof optionsOrCallback === 'function') {
|
|
82793
|
+
callback = optionsOrCallback;
|
|
82794
|
+
options = {};
|
|
82795
|
+
}
|
|
82796
|
+
|
|
82797
|
+
const rootUrl =
|
|
82798
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
82799
|
+
const parameters = {
|
|
82800
|
+
options: Object.assign(
|
|
82801
|
+
{
|
|
82802
|
+
url: (rootUrl + '/v1alpha/{+parent}/notebooks:batchDelete').replace(
|
|
82803
|
+
/([^:]\/)\/+/g,
|
|
82804
|
+
'$1'
|
|
82805
|
+
),
|
|
82806
|
+
method: 'POST',
|
|
82807
|
+
apiVersion: '',
|
|
82808
|
+
},
|
|
82809
|
+
options
|
|
82810
|
+
),
|
|
82811
|
+
params,
|
|
82812
|
+
requiredParams: ['parent'],
|
|
82813
|
+
pathParams: ['parent'],
|
|
82814
|
+
context: this.context,
|
|
82815
|
+
};
|
|
82816
|
+
if (callback) {
|
|
82817
|
+
createAPIRequest<Schema$GoogleProtobufEmpty>(
|
|
82818
|
+
parameters,
|
|
82819
|
+
callback as BodyResponseCallback<unknown>
|
|
82820
|
+
);
|
|
82821
|
+
} else {
|
|
82822
|
+
return createAPIRequest<Schema$GoogleProtobufEmpty>(parameters);
|
|
82823
|
+
}
|
|
82824
|
+
}
|
|
82825
|
+
|
|
82826
|
+
/**
|
|
82827
|
+
* Creates a notebook.
|
|
82828
|
+
* @example
|
|
82829
|
+
* ```js
|
|
82830
|
+
* // Before running the sample:
|
|
82831
|
+
* // - Enable the API at:
|
|
82832
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
82833
|
+
* // - Login into gcloud by running:
|
|
82834
|
+
* // ```sh
|
|
82835
|
+
* // $ gcloud auth application-default login
|
|
82836
|
+
* // ```
|
|
82837
|
+
* // - Install the npm module by running:
|
|
82838
|
+
* // ```sh
|
|
82839
|
+
* // $ npm install googleapis
|
|
82840
|
+
* // ```
|
|
82841
|
+
*
|
|
82842
|
+
* const {google} = require('googleapis');
|
|
82843
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
82844
|
+
*
|
|
82845
|
+
* async function main() {
|
|
82846
|
+
* const auth = new google.auth.GoogleAuth({
|
|
82847
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
82848
|
+
* scopes: [
|
|
82849
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
82850
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
82851
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
82852
|
+
* ],
|
|
82853
|
+
* });
|
|
82854
|
+
*
|
|
82855
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
82856
|
+
* const authClient = await auth.getClient();
|
|
82857
|
+
* google.options({auth: authClient});
|
|
82858
|
+
*
|
|
82859
|
+
* // Do the magic
|
|
82860
|
+
* const res = await discoveryengine.projects.locations.notebooks.create({
|
|
82861
|
+
* // Required. The parent resource name, such as `projects/{project\}/locations/{location\}`.
|
|
82862
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
82863
|
+
*
|
|
82864
|
+
* // Request body metadata
|
|
82865
|
+
* requestBody: {
|
|
82866
|
+
* // request body parameters
|
|
82867
|
+
* // {
|
|
82868
|
+
* // "cmekConfig": {},
|
|
82869
|
+
* // "emoji": "my_emoji",
|
|
82870
|
+
* // "metadata": {},
|
|
82871
|
+
* // "name": "my_name",
|
|
82872
|
+
* // "notebookId": "my_notebookId",
|
|
82873
|
+
* // "sources": [],
|
|
82874
|
+
* // "title": "my_title"
|
|
82875
|
+
* // }
|
|
82876
|
+
* },
|
|
82877
|
+
* });
|
|
82878
|
+
* console.log(res.data);
|
|
82879
|
+
*
|
|
82880
|
+
* // Example response
|
|
82881
|
+
* // {
|
|
82882
|
+
* // "cmekConfig": {},
|
|
82883
|
+
* // "emoji": "my_emoji",
|
|
82884
|
+
* // "metadata": {},
|
|
82885
|
+
* // "name": "my_name",
|
|
82886
|
+
* // "notebookId": "my_notebookId",
|
|
82887
|
+
* // "sources": [],
|
|
82888
|
+
* // "title": "my_title"
|
|
82889
|
+
* // }
|
|
82890
|
+
* }
|
|
82891
|
+
*
|
|
82892
|
+
* main().catch(e => {
|
|
82893
|
+
* console.error(e);
|
|
82894
|
+
* throw e;
|
|
82895
|
+
* });
|
|
82896
|
+
*
|
|
82897
|
+
* ```
|
|
82898
|
+
*
|
|
82899
|
+
* @param params - Parameters for request
|
|
82900
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
82901
|
+
* @param callback - Optional callback that handles the response.
|
|
82902
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
82903
|
+
*/
|
|
82904
|
+
create(
|
|
82905
|
+
params: Params$Resource$Projects$Locations$Notebooks$Create,
|
|
82906
|
+
options: StreamMethodOptions
|
|
82907
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
82908
|
+
create(
|
|
82909
|
+
params?: Params$Resource$Projects$Locations$Notebooks$Create,
|
|
82910
|
+
options?: MethodOptions
|
|
82911
|
+
): Promise<
|
|
82912
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
82913
|
+
>;
|
|
82914
|
+
create(
|
|
82915
|
+
params: Params$Resource$Projects$Locations$Notebooks$Create,
|
|
82916
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
82917
|
+
callback: BodyResponseCallback<Readable>
|
|
82918
|
+
): void;
|
|
82919
|
+
create(
|
|
82920
|
+
params: Params$Resource$Projects$Locations$Notebooks$Create,
|
|
82921
|
+
options:
|
|
82922
|
+
| MethodOptions
|
|
82923
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>,
|
|
82924
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
82925
|
+
): void;
|
|
82926
|
+
create(
|
|
82927
|
+
params: Params$Resource$Projects$Locations$Notebooks$Create,
|
|
82928
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
82929
|
+
): void;
|
|
82930
|
+
create(
|
|
82931
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
82932
|
+
): void;
|
|
82933
|
+
create(
|
|
82934
|
+
paramsOrCallback?:
|
|
82935
|
+
| Params$Resource$Projects$Locations$Notebooks$Create
|
|
82936
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
82937
|
+
| BodyResponseCallback<Readable>,
|
|
82938
|
+
optionsOrCallback?:
|
|
82939
|
+
| MethodOptions
|
|
82940
|
+
| StreamMethodOptions
|
|
82941
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
82942
|
+
| BodyResponseCallback<Readable>,
|
|
82943
|
+
callback?:
|
|
82944
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
82945
|
+
| BodyResponseCallback<Readable>
|
|
82946
|
+
):
|
|
82947
|
+
| void
|
|
82948
|
+
| Promise<
|
|
82949
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
82950
|
+
>
|
|
82951
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
82952
|
+
let params = (paramsOrCallback ||
|
|
82953
|
+
{}) as Params$Resource$Projects$Locations$Notebooks$Create;
|
|
82954
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
82955
|
+
|
|
82956
|
+
if (typeof paramsOrCallback === 'function') {
|
|
82957
|
+
callback = paramsOrCallback;
|
|
82958
|
+
params = {} as Params$Resource$Projects$Locations$Notebooks$Create;
|
|
82959
|
+
options = {};
|
|
82960
|
+
}
|
|
82961
|
+
|
|
82962
|
+
if (typeof optionsOrCallback === 'function') {
|
|
82963
|
+
callback = optionsOrCallback;
|
|
82964
|
+
options = {};
|
|
82965
|
+
}
|
|
82966
|
+
|
|
82967
|
+
const rootUrl =
|
|
82968
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
82969
|
+
const parameters = {
|
|
82970
|
+
options: Object.assign(
|
|
82971
|
+
{
|
|
82972
|
+
url: (rootUrl + '/v1alpha/{+parent}/notebooks').replace(
|
|
82973
|
+
/([^:]\/)\/+/g,
|
|
82974
|
+
'$1'
|
|
82975
|
+
),
|
|
82976
|
+
method: 'POST',
|
|
82977
|
+
apiVersion: '',
|
|
82978
|
+
},
|
|
82979
|
+
options
|
|
82980
|
+
),
|
|
82981
|
+
params,
|
|
82982
|
+
requiredParams: ['parent'],
|
|
82983
|
+
pathParams: ['parent'],
|
|
82984
|
+
context: this.context,
|
|
82985
|
+
};
|
|
82986
|
+
if (callback) {
|
|
82987
|
+
createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaNotebook>(
|
|
82988
|
+
parameters,
|
|
82989
|
+
callback as BodyResponseCallback<unknown>
|
|
82990
|
+
);
|
|
82991
|
+
} else {
|
|
82992
|
+
return createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaNotebook>(
|
|
82993
|
+
parameters
|
|
82994
|
+
);
|
|
82995
|
+
}
|
|
82996
|
+
}
|
|
82997
|
+
|
|
82998
|
+
/**
|
|
82999
|
+
* Gets a notebook.
|
|
83000
|
+
* @example
|
|
83001
|
+
* ```js
|
|
83002
|
+
* // Before running the sample:
|
|
83003
|
+
* // - Enable the API at:
|
|
83004
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
83005
|
+
* // - Login into gcloud by running:
|
|
83006
|
+
* // ```sh
|
|
83007
|
+
* // $ gcloud auth application-default login
|
|
83008
|
+
* // ```
|
|
83009
|
+
* // - Install the npm module by running:
|
|
83010
|
+
* // ```sh
|
|
83011
|
+
* // $ npm install googleapis
|
|
83012
|
+
* // ```
|
|
83013
|
+
*
|
|
83014
|
+
* const {google} = require('googleapis');
|
|
83015
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
83016
|
+
*
|
|
83017
|
+
* async function main() {
|
|
83018
|
+
* const auth = new google.auth.GoogleAuth({
|
|
83019
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
83020
|
+
* scopes: [
|
|
83021
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
83022
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
83023
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
83024
|
+
* ],
|
|
83025
|
+
* });
|
|
83026
|
+
*
|
|
83027
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
83028
|
+
* const authClient = await auth.getClient();
|
|
83029
|
+
* google.options({auth: authClient});
|
|
83030
|
+
*
|
|
83031
|
+
* // Do the magic
|
|
83032
|
+
* const res = await discoveryengine.projects.locations.notebooks.get({
|
|
83033
|
+
* // Required. Full resource name of Notebook, such as `projects/{project\}/locations/{location\}/notebooks/{notebook_id\}`.
|
|
83034
|
+
* name: 'projects/my-project/locations/my-location/notebooks/my-notebook',
|
|
83035
|
+
* });
|
|
83036
|
+
* console.log(res.data);
|
|
83037
|
+
*
|
|
83038
|
+
* // Example response
|
|
83039
|
+
* // {
|
|
83040
|
+
* // "cmekConfig": {},
|
|
83041
|
+
* // "emoji": "my_emoji",
|
|
83042
|
+
* // "metadata": {},
|
|
83043
|
+
* // "name": "my_name",
|
|
83044
|
+
* // "notebookId": "my_notebookId",
|
|
83045
|
+
* // "sources": [],
|
|
83046
|
+
* // "title": "my_title"
|
|
83047
|
+
* // }
|
|
83048
|
+
* }
|
|
83049
|
+
*
|
|
83050
|
+
* main().catch(e => {
|
|
83051
|
+
* console.error(e);
|
|
83052
|
+
* throw e;
|
|
83053
|
+
* });
|
|
83054
|
+
*
|
|
83055
|
+
* ```
|
|
83056
|
+
*
|
|
83057
|
+
* @param params - Parameters for request
|
|
83058
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
83059
|
+
* @param callback - Optional callback that handles the response.
|
|
83060
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
83061
|
+
*/
|
|
83062
|
+
get(
|
|
83063
|
+
params: Params$Resource$Projects$Locations$Notebooks$Get,
|
|
83064
|
+
options: StreamMethodOptions
|
|
83065
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
83066
|
+
get(
|
|
83067
|
+
params?: Params$Resource$Projects$Locations$Notebooks$Get,
|
|
83068
|
+
options?: MethodOptions
|
|
83069
|
+
): Promise<
|
|
83070
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
83071
|
+
>;
|
|
83072
|
+
get(
|
|
83073
|
+
params: Params$Resource$Projects$Locations$Notebooks$Get,
|
|
83074
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
83075
|
+
callback: BodyResponseCallback<Readable>
|
|
83076
|
+
): void;
|
|
83077
|
+
get(
|
|
83078
|
+
params: Params$Resource$Projects$Locations$Notebooks$Get,
|
|
83079
|
+
options:
|
|
83080
|
+
| MethodOptions
|
|
83081
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>,
|
|
83082
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
83083
|
+
): void;
|
|
83084
|
+
get(
|
|
83085
|
+
params: Params$Resource$Projects$Locations$Notebooks$Get,
|
|
83086
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
83087
|
+
): void;
|
|
83088
|
+
get(
|
|
83089
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
83090
|
+
): void;
|
|
83091
|
+
get(
|
|
83092
|
+
paramsOrCallback?:
|
|
83093
|
+
| Params$Resource$Projects$Locations$Notebooks$Get
|
|
83094
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
83095
|
+
| BodyResponseCallback<Readable>,
|
|
83096
|
+
optionsOrCallback?:
|
|
83097
|
+
| MethodOptions
|
|
83098
|
+
| StreamMethodOptions
|
|
83099
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
83100
|
+
| BodyResponseCallback<Readable>,
|
|
83101
|
+
callback?:
|
|
83102
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
83103
|
+
| BodyResponseCallback<Readable>
|
|
83104
|
+
):
|
|
83105
|
+
| void
|
|
83106
|
+
| Promise<
|
|
83107
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaNotebook>
|
|
83108
|
+
>
|
|
83109
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
83110
|
+
let params = (paramsOrCallback ||
|
|
83111
|
+
{}) as Params$Resource$Projects$Locations$Notebooks$Get;
|
|
83112
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
83113
|
+
|
|
83114
|
+
if (typeof paramsOrCallback === 'function') {
|
|
83115
|
+
callback = paramsOrCallback;
|
|
83116
|
+
params = {} as Params$Resource$Projects$Locations$Notebooks$Get;
|
|
83117
|
+
options = {};
|
|
83118
|
+
}
|
|
83119
|
+
|
|
83120
|
+
if (typeof optionsOrCallback === 'function') {
|
|
83121
|
+
callback = optionsOrCallback;
|
|
83122
|
+
options = {};
|
|
83123
|
+
}
|
|
83124
|
+
|
|
83125
|
+
const rootUrl =
|
|
83126
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
83127
|
+
const parameters = {
|
|
83128
|
+
options: Object.assign(
|
|
83129
|
+
{
|
|
83130
|
+
url: (rootUrl + '/v1alpha/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
83131
|
+
method: 'GET',
|
|
83132
|
+
apiVersion: '',
|
|
83133
|
+
},
|
|
83134
|
+
options
|
|
83135
|
+
),
|
|
83136
|
+
params,
|
|
83137
|
+
requiredParams: ['name'],
|
|
83138
|
+
pathParams: ['name'],
|
|
83139
|
+
context: this.context,
|
|
83140
|
+
};
|
|
83141
|
+
if (callback) {
|
|
83142
|
+
createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaNotebook>(
|
|
83143
|
+
parameters,
|
|
83144
|
+
callback as BodyResponseCallback<unknown>
|
|
83145
|
+
);
|
|
83146
|
+
} else {
|
|
83147
|
+
return createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaNotebook>(
|
|
83148
|
+
parameters
|
|
83149
|
+
);
|
|
83150
|
+
}
|
|
83151
|
+
}
|
|
83152
|
+
|
|
83153
|
+
/**
|
|
83154
|
+
* Lists the notebooks ordered by last view time.
|
|
83155
|
+
* @example
|
|
83156
|
+
* ```js
|
|
83157
|
+
* // Before running the sample:
|
|
83158
|
+
* // - Enable the API at:
|
|
83159
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
83160
|
+
* // - Login into gcloud by running:
|
|
83161
|
+
* // ```sh
|
|
83162
|
+
* // $ gcloud auth application-default login
|
|
83163
|
+
* // ```
|
|
83164
|
+
* // - Install the npm module by running:
|
|
83165
|
+
* // ```sh
|
|
83166
|
+
* // $ npm install googleapis
|
|
83167
|
+
* // ```
|
|
83168
|
+
*
|
|
83169
|
+
* const {google} = require('googleapis');
|
|
83170
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
83171
|
+
*
|
|
83172
|
+
* async function main() {
|
|
83173
|
+
* const auth = new google.auth.GoogleAuth({
|
|
83174
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
83175
|
+
* scopes: [
|
|
83176
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
83177
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
83178
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
83179
|
+
* ],
|
|
83180
|
+
* });
|
|
83181
|
+
*
|
|
83182
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
83183
|
+
* const authClient = await auth.getClient();
|
|
83184
|
+
* google.options({auth: authClient});
|
|
83185
|
+
*
|
|
83186
|
+
* // Do the magic
|
|
83187
|
+
* const res =
|
|
83188
|
+
* await discoveryengine.projects.locations.notebooks.listRecentlyViewed({
|
|
83189
|
+
* // Optional. Maximum number of Notebooks to return. If unspecified, defaults to "500". The maximum allowed value is "500". If this field is negative, will use the default value.
|
|
83190
|
+
* pageSize: 'placeholder-value',
|
|
83191
|
+
* // Optional. The page token, provide this to retrieve the subsequent page.
|
|
83192
|
+
* pageToken: 'placeholder-value',
|
|
83193
|
+
* // Required. The parent branch resource name, such as `projects/{project\}/locations/{location\}`.
|
|
83194
|
+
* parent: 'projects/my-project/locations/my-location',
|
|
83195
|
+
* });
|
|
83196
|
+
* console.log(res.data);
|
|
83197
|
+
*
|
|
83198
|
+
* // Example response
|
|
83199
|
+
* // {
|
|
83200
|
+
* // "nextPageToken": "my_nextPageToken",
|
|
83201
|
+
* // "notebooks": []
|
|
83202
|
+
* // }
|
|
83203
|
+
* }
|
|
83204
|
+
*
|
|
83205
|
+
* main().catch(e => {
|
|
83206
|
+
* console.error(e);
|
|
83207
|
+
* throw e;
|
|
83208
|
+
* });
|
|
83209
|
+
*
|
|
83210
|
+
* ```
|
|
83211
|
+
*
|
|
83212
|
+
* @param params - Parameters for request
|
|
83213
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
83214
|
+
* @param callback - Optional callback that handles the response.
|
|
83215
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
83216
|
+
*/
|
|
83217
|
+
listRecentlyViewed(
|
|
83218
|
+
params: Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed,
|
|
83219
|
+
options: StreamMethodOptions
|
|
83220
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
83221
|
+
listRecentlyViewed(
|
|
83222
|
+
params?: Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed,
|
|
83223
|
+
options?: MethodOptions
|
|
83224
|
+
): Promise<
|
|
83225
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>
|
|
83226
|
+
>;
|
|
83227
|
+
listRecentlyViewed(
|
|
83228
|
+
params: Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed,
|
|
83229
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
83230
|
+
callback: BodyResponseCallback<Readable>
|
|
83231
|
+
): void;
|
|
83232
|
+
listRecentlyViewed(
|
|
83233
|
+
params: Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed,
|
|
83234
|
+
options:
|
|
83235
|
+
| MethodOptions
|
|
83236
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>,
|
|
83237
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>
|
|
83238
|
+
): void;
|
|
83239
|
+
listRecentlyViewed(
|
|
83240
|
+
params: Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed,
|
|
83241
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>
|
|
83242
|
+
): void;
|
|
83243
|
+
listRecentlyViewed(
|
|
83244
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>
|
|
83245
|
+
): void;
|
|
83246
|
+
listRecentlyViewed(
|
|
83247
|
+
paramsOrCallback?:
|
|
83248
|
+
| Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed
|
|
83249
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>
|
|
83250
|
+
| BodyResponseCallback<Readable>,
|
|
83251
|
+
optionsOrCallback?:
|
|
83252
|
+
| MethodOptions
|
|
83253
|
+
| StreamMethodOptions
|
|
83254
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>
|
|
83255
|
+
| BodyResponseCallback<Readable>,
|
|
83256
|
+
callback?:
|
|
83257
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>
|
|
83258
|
+
| BodyResponseCallback<Readable>
|
|
83259
|
+
):
|
|
83260
|
+
| void
|
|
83261
|
+
| Promise<
|
|
83262
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>
|
|
83263
|
+
>
|
|
83264
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
83265
|
+
let params = (paramsOrCallback ||
|
|
83266
|
+
{}) as Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed;
|
|
83267
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
83268
|
+
|
|
83269
|
+
if (typeof paramsOrCallback === 'function') {
|
|
83270
|
+
callback = paramsOrCallback;
|
|
83271
|
+
params =
|
|
83272
|
+
{} as Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed;
|
|
83273
|
+
options = {};
|
|
83274
|
+
}
|
|
83275
|
+
|
|
83276
|
+
if (typeof optionsOrCallback === 'function') {
|
|
83277
|
+
callback = optionsOrCallback;
|
|
83278
|
+
options = {};
|
|
83279
|
+
}
|
|
83280
|
+
|
|
83281
|
+
const rootUrl =
|
|
83282
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
83283
|
+
const parameters = {
|
|
83284
|
+
options: Object.assign(
|
|
83285
|
+
{
|
|
83286
|
+
url: (
|
|
83287
|
+
rootUrl + '/v1alpha/{+parent}/notebooks:listRecentlyViewed'
|
|
83288
|
+
).replace(/([^:]\/)\/+/g, '$1'),
|
|
83289
|
+
method: 'GET',
|
|
83290
|
+
apiVersion: '',
|
|
83291
|
+
},
|
|
83292
|
+
options
|
|
83293
|
+
),
|
|
83294
|
+
params,
|
|
83295
|
+
requiredParams: ['parent'],
|
|
83296
|
+
pathParams: ['parent'],
|
|
83297
|
+
context: this.context,
|
|
83298
|
+
};
|
|
83299
|
+
if (callback) {
|
|
83300
|
+
createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>(
|
|
83301
|
+
parameters,
|
|
83302
|
+
callback as BodyResponseCallback<unknown>
|
|
83303
|
+
);
|
|
83304
|
+
} else {
|
|
83305
|
+
return createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaListRecentlyViewedNotebooksResponse>(
|
|
83306
|
+
parameters
|
|
83307
|
+
);
|
|
83308
|
+
}
|
|
83309
|
+
}
|
|
83310
|
+
|
|
83311
|
+
/**
|
|
83312
|
+
* Shares a notebook to other accounts.
|
|
83313
|
+
* @example
|
|
83314
|
+
* ```js
|
|
83315
|
+
* // Before running the sample:
|
|
83316
|
+
* // - Enable the API at:
|
|
83317
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
83318
|
+
* // - Login into gcloud by running:
|
|
83319
|
+
* // ```sh
|
|
83320
|
+
* // $ gcloud auth application-default login
|
|
83321
|
+
* // ```
|
|
83322
|
+
* // - Install the npm module by running:
|
|
83323
|
+
* // ```sh
|
|
83324
|
+
* // $ npm install googleapis
|
|
83325
|
+
* // ```
|
|
83326
|
+
*
|
|
83327
|
+
* const {google} = require('googleapis');
|
|
83328
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
83329
|
+
*
|
|
83330
|
+
* async function main() {
|
|
83331
|
+
* const auth = new google.auth.GoogleAuth({
|
|
83332
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
83333
|
+
* scopes: [
|
|
83334
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
83335
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
83336
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
83337
|
+
* ],
|
|
83338
|
+
* });
|
|
83339
|
+
*
|
|
83340
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
83341
|
+
* const authClient = await auth.getClient();
|
|
83342
|
+
* google.options({auth: authClient});
|
|
83343
|
+
*
|
|
83344
|
+
* // Do the magic
|
|
83345
|
+
* const res = await discoveryengine.projects.locations.notebooks.share({
|
|
83346
|
+
* // Required. Full resource name of Notebook, such as `projects/{project\}/locations/{location\}/notebooks/{notebook_id\}`.
|
|
83347
|
+
* name: 'projects/my-project/locations/my-location/notebooks/my-notebook',
|
|
83348
|
+
*
|
|
83349
|
+
* // Request body metadata
|
|
83350
|
+
* requestBody: {
|
|
83351
|
+
* // request body parameters
|
|
83352
|
+
* // {
|
|
83353
|
+
* // "accountAndRoles": [],
|
|
83354
|
+
* // "notifyViaEmail": false
|
|
83355
|
+
* // }
|
|
83356
|
+
* },
|
|
83357
|
+
* });
|
|
83358
|
+
* console.log(res.data);
|
|
83359
|
+
*
|
|
83360
|
+
* // Example response
|
|
83361
|
+
* // {}
|
|
83362
|
+
* }
|
|
83363
|
+
*
|
|
83364
|
+
* main().catch(e => {
|
|
83365
|
+
* console.error(e);
|
|
83366
|
+
* throw e;
|
|
83367
|
+
* });
|
|
83368
|
+
*
|
|
83369
|
+
* ```
|
|
83370
|
+
*
|
|
83371
|
+
* @param params - Parameters for request
|
|
83372
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
83373
|
+
* @param callback - Optional callback that handles the response.
|
|
83374
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
83375
|
+
*/
|
|
83376
|
+
share(
|
|
83377
|
+
params: Params$Resource$Projects$Locations$Notebooks$Share,
|
|
83378
|
+
options: StreamMethodOptions
|
|
83379
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
83380
|
+
share(
|
|
83381
|
+
params?: Params$Resource$Projects$Locations$Notebooks$Share,
|
|
83382
|
+
options?: MethodOptions
|
|
83383
|
+
): Promise<
|
|
83384
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>
|
|
83385
|
+
>;
|
|
83386
|
+
share(
|
|
83387
|
+
params: Params$Resource$Projects$Locations$Notebooks$Share,
|
|
83388
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
83389
|
+
callback: BodyResponseCallback<Readable>
|
|
83390
|
+
): void;
|
|
83391
|
+
share(
|
|
83392
|
+
params: Params$Resource$Projects$Locations$Notebooks$Share,
|
|
83393
|
+
options:
|
|
83394
|
+
| MethodOptions
|
|
83395
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>,
|
|
83396
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>
|
|
83397
|
+
): void;
|
|
83398
|
+
share(
|
|
83399
|
+
params: Params$Resource$Projects$Locations$Notebooks$Share,
|
|
83400
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>
|
|
83401
|
+
): void;
|
|
83402
|
+
share(
|
|
83403
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>
|
|
83404
|
+
): void;
|
|
83405
|
+
share(
|
|
83406
|
+
paramsOrCallback?:
|
|
83407
|
+
| Params$Resource$Projects$Locations$Notebooks$Share
|
|
83408
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>
|
|
83409
|
+
| BodyResponseCallback<Readable>,
|
|
83410
|
+
optionsOrCallback?:
|
|
83411
|
+
| MethodOptions
|
|
83412
|
+
| StreamMethodOptions
|
|
83413
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>
|
|
83414
|
+
| BodyResponseCallback<Readable>,
|
|
83415
|
+
callback?:
|
|
83416
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>
|
|
83417
|
+
| BodyResponseCallback<Readable>
|
|
83418
|
+
):
|
|
83419
|
+
| void
|
|
83420
|
+
| Promise<
|
|
83421
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>
|
|
83422
|
+
>
|
|
83423
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
83424
|
+
let params = (paramsOrCallback ||
|
|
83425
|
+
{}) as Params$Resource$Projects$Locations$Notebooks$Share;
|
|
83426
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
83427
|
+
|
|
83428
|
+
if (typeof paramsOrCallback === 'function') {
|
|
83429
|
+
callback = paramsOrCallback;
|
|
83430
|
+
params = {} as Params$Resource$Projects$Locations$Notebooks$Share;
|
|
83431
|
+
options = {};
|
|
83432
|
+
}
|
|
83433
|
+
|
|
83434
|
+
if (typeof optionsOrCallback === 'function') {
|
|
83435
|
+
callback = optionsOrCallback;
|
|
83436
|
+
options = {};
|
|
83437
|
+
}
|
|
83438
|
+
|
|
83439
|
+
const rootUrl =
|
|
83440
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
83441
|
+
const parameters = {
|
|
83442
|
+
options: Object.assign(
|
|
83443
|
+
{
|
|
83444
|
+
url: (rootUrl + '/v1alpha/{+name}:share').replace(
|
|
83445
|
+
/([^:]\/)\/+/g,
|
|
83446
|
+
'$1'
|
|
83447
|
+
),
|
|
83448
|
+
method: 'POST',
|
|
83449
|
+
apiVersion: '',
|
|
83450
|
+
},
|
|
83451
|
+
options
|
|
83452
|
+
),
|
|
83453
|
+
params,
|
|
83454
|
+
requiredParams: ['name'],
|
|
83455
|
+
pathParams: ['name'],
|
|
83456
|
+
context: this.context,
|
|
83457
|
+
};
|
|
83458
|
+
if (callback) {
|
|
83459
|
+
createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>(
|
|
83460
|
+
parameters,
|
|
83461
|
+
callback as BodyResponseCallback<unknown>
|
|
83462
|
+
);
|
|
83463
|
+
} else {
|
|
83464
|
+
return createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaShareNotebookResponse>(
|
|
83465
|
+
parameters
|
|
83466
|
+
);
|
|
83467
|
+
}
|
|
81841
83468
|
}
|
|
81842
83469
|
}
|
|
81843
83470
|
|
|
83471
|
+
export interface Params$Resource$Projects$Locations$Notebooks$Batchdelete extends StandardParameters {
|
|
83472
|
+
/**
|
|
83473
|
+
* Required. The parent branch resource name, such as `projects/{project\}/locations/{location\}`.
|
|
83474
|
+
*/
|
|
83475
|
+
parent?: string;
|
|
83476
|
+
|
|
83477
|
+
/**
|
|
83478
|
+
* Request body metadata
|
|
83479
|
+
*/
|
|
83480
|
+
requestBody?: Schema$GoogleCloudNotebooklmV1alphaBatchDeleteNotebooksRequest;
|
|
83481
|
+
}
|
|
83482
|
+
export interface Params$Resource$Projects$Locations$Notebooks$Create extends StandardParameters {
|
|
83483
|
+
/**
|
|
83484
|
+
* Required. The parent resource name, such as `projects/{project\}/locations/{location\}`.
|
|
83485
|
+
*/
|
|
83486
|
+
parent?: string;
|
|
83487
|
+
|
|
83488
|
+
/**
|
|
83489
|
+
* Request body metadata
|
|
83490
|
+
*/
|
|
83491
|
+
requestBody?: Schema$GoogleCloudNotebooklmV1alphaNotebook;
|
|
83492
|
+
}
|
|
83493
|
+
export interface Params$Resource$Projects$Locations$Notebooks$Get extends StandardParameters {
|
|
83494
|
+
/**
|
|
83495
|
+
* Required. Full resource name of Notebook, such as `projects/{project\}/locations/{location\}/notebooks/{notebook_id\}`.
|
|
83496
|
+
*/
|
|
83497
|
+
name?: string;
|
|
83498
|
+
}
|
|
83499
|
+
export interface Params$Resource$Projects$Locations$Notebooks$Listrecentlyviewed extends StandardParameters {
|
|
83500
|
+
/**
|
|
83501
|
+
* Optional. Maximum number of Notebooks to return. If unspecified, defaults to "500". The maximum allowed value is "500". If this field is negative, will use the default value.
|
|
83502
|
+
*/
|
|
83503
|
+
pageSize?: number;
|
|
83504
|
+
/**
|
|
83505
|
+
* Optional. The page token, provide this to retrieve the subsequent page.
|
|
83506
|
+
*/
|
|
83507
|
+
pageToken?: string;
|
|
83508
|
+
/**
|
|
83509
|
+
* Required. The parent branch resource name, such as `projects/{project\}/locations/{location\}`.
|
|
83510
|
+
*/
|
|
83511
|
+
parent?: string;
|
|
83512
|
+
}
|
|
83513
|
+
export interface Params$Resource$Projects$Locations$Notebooks$Share extends StandardParameters {
|
|
83514
|
+
/**
|
|
83515
|
+
* Required. Full resource name of Notebook, such as `projects/{project\}/locations/{location\}/notebooks/{notebook_id\}`.
|
|
83516
|
+
*/
|
|
83517
|
+
name?: string;
|
|
83518
|
+
|
|
83519
|
+
/**
|
|
83520
|
+
* Request body metadata
|
|
83521
|
+
*/
|
|
83522
|
+
requestBody?: Schema$GoogleCloudNotebooklmV1alphaShareNotebookRequest;
|
|
83523
|
+
}
|
|
83524
|
+
|
|
81844
83525
|
export class Resource$Projects$Locations$Notebooks$Audiooverviews {
|
|
81845
83526
|
context: APIRequestContext;
|
|
81846
83527
|
constructor(context: APIRequestContext) {
|
|
@@ -82167,6 +83848,510 @@ export namespace discoveryengine_v1alpha {
|
|
|
82167
83848
|
name?: string;
|
|
82168
83849
|
}
|
|
82169
83850
|
|
|
83851
|
+
export class Resource$Projects$Locations$Notebooks$Sources {
|
|
83852
|
+
context: APIRequestContext;
|
|
83853
|
+
constructor(context: APIRequestContext) {
|
|
83854
|
+
this.context = context;
|
|
83855
|
+
}
|
|
83856
|
+
|
|
83857
|
+
/**
|
|
83858
|
+
* Creates a list of Sources.
|
|
83859
|
+
* @example
|
|
83860
|
+
* ```js
|
|
83861
|
+
* // Before running the sample:
|
|
83862
|
+
* // - Enable the API at:
|
|
83863
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
83864
|
+
* // - Login into gcloud by running:
|
|
83865
|
+
* // ```sh
|
|
83866
|
+
* // $ gcloud auth application-default login
|
|
83867
|
+
* // ```
|
|
83868
|
+
* // - Install the npm module by running:
|
|
83869
|
+
* // ```sh
|
|
83870
|
+
* // $ npm install googleapis
|
|
83871
|
+
* // ```
|
|
83872
|
+
*
|
|
83873
|
+
* const {google} = require('googleapis');
|
|
83874
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
83875
|
+
*
|
|
83876
|
+
* async function main() {
|
|
83877
|
+
* const auth = new google.auth.GoogleAuth({
|
|
83878
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
83879
|
+
* scopes: [
|
|
83880
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
83881
|
+
* 'https://www.googleapis.com/auth/discoveryengine.assist.readwrite',
|
|
83882
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
83883
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
83884
|
+
* ],
|
|
83885
|
+
* });
|
|
83886
|
+
*
|
|
83887
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
83888
|
+
* const authClient = await auth.getClient();
|
|
83889
|
+
* google.options({auth: authClient});
|
|
83890
|
+
*
|
|
83891
|
+
* // Do the magic
|
|
83892
|
+
* const res =
|
|
83893
|
+
* await discoveryengine.projects.locations.notebooks.sources.batchCreate({
|
|
83894
|
+
* // Required. The parent resource where the sources will be created. Format: projects/{project\}/locations/{location\}/notebooks/{notebook\}
|
|
83895
|
+
* parent: 'projects/my-project/locations/my-location/notebooks/my-notebook',
|
|
83896
|
+
*
|
|
83897
|
+
* // Request body metadata
|
|
83898
|
+
* requestBody: {
|
|
83899
|
+
* // request body parameters
|
|
83900
|
+
* // {
|
|
83901
|
+
* // "userContents": []
|
|
83902
|
+
* // }
|
|
83903
|
+
* },
|
|
83904
|
+
* });
|
|
83905
|
+
* console.log(res.data);
|
|
83906
|
+
*
|
|
83907
|
+
* // Example response
|
|
83908
|
+
* // {
|
|
83909
|
+
* // "sources": []
|
|
83910
|
+
* // }
|
|
83911
|
+
* }
|
|
83912
|
+
*
|
|
83913
|
+
* main().catch(e => {
|
|
83914
|
+
* console.error(e);
|
|
83915
|
+
* throw e;
|
|
83916
|
+
* });
|
|
83917
|
+
*
|
|
83918
|
+
* ```
|
|
83919
|
+
*
|
|
83920
|
+
* @param params - Parameters for request
|
|
83921
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
83922
|
+
* @param callback - Optional callback that handles the response.
|
|
83923
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
83924
|
+
*/
|
|
83925
|
+
batchCreate(
|
|
83926
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate,
|
|
83927
|
+
options: StreamMethodOptions
|
|
83928
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
83929
|
+
batchCreate(
|
|
83930
|
+
params?: Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate,
|
|
83931
|
+
options?: MethodOptions
|
|
83932
|
+
): Promise<
|
|
83933
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>
|
|
83934
|
+
>;
|
|
83935
|
+
batchCreate(
|
|
83936
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate,
|
|
83937
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
83938
|
+
callback: BodyResponseCallback<Readable>
|
|
83939
|
+
): void;
|
|
83940
|
+
batchCreate(
|
|
83941
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate,
|
|
83942
|
+
options:
|
|
83943
|
+
| MethodOptions
|
|
83944
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>,
|
|
83945
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>
|
|
83946
|
+
): void;
|
|
83947
|
+
batchCreate(
|
|
83948
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate,
|
|
83949
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>
|
|
83950
|
+
): void;
|
|
83951
|
+
batchCreate(
|
|
83952
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>
|
|
83953
|
+
): void;
|
|
83954
|
+
batchCreate(
|
|
83955
|
+
paramsOrCallback?:
|
|
83956
|
+
| Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate
|
|
83957
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>
|
|
83958
|
+
| BodyResponseCallback<Readable>,
|
|
83959
|
+
optionsOrCallback?:
|
|
83960
|
+
| MethodOptions
|
|
83961
|
+
| StreamMethodOptions
|
|
83962
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>
|
|
83963
|
+
| BodyResponseCallback<Readable>,
|
|
83964
|
+
callback?:
|
|
83965
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>
|
|
83966
|
+
| BodyResponseCallback<Readable>
|
|
83967
|
+
):
|
|
83968
|
+
| void
|
|
83969
|
+
| Promise<
|
|
83970
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>
|
|
83971
|
+
>
|
|
83972
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
83973
|
+
let params = (paramsOrCallback ||
|
|
83974
|
+
{}) as Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate;
|
|
83975
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
83976
|
+
|
|
83977
|
+
if (typeof paramsOrCallback === 'function') {
|
|
83978
|
+
callback = paramsOrCallback;
|
|
83979
|
+
params =
|
|
83980
|
+
{} as Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate;
|
|
83981
|
+
options = {};
|
|
83982
|
+
}
|
|
83983
|
+
|
|
83984
|
+
if (typeof optionsOrCallback === 'function') {
|
|
83985
|
+
callback = optionsOrCallback;
|
|
83986
|
+
options = {};
|
|
83987
|
+
}
|
|
83988
|
+
|
|
83989
|
+
const rootUrl =
|
|
83990
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
83991
|
+
const parameters = {
|
|
83992
|
+
options: Object.assign(
|
|
83993
|
+
{
|
|
83994
|
+
url: (rootUrl + '/v1alpha/{+parent}/sources:batchCreate').replace(
|
|
83995
|
+
/([^:]\/)\/+/g,
|
|
83996
|
+
'$1'
|
|
83997
|
+
),
|
|
83998
|
+
method: 'POST',
|
|
83999
|
+
apiVersion: '',
|
|
84000
|
+
},
|
|
84001
|
+
options
|
|
84002
|
+
),
|
|
84003
|
+
params,
|
|
84004
|
+
requiredParams: ['parent'],
|
|
84005
|
+
pathParams: ['parent'],
|
|
84006
|
+
context: this.context,
|
|
84007
|
+
};
|
|
84008
|
+
if (callback) {
|
|
84009
|
+
createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>(
|
|
84010
|
+
parameters,
|
|
84011
|
+
callback as BodyResponseCallback<unknown>
|
|
84012
|
+
);
|
|
84013
|
+
} else {
|
|
84014
|
+
return createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesResponse>(
|
|
84015
|
+
parameters
|
|
84016
|
+
);
|
|
84017
|
+
}
|
|
84018
|
+
}
|
|
84019
|
+
|
|
84020
|
+
/**
|
|
84021
|
+
* Deletes multiple sources
|
|
84022
|
+
* @example
|
|
84023
|
+
* ```js
|
|
84024
|
+
* // Before running the sample:
|
|
84025
|
+
* // - Enable the API at:
|
|
84026
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
84027
|
+
* // - Login into gcloud by running:
|
|
84028
|
+
* // ```sh
|
|
84029
|
+
* // $ gcloud auth application-default login
|
|
84030
|
+
* // ```
|
|
84031
|
+
* // - Install the npm module by running:
|
|
84032
|
+
* // ```sh
|
|
84033
|
+
* // $ npm install googleapis
|
|
84034
|
+
* // ```
|
|
84035
|
+
*
|
|
84036
|
+
* const {google} = require('googleapis');
|
|
84037
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
84038
|
+
*
|
|
84039
|
+
* async function main() {
|
|
84040
|
+
* const auth = new google.auth.GoogleAuth({
|
|
84041
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
84042
|
+
* scopes: [
|
|
84043
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
84044
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
84045
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
84046
|
+
* ],
|
|
84047
|
+
* });
|
|
84048
|
+
*
|
|
84049
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
84050
|
+
* const authClient = await auth.getClient();
|
|
84051
|
+
* google.options({auth: authClient});
|
|
84052
|
+
*
|
|
84053
|
+
* // Do the magic
|
|
84054
|
+
* const res =
|
|
84055
|
+
* await discoveryengine.projects.locations.notebooks.sources.batchDelete({
|
|
84056
|
+
* // Required. The parent resource where the sources will be deleted. Format: projects/{project\}/locations/{location\}/notebooks/{notebook\}
|
|
84057
|
+
* parent: 'projects/my-project/locations/my-location/notebooks/my-notebook',
|
|
84058
|
+
*
|
|
84059
|
+
* // Request body metadata
|
|
84060
|
+
* requestBody: {
|
|
84061
|
+
* // request body parameters
|
|
84062
|
+
* // {
|
|
84063
|
+
* // "names": []
|
|
84064
|
+
* // }
|
|
84065
|
+
* },
|
|
84066
|
+
* });
|
|
84067
|
+
* console.log(res.data);
|
|
84068
|
+
*
|
|
84069
|
+
* // Example response
|
|
84070
|
+
* // {}
|
|
84071
|
+
* }
|
|
84072
|
+
*
|
|
84073
|
+
* main().catch(e => {
|
|
84074
|
+
* console.error(e);
|
|
84075
|
+
* throw e;
|
|
84076
|
+
* });
|
|
84077
|
+
*
|
|
84078
|
+
* ```
|
|
84079
|
+
*
|
|
84080
|
+
* @param params - Parameters for request
|
|
84081
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
84082
|
+
* @param callback - Optional callback that handles the response.
|
|
84083
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
84084
|
+
*/
|
|
84085
|
+
batchDelete(
|
|
84086
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete,
|
|
84087
|
+
options: StreamMethodOptions
|
|
84088
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
84089
|
+
batchDelete(
|
|
84090
|
+
params?: Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete,
|
|
84091
|
+
options?: MethodOptions
|
|
84092
|
+
): Promise<GaxiosResponseWithHTTP2<Schema$GoogleProtobufEmpty>>;
|
|
84093
|
+
batchDelete(
|
|
84094
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete,
|
|
84095
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
84096
|
+
callback: BodyResponseCallback<Readable>
|
|
84097
|
+
): void;
|
|
84098
|
+
batchDelete(
|
|
84099
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete,
|
|
84100
|
+
options: MethodOptions | BodyResponseCallback<Schema$GoogleProtobufEmpty>,
|
|
84101
|
+
callback: BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
84102
|
+
): void;
|
|
84103
|
+
batchDelete(
|
|
84104
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete,
|
|
84105
|
+
callback: BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
84106
|
+
): void;
|
|
84107
|
+
batchDelete(
|
|
84108
|
+
callback: BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
84109
|
+
): void;
|
|
84110
|
+
batchDelete(
|
|
84111
|
+
paramsOrCallback?:
|
|
84112
|
+
| Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete
|
|
84113
|
+
| BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
84114
|
+
| BodyResponseCallback<Readable>,
|
|
84115
|
+
optionsOrCallback?:
|
|
84116
|
+
| MethodOptions
|
|
84117
|
+
| StreamMethodOptions
|
|
84118
|
+
| BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
84119
|
+
| BodyResponseCallback<Readable>,
|
|
84120
|
+
callback?:
|
|
84121
|
+
| BodyResponseCallback<Schema$GoogleProtobufEmpty>
|
|
84122
|
+
| BodyResponseCallback<Readable>
|
|
84123
|
+
):
|
|
84124
|
+
| void
|
|
84125
|
+
| Promise<GaxiosResponseWithHTTP2<Schema$GoogleProtobufEmpty>>
|
|
84126
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
84127
|
+
let params = (paramsOrCallback ||
|
|
84128
|
+
{}) as Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete;
|
|
84129
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
84130
|
+
|
|
84131
|
+
if (typeof paramsOrCallback === 'function') {
|
|
84132
|
+
callback = paramsOrCallback;
|
|
84133
|
+
params =
|
|
84134
|
+
{} as Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete;
|
|
84135
|
+
options = {};
|
|
84136
|
+
}
|
|
84137
|
+
|
|
84138
|
+
if (typeof optionsOrCallback === 'function') {
|
|
84139
|
+
callback = optionsOrCallback;
|
|
84140
|
+
options = {};
|
|
84141
|
+
}
|
|
84142
|
+
|
|
84143
|
+
const rootUrl =
|
|
84144
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
84145
|
+
const parameters = {
|
|
84146
|
+
options: Object.assign(
|
|
84147
|
+
{
|
|
84148
|
+
url: (rootUrl + '/v1alpha/{+parent}/sources:batchDelete').replace(
|
|
84149
|
+
/([^:]\/)\/+/g,
|
|
84150
|
+
'$1'
|
|
84151
|
+
),
|
|
84152
|
+
method: 'POST',
|
|
84153
|
+
apiVersion: '',
|
|
84154
|
+
},
|
|
84155
|
+
options
|
|
84156
|
+
),
|
|
84157
|
+
params,
|
|
84158
|
+
requiredParams: ['parent'],
|
|
84159
|
+
pathParams: ['parent'],
|
|
84160
|
+
context: this.context,
|
|
84161
|
+
};
|
|
84162
|
+
if (callback) {
|
|
84163
|
+
createAPIRequest<Schema$GoogleProtobufEmpty>(
|
|
84164
|
+
parameters,
|
|
84165
|
+
callback as BodyResponseCallback<unknown>
|
|
84166
|
+
);
|
|
84167
|
+
} else {
|
|
84168
|
+
return createAPIRequest<Schema$GoogleProtobufEmpty>(parameters);
|
|
84169
|
+
}
|
|
84170
|
+
}
|
|
84171
|
+
|
|
84172
|
+
/**
|
|
84173
|
+
* Gets a Source.
|
|
84174
|
+
* @example
|
|
84175
|
+
* ```js
|
|
84176
|
+
* // Before running the sample:
|
|
84177
|
+
* // - Enable the API at:
|
|
84178
|
+
* // https://console.developers.google.com/apis/api/discoveryengine.googleapis.com
|
|
84179
|
+
* // - Login into gcloud by running:
|
|
84180
|
+
* // ```sh
|
|
84181
|
+
* // $ gcloud auth application-default login
|
|
84182
|
+
* // ```
|
|
84183
|
+
* // - Install the npm module by running:
|
|
84184
|
+
* // ```sh
|
|
84185
|
+
* // $ npm install googleapis
|
|
84186
|
+
* // ```
|
|
84187
|
+
*
|
|
84188
|
+
* const {google} = require('googleapis');
|
|
84189
|
+
* const discoveryengine = google.discoveryengine('v1alpha');
|
|
84190
|
+
*
|
|
84191
|
+
* async function main() {
|
|
84192
|
+
* const auth = new google.auth.GoogleAuth({
|
|
84193
|
+
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
84194
|
+
* scopes: [
|
|
84195
|
+
* 'https://www.googleapis.com/auth/cloud-platform',
|
|
84196
|
+
* 'https://www.googleapis.com/auth/discoveryengine.readwrite',
|
|
84197
|
+
* 'https://www.googleapis.com/auth/discoveryengine.serving.readwrite',
|
|
84198
|
+
* ],
|
|
84199
|
+
* });
|
|
84200
|
+
*
|
|
84201
|
+
* // Acquire an auth client, and bind it to all future calls
|
|
84202
|
+
* const authClient = await auth.getClient();
|
|
84203
|
+
* google.options({auth: authClient});
|
|
84204
|
+
*
|
|
84205
|
+
* // Do the magic
|
|
84206
|
+
* const res = await discoveryengine.projects.locations.notebooks.sources.get({
|
|
84207
|
+
* // Required. The resource name for source Format: projects/{project\}/locations/{location\}/notebooks/{notebook\}/sources/{source\}
|
|
84208
|
+
* name: 'projects/my-project/locations/my-location/notebooks/my-notebook/sources/my-source',
|
|
84209
|
+
* });
|
|
84210
|
+
* console.log(res.data);
|
|
84211
|
+
*
|
|
84212
|
+
* // Example response
|
|
84213
|
+
* // {
|
|
84214
|
+
* // "metadata": {},
|
|
84215
|
+
* // "name": "my_name",
|
|
84216
|
+
* // "settings": {},
|
|
84217
|
+
* // "sourceId": {},
|
|
84218
|
+
* // "title": "my_title"
|
|
84219
|
+
* // }
|
|
84220
|
+
* }
|
|
84221
|
+
*
|
|
84222
|
+
* main().catch(e => {
|
|
84223
|
+
* console.error(e);
|
|
84224
|
+
* throw e;
|
|
84225
|
+
* });
|
|
84226
|
+
*
|
|
84227
|
+
* ```
|
|
84228
|
+
*
|
|
84229
|
+
* @param params - Parameters for request
|
|
84230
|
+
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
84231
|
+
* @param callback - Optional callback that handles the response.
|
|
84232
|
+
* @returns A promise if used with async/await, or void if used with a callback.
|
|
84233
|
+
*/
|
|
84234
|
+
get(
|
|
84235
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Get,
|
|
84236
|
+
options: StreamMethodOptions
|
|
84237
|
+
): Promise<GaxiosResponseWithHTTP2<Readable>>;
|
|
84238
|
+
get(
|
|
84239
|
+
params?: Params$Resource$Projects$Locations$Notebooks$Sources$Get,
|
|
84240
|
+
options?: MethodOptions
|
|
84241
|
+
): Promise<
|
|
84242
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaSource>
|
|
84243
|
+
>;
|
|
84244
|
+
get(
|
|
84245
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Get,
|
|
84246
|
+
options: StreamMethodOptions | BodyResponseCallback<Readable>,
|
|
84247
|
+
callback: BodyResponseCallback<Readable>
|
|
84248
|
+
): void;
|
|
84249
|
+
get(
|
|
84250
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Get,
|
|
84251
|
+
options:
|
|
84252
|
+
| MethodOptions
|
|
84253
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaSource>,
|
|
84254
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaSource>
|
|
84255
|
+
): void;
|
|
84256
|
+
get(
|
|
84257
|
+
params: Params$Resource$Projects$Locations$Notebooks$Sources$Get,
|
|
84258
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaSource>
|
|
84259
|
+
): void;
|
|
84260
|
+
get(
|
|
84261
|
+
callback: BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaSource>
|
|
84262
|
+
): void;
|
|
84263
|
+
get(
|
|
84264
|
+
paramsOrCallback?:
|
|
84265
|
+
| Params$Resource$Projects$Locations$Notebooks$Sources$Get
|
|
84266
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaSource>
|
|
84267
|
+
| BodyResponseCallback<Readable>,
|
|
84268
|
+
optionsOrCallback?:
|
|
84269
|
+
| MethodOptions
|
|
84270
|
+
| StreamMethodOptions
|
|
84271
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaSource>
|
|
84272
|
+
| BodyResponseCallback<Readable>,
|
|
84273
|
+
callback?:
|
|
84274
|
+
| BodyResponseCallback<Schema$GoogleCloudNotebooklmV1alphaSource>
|
|
84275
|
+
| BodyResponseCallback<Readable>
|
|
84276
|
+
):
|
|
84277
|
+
| void
|
|
84278
|
+
| Promise<
|
|
84279
|
+
GaxiosResponseWithHTTP2<Schema$GoogleCloudNotebooklmV1alphaSource>
|
|
84280
|
+
>
|
|
84281
|
+
| Promise<GaxiosResponseWithHTTP2<Readable>> {
|
|
84282
|
+
let params = (paramsOrCallback ||
|
|
84283
|
+
{}) as Params$Resource$Projects$Locations$Notebooks$Sources$Get;
|
|
84284
|
+
let options = (optionsOrCallback || {}) as MethodOptions;
|
|
84285
|
+
|
|
84286
|
+
if (typeof paramsOrCallback === 'function') {
|
|
84287
|
+
callback = paramsOrCallback;
|
|
84288
|
+
params = {} as Params$Resource$Projects$Locations$Notebooks$Sources$Get;
|
|
84289
|
+
options = {};
|
|
84290
|
+
}
|
|
84291
|
+
|
|
84292
|
+
if (typeof optionsOrCallback === 'function') {
|
|
84293
|
+
callback = optionsOrCallback;
|
|
84294
|
+
options = {};
|
|
84295
|
+
}
|
|
84296
|
+
|
|
84297
|
+
const rootUrl =
|
|
84298
|
+
options.rootUrl || 'https://discoveryengine.googleapis.com/';
|
|
84299
|
+
const parameters = {
|
|
84300
|
+
options: Object.assign(
|
|
84301
|
+
{
|
|
84302
|
+
url: (rootUrl + '/v1alpha/{+name}').replace(/([^:]\/)\/+/g, '$1'),
|
|
84303
|
+
method: 'GET',
|
|
84304
|
+
apiVersion: '',
|
|
84305
|
+
},
|
|
84306
|
+
options
|
|
84307
|
+
),
|
|
84308
|
+
params,
|
|
84309
|
+
requiredParams: ['name'],
|
|
84310
|
+
pathParams: ['name'],
|
|
84311
|
+
context: this.context,
|
|
84312
|
+
};
|
|
84313
|
+
if (callback) {
|
|
84314
|
+
createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaSource>(
|
|
84315
|
+
parameters,
|
|
84316
|
+
callback as BodyResponseCallback<unknown>
|
|
84317
|
+
);
|
|
84318
|
+
} else {
|
|
84319
|
+
return createAPIRequest<Schema$GoogleCloudNotebooklmV1alphaSource>(
|
|
84320
|
+
parameters
|
|
84321
|
+
);
|
|
84322
|
+
}
|
|
84323
|
+
}
|
|
84324
|
+
}
|
|
84325
|
+
|
|
84326
|
+
export interface Params$Resource$Projects$Locations$Notebooks$Sources$Batchcreate extends StandardParameters {
|
|
84327
|
+
/**
|
|
84328
|
+
* Required. The parent resource where the sources will be created. Format: projects/{project\}/locations/{location\}/notebooks/{notebook\}
|
|
84329
|
+
*/
|
|
84330
|
+
parent?: string;
|
|
84331
|
+
|
|
84332
|
+
/**
|
|
84333
|
+
* Request body metadata
|
|
84334
|
+
*/
|
|
84335
|
+
requestBody?: Schema$GoogleCloudNotebooklmV1alphaBatchCreateSourcesRequest;
|
|
84336
|
+
}
|
|
84337
|
+
export interface Params$Resource$Projects$Locations$Notebooks$Sources$Batchdelete extends StandardParameters {
|
|
84338
|
+
/**
|
|
84339
|
+
* Required. The parent resource where the sources will be deleted. Format: projects/{project\}/locations/{location\}/notebooks/{notebook\}
|
|
84340
|
+
*/
|
|
84341
|
+
parent?: string;
|
|
84342
|
+
|
|
84343
|
+
/**
|
|
84344
|
+
* Request body metadata
|
|
84345
|
+
*/
|
|
84346
|
+
requestBody?: Schema$GoogleCloudNotebooklmV1alphaBatchDeleteSourcesRequest;
|
|
84347
|
+
}
|
|
84348
|
+
export interface Params$Resource$Projects$Locations$Notebooks$Sources$Get extends StandardParameters {
|
|
84349
|
+
/**
|
|
84350
|
+
* Required. The resource name for source Format: projects/{project\}/locations/{location\}/notebooks/{notebook\}/sources/{source\}
|
|
84351
|
+
*/
|
|
84352
|
+
name?: string;
|
|
84353
|
+
}
|
|
84354
|
+
|
|
82170
84355
|
export class Resource$Projects$Locations$Operations {
|
|
82171
84356
|
context: APIRequestContext;
|
|
82172
84357
|
constructor(context: APIRequestContext) {
|