pub struct SkybaseConfig {
pub client_id: String,
pub redirect_uri: String,
pub app_name: String,
pub jetstream_endpoint: Option<String>,
pub storage_path: Option<PathBuf>,
pub in_memory_store: bool,
pub store_config: Option<RecordStoreConfig>,
pub wanted_collections: Vec<String>,
pub wanted_dids: Vec<String>,
}Expand description
Configuration options for initializing a Skybase engine instance.
Fields§
§client_id: StringOAuth Client ID URI (e.g., <https://app.example.com/oauth/client-metadata.json>).
redirect_uri: StringOAuth callback redirect URI (e.g., <https://app.example.com/oauth/callback>).
app_name: StringApplication display name presented during consent dialogs.
jetstream_endpoint: Option<String>Optional Jetstream WebSocket endpoint for real-time firehose subscription.
storage_path: Option<PathBuf>Optional filesystem path to SQLite database. If set, opens a persistent WAL store.
in_memory_store: boolWhether to open an isolated in-memory SQLite database upon initialization.
store_config: Option<RecordStoreConfig>Optional explicit configuration for the embedded record store.
wanted_collections: Vec<String>Target collection NSIDs to filter for at the edge during Jetstream ingestion.
wanted_dids: Vec<String>Target repository DIDs to filter for at the edge during Jetstream ingestion.
Implementations§
Source§impl SkybaseConfig
impl SkybaseConfig
Sourcepub fn new(
client_id: impl Into<String>,
redirect_uri: impl Into<String>,
app_name: impl Into<String>,
) -> Self
pub fn new( client_id: impl Into<String>, redirect_uri: impl Into<String>, app_name: impl Into<String>, ) -> Self
Creates a new SkybaseConfig with required OAuth parameters.
Sourcepub fn with_jetstream_endpoint(self, endpoint: impl Into<String>) -> Self
pub fn with_jetstream_endpoint(self, endpoint: impl Into<String>) -> Self
Sets a custom Jetstream WebSocket endpoint for event subscription.
Sourcepub fn with_storage_path(self, path: impl Into<PathBuf>) -> Self
pub fn with_storage_path(self, path: impl Into<PathBuf>) -> Self
Configures a persistent SQLite database file path.
Sourcepub fn with_in_memory_store(self) -> Self
pub fn with_in_memory_store(self) -> Self
Configures an isolated in-memory SQLite database.
Sourcepub fn with_store_config(self, config: RecordStoreConfig) -> Self
pub fn with_store_config(self, config: RecordStoreConfig) -> Self
Sets an explicit RecordStoreConfig.
Sourcepub fn with_wanted_collection(self, collection: impl Into<String>) -> Self
pub fn with_wanted_collection(self, collection: impl Into<String>) -> Self
Appends a target collection NSID to filter for at the edge.
Sourcepub fn with_wanted_collections<I, S>(self, collections: I) -> Self
pub fn with_wanted_collections<I, S>(self, collections: I) -> Self
Sets target collection NSIDs to filter for at the edge.
Sourcepub fn with_wanted_did(self, did: impl Into<String>) -> Self
pub fn with_wanted_did(self, did: impl Into<String>) -> Self
Appends a target DID to filter for at the edge.
Sourcepub fn with_wanted_dids<I, S>(self, dids: I) -> Self
pub fn with_wanted_dids<I, S>(self, dids: I) -> Self
Sets target DIDs to filter for at the edge.