Skip to main content

Crate agent_proxy_rust_storage

Crate agent_proxy_rust_storage 

Source
Expand description

Backend-agnostic storage abstraction for agent-proxy-rust.

Defines the Storage trait and all data types shared across backends. Middleware crates depend on Box<dyn Storage> injected at construction time, and never know whether the backend is SQLite, PostgreSQL, or an in-memory mock.

Structs§

AvailableChannelInfo
An enabled channel with its bound models, used by the Admin API GET /admin/available-channels endpoint for Claude direct-connect mode.
AvailableModelInfo
A model bound to a channel, returned as part of AvailableChannelInfo.
Channel
An upstream AI provider channel with its API key and protocol.
CompressionSavingsReport
Compression savings report for a project.
CostAggregate
Aggregated cost summary row.
CostFilter
Optional filters for querying cost records.
CostRecord
A single proxied request with token usage and cost.
Model
A model offered by a provider.
ModelMapping
Maps a client-facing model name to an upstream model name with pricing.
ProtocolEntry
A single protocol entry in a channel’s protocols JSON.
Provider
An upstream AI provider (e.g. “Anthropic”, “OpenAI”).
SeedEntryStatus
Status of a single seed data entry.
SeedManifest
Deserialized seed manifest from seed-manifest.json.
SeedManifestEntry
A single file entry in the seed manifest.
SeedStatus
Status of the local seed data.
SubscriptionFee
A monthly subscription fee for a flat-fee channel.
SwitchLog
A switch/redirect event between channels.
TimeRange
A time range bounded by start and end timestamps.

Enums§

CostGroupBy
Grouping dimension for cost aggregation.
StorageError
Storage error type covering all backend failure modes.

Traits§

SeedManager
Seed data manager — initializes and refreshes reference data.
Storage
Backend-agnostic storage for providers, models, channels, and cost records.