pub struct TapHttpConfig {
pub host: String,
pub port: u16,
pub didcomm_endpoint: String,
pub rate_limit: Option<RateLimitConfig>,
pub tls: Option<TlsConfig>,
pub request_timeout_secs: u64,
pub event_logger: Option<EventLoggerConfig>,
pub enable_web_did: bool,
pub max_agents: usize,
}Expand description
Configuration for the TAP HTTP server.
Fields§
§host: StringThe host address to bind to.
port: u16The port to bind to.
didcomm_endpoint: StringThe endpoint path for receiving DIDComm messages.
rate_limit: Option<RateLimitConfig>Optional rate limiting configuration.
tls: Option<TlsConfig>Optional TLS configuration.
request_timeout_secs: u64Default timeout for outbound HTTP requests in seconds.
event_logger: Option<EventLoggerConfig>Optional event logger configuration. If not provided, no event logging will be performed.
enable_web_did: boolEnable the /.well-known/did.json endpoint for did:web hosting.
When enabled, the server resolves the HTTP Host header to a did:web
DID and serves the corresponding DID document.
max_agents: usizeMaximum number of agents that can be auto-created via the web DID endpoint. Prevents denial-of-service via unbounded agent creation.
Implementations§
Source§impl TapHttpConfig
impl TapHttpConfig
Sourcepub fn server_addr(&self) -> String
pub fn server_addr(&self) -> String
Returns the full server address as a string (e.g., “127.0.0.1:8000”).
Sourcepub fn didcomm_url(&self, secure: bool) -> String
pub fn didcomm_url(&self, secure: bool) -> String
Returns the full URL for the DIDComm endpoint.
Sourcepub fn request_timeout(&self) -> Duration
pub fn request_timeout(&self) -> Duration
Returns the request timeout as a Duration.
Trait Implementations§
Source§impl Clone for TapHttpConfig
impl Clone for TapHttpConfig
Source§fn clone(&self) -> TapHttpConfig
fn clone(&self) -> TapHttpConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for TapHttpConfig
impl Debug for TapHttpConfig
Source§impl Default for TapHttpConfig
impl Default for TapHttpConfig
Source§impl<'de> Deserialize<'de> for TapHttpConfig
impl<'de> Deserialize<'de> for TapHttpConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for TapHttpConfig
impl !RefUnwindSafe for TapHttpConfig
impl Send for TapHttpConfig
impl Sync for TapHttpConfig
impl Unpin for TapHttpConfig
impl UnsafeUnpin for TapHttpConfig
impl !UnwindSafe for TapHttpConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more