google_cloud_aiplatform_v1/
lib.rs

1// Copyright 2025 Google LLC
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//     https://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14//
15// Code generated by sidekick. DO NOT EDIT.
16
17//! Google Cloud Client Libraries for Rust - Vertex AI API
18//!
19//! **WARNING:** some RPCs have no corresponding Rust function to call them.
20//! Typically these are streaming RPCs. We expect adding these RPCs in a
21//! way that does not break the existing APIs or changes their behavior in a
22//! significant way. We do anticipate a number of new crate dependencies
23//! will be required. If you need these RPCs please open an issue in our
24//! GitHub repository.
25//!
26//! This crate contains traits, types, and functions to interact with Vertex AI API
27//! Most applications will use the structs defined in the [client] module.
28//!
29//! The client library types and functions are stable and not expected to change.
30//! Please note that Google Cloud services do change from time to time. The client
31//! libraries are designed to preserve backwards compatibility when the service
32//! changes in compatible ways. For example, adding RPCs, or fields to messages
33//! should not introduce breaking changes to the client libraries.
34//!
35//! # Available Clients
36//!
37//! * [DataFoundryService](client/struct.DataFoundryService.html)
38//! * [DatasetService](client/struct.DatasetService.html)
39//! * [DeploymentResourcePoolService](client/struct.DeploymentResourcePoolService.html)
40//! * [EndpointService](client/struct.EndpointService.html)
41//! * [EvaluationService](client/struct.EvaluationService.html)
42//! * [FeatureOnlineStoreAdminService](client/struct.FeatureOnlineStoreAdminService.html)
43//! * [FeatureOnlineStoreService](client/struct.FeatureOnlineStoreService.html)
44//! * [FeatureRegistryService](client/struct.FeatureRegistryService.html)
45//! * [FeaturestoreOnlineServingService](client/struct.FeaturestoreOnlineServingService.html)
46//! * [FeaturestoreService](client/struct.FeaturestoreService.html)
47//! * [GenAiCacheService](client/struct.GenAiCacheService.html)
48//! * [GenAiTuningService](client/struct.GenAiTuningService.html)
49//! * [IndexEndpointService](client/struct.IndexEndpointService.html)
50//! * [IndexService](client/struct.IndexService.html)
51//! * [JobService](client/struct.JobService.html)
52//! * [LlmUtilityService](client/struct.LlmUtilityService.html)
53//! * [MatchService](client/struct.MatchService.html)
54//! * [MetadataService](client/struct.MetadataService.html)
55//! * [MigrationService](client/struct.MigrationService.html)
56//! * [ModelGardenService](client/struct.ModelGardenService.html)
57//! * [ModelService](client/struct.ModelService.html)
58//! * [NotebookService](client/struct.NotebookService.html)
59//! * [PersistentResourceService](client/struct.PersistentResourceService.html)
60//! * [PipelineService](client/struct.PipelineService.html)
61//! * [PredictionService](client/struct.PredictionService.html)
62//! * [ReasoningEngineExecutionService](client/struct.ReasoningEngineExecutionService.html)
63//! * [ReasoningEngineService](client/struct.ReasoningEngineService.html)
64//! * [ScheduleService](client/struct.ScheduleService.html)
65//! * [SpecialistPoolService](client/struct.SpecialistPoolService.html)
66//! * [TensorboardService](client/struct.TensorboardService.html)
67//! * [VertexRagDataService](client/struct.VertexRagDataService.html)
68//! * [VertexRagService](client/struct.VertexRagService.html)
69//! * [VizierService](client/struct.VizierService.html)
70
71#![cfg_attr(docsrs, feature(doc_cfg))]
72#![allow(deprecated)]
73
74/// The messages and enums that are part of this client library.
75#[allow(clippy::module_inception)]
76pub mod model;
77
78pub use gax::Result;
79pub use gax::error::Error;
80
81#[allow(rustdoc::invalid_html_tags)]
82#[allow(rustdoc::redundant_explicit_links)]
83pub mod stub;
84
85/// Concrete implementations of this client library traits.
86pub mod client;
87
88/// Request builders.
89pub mod builder;
90
91#[doc(hidden)]
92pub(crate) mod tracing;
93
94#[doc(hidden)]
95pub(crate) mod transport;
96
97/// The default host used by the service.
98#[cfg(any(
99    feature = "data-foundry-service",
100    feature = "dataset-service",
101    feature = "deployment-resource-pool-service",
102    feature = "endpoint-service",
103    feature = "evaluation-service",
104    feature = "feature-online-store-admin-service",
105    feature = "feature-online-store-service",
106    feature = "feature-registry-service",
107    feature = "featurestore-online-serving-service",
108    feature = "featurestore-service",
109    feature = "gen-ai-cache-service",
110    feature = "gen-ai-tuning-service",
111    feature = "index-endpoint-service",
112    feature = "index-service",
113    feature = "job-service",
114    feature = "llm-utility-service",
115    feature = "match-service",
116    feature = "metadata-service",
117    feature = "migration-service",
118    feature = "model-garden-service",
119    feature = "model-service",
120    feature = "notebook-service",
121    feature = "persistent-resource-service",
122    feature = "pipeline-service",
123    feature = "prediction-service",
124    feature = "reasoning-engine-execution-service",
125    feature = "reasoning-engine-service",
126    feature = "schedule-service",
127    feature = "specialist-pool-service",
128    feature = "tensorboard-service",
129    feature = "vertex-rag-data-service",
130    feature = "vertex-rag-service",
131    feature = "vizier-service",
132))]
133const DEFAULT_HOST: &str = "https://aiplatform.googleapis.com/";
134
135#[cfg(any(
136    feature = "data-foundry-service",
137    feature = "dataset-service",
138    feature = "deployment-resource-pool-service",
139    feature = "endpoint-service",
140    feature = "evaluation-service",
141    feature = "feature-online-store-admin-service",
142    feature = "feature-online-store-service",
143    feature = "feature-registry-service",
144    feature = "featurestore-online-serving-service",
145    feature = "featurestore-service",
146    feature = "gen-ai-cache-service",
147    feature = "gen-ai-tuning-service",
148    feature = "index-endpoint-service",
149    feature = "index-service",
150    feature = "job-service",
151    feature = "llm-utility-service",
152    feature = "match-service",
153    feature = "metadata-service",
154    feature = "migration-service",
155    feature = "model-garden-service",
156    feature = "model-service",
157    feature = "notebook-service",
158    feature = "persistent-resource-service",
159    feature = "pipeline-service",
160    feature = "prediction-service",
161    feature = "reasoning-engine-execution-service",
162    feature = "reasoning-engine-service",
163    feature = "schedule-service",
164    feature = "specialist-pool-service",
165    feature = "tensorboard-service",
166    feature = "vertex-rag-data-service",
167    feature = "vertex-rag-service",
168    feature = "vizier-service",
169))]
170pub(crate) mod info {
171    const NAME: &str = env!("CARGO_PKG_NAME");
172    const VERSION: &str = env!("CARGO_PKG_VERSION");
173    lazy_static::lazy_static! {
174        pub(crate) static ref X_GOOG_API_CLIENT_HEADER: String = {
175            let ac = gaxi::api_header::XGoogApiClient{
176                name:          NAME,
177                version:       VERSION,
178                library_type:  gaxi::api_header::GAPIC,
179            };
180            ac.rest_header_value()
181        };
182    }
183}