Crate gemini_rust

Crate gemini_rust 

Source
Expand description

§gemini-rust

A Rust client library for Google’s Gemini 2.0 API.

Structs§

BatchBuilder
Builder for synchronous batch content generation requests
BatchConfig
Batch configuration
BatchMetadata
Metadata for the batch operation
BatchRequestItem
Individual batch request item
BatchStats
Statistics for the batch
Blob
Blob for a message part
Candidate
A candidate response
CitationMetadata
Citation metadata for content
Content
Content of a message
ContentBuilder
Builder for content generation requests
FunctionCall
A function call made by the model
FunctionDeclaration
Declaration of a function that can be called by the model
FunctionParameters
Parameters for a function
Gemini
Client for the Gemini API
GenerateContentRequest
Request to generate content
GenerationConfig
Configuration for generation
GenerationResponse
Response from the Gemini API for content generation
InputConfig
Input configuration for batch requests
Message
Message in a conversation
PromptTokenDetails
Details about prompt tokens by modality
PropertyDetails
Details about a property
RequestMetadata
Metadata for batch request
RequestsContainer
Container for requests
SafetyRating
Safety rating for content
ThinkingConfig
Configuration for thinking (Gemini 2.5 series only)
UsageMetadata
Metadata about token usage

Enums§

Error
Errors that can occur when using the Gemini API
FunctionCallingMode
Mode for function calling
Part
Content part that can be included in a message
Role
Role of a message in a conversation
TaskType
Embedding Task types
Tool
Tool that can be used by the model

Type Aliases§

Result
Result type for this crate