pub struct ServerConfiguration {
pub identifier: String,
pub server_version: String,
pub min_libxmtp_version: String,
pub auth: AuthConfiguration,
pub retention: RetentionConfiguration,
pub limits: LimitsConfiguration,
pub mls: MlsConfiguration,
pub handles: HandlesConfiguration,
pub attachments: Option<AttachmentsConfiguration>,
pub smart_contract_wallet_chains: Vec<String>,
pub application_components: Vec<ApplicationComponentDefinition>,
}Expand description
One immutable snapshot of what a deployment published.
Default is the compiled fallback used before any fetch succeeds, and for
any field the deployment left at zero.
Fields§
§identifier: StringStable operator-chosen name. Empty only before a first fetch succeeds.
server_version: String§min_libxmtp_version: StringEmpty when the operator published no minimum.
auth: AuthConfiguration§retention: RetentionConfiguration§limits: LimitsConfiguration§mls: MlsConfiguration§handles: HandlesConfiguration§attachments: Option<AttachmentsConfiguration>Absent when attachment storage is not offered or its message is unusable.
smart_contract_wallet_chains: Vec<String>CAIP-2 chain ids this deployment verifies smart contract wallet signatures on. Empty rejects every app-supplied signature.
application_components: Vec<ApplicationComponentDefinition>Group metadata fields a client registers in the conversations it creates, in published order.
Implementations§
Source§impl ServerConfiguration
impl ServerConfiguration
Sourcepub fn validate(&self) -> Result<(), ServerConfigurationError>
pub fn validate(&self) -> Result<(), ServerConfigurationError>
The identifier must be well formed, any
minimum version must parse, every chain must be CAIP-2, every
numeric value must survive the trip to an SDK integer intact, and the
application catalogue must pass validate_application_components.
Sourcepub fn minimum_version(
&self,
) -> Result<Option<Version>, ServerConfigurationError>
pub fn minimum_version( &self, ) -> Result<Option<Version>, ServerConfigurationError>
The published minimum, parsed. None admits every client version.
Sourcepub fn accepts_chain(&self, chain: &str) -> bool
pub fn accepts_chain(&self, chain: &str) -> bool
Whether this deployment accepts a smart contract wallet signature on
chain. An empty list accepts none.
Trait Implementations§
Source§impl Clone for ServerConfiguration
impl Clone for ServerConfiguration
Source§fn clone(&self) -> ServerConfiguration
fn clone(&self) -> ServerConfiguration
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ServerConfiguration
impl Debug for ServerConfiguration
Source§impl Default for ServerConfiguration
impl Default for ServerConfiguration
Source§fn default() -> ServerConfiguration
fn default() -> ServerConfiguration
Source§impl PartialEq for ServerConfiguration
impl PartialEq for ServerConfiguration
Source§fn eq(&self, other: &ServerConfiguration) -> bool
fn eq(&self, other: &ServerConfiguration) -> bool
self and other values to be equal, and is used by ==.