pub struct UpsertLlmConnectionRequest {
pub provider: String,
pub adapter: LlmAdapter,
pub secret_key: String,
pub base_url: Option<Option<String>>,
pub custom_models: Option<Option<Vec<String>>>,
pub with_default_models: Option<Option<bool>>,
pub extra_headers: Option<Option<HashMap<String, String>>>,
pub config: Option<Option<HashMap<String, Value>>>,
}Expand description
UpsertLlmConnectionRequest : Request to create or update an LLM connection (upsert)
Fields§
§provider: StringProvider name (e.g., ‘openai’, ‘my-gateway’). Must be unique in project, used for upserting.
adapter: LlmAdapter§secret_key: StringSecret key for the LLM API.
base_url: Option<Option<String>>Custom base URL for the LLM API
custom_models: Option<Option<Vec<String>>>List of custom model names
with_default_models: Option<Option<bool>>Whether to include default models. Default is true.
extra_headers: Option<Option<HashMap<String, String>>>Extra headers to send with requests
config: Option<Option<HashMap<String, Value>>>Adapter-specific configuration. Validation rules: - Bedrock: Required. Must be {\"region\": \"<aws-region>\"} (e.g., {\"region\":\"us-east-1\"}) - VertexAI: Optional. If provided, must be {\"location\": \"<gcp-location>\"} (e.g., {\"location\":\"us-central1\"}) - Other adapters: Not supported. Omit this field or set to null.
Implementations§
Source§impl UpsertLlmConnectionRequest
impl UpsertLlmConnectionRequest
Sourcepub fn builder() -> UpsertLlmConnectionRequestBuilder
pub fn builder() -> UpsertLlmConnectionRequestBuilder
Create an instance of UpsertLlmConnectionRequest using the builder syntax
Source§impl UpsertLlmConnectionRequest
impl UpsertLlmConnectionRequest
Sourcepub fn new(
provider: String,
adapter: LlmAdapter,
secret_key: String,
) -> UpsertLlmConnectionRequest
pub fn new( provider: String, adapter: LlmAdapter, secret_key: String, ) -> UpsertLlmConnectionRequest
Request to create or update an LLM connection (upsert)
Trait Implementations§
Source§impl Clone for UpsertLlmConnectionRequest
impl Clone for UpsertLlmConnectionRequest
Source§fn clone(&self) -> UpsertLlmConnectionRequest
fn clone(&self) -> UpsertLlmConnectionRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more