pub struct InteractshClient { /* private fields */ }Expand description
One interactsh registration. Cheap to clone (Arc-friendly fields only on caller’s side; here we hold owned values because the session pins this for the lifetime of the engine).
Implementations§
Source§impl InteractshClient
impl InteractshClient
Sourcepub async fn register(
http: Client,
server: &str,
) -> Result<Self, InteractshError>
pub async fn register( http: Client, server: &str, ) -> Result<Self, InteractshError>
Build, generate keys, and register with the collector. The returned client is ready to mint URLs and be polled.
Sourcepub fn mint_url(&self) -> MintedUrl
pub fn mint_url(&self) -> MintedUrl
Mint a fresh callback URL bound to this session. The full 33-char subdomain is returned (unique-id) plus the host the service should hit. Caller is responsible for embedding it where the credential’s API will follow.
Sourcepub async fn poll(&self) -> Result<Vec<Interaction>, InteractshError>
pub async fn poll(&self) -> Result<Vec<Interaction>, InteractshError>
Poll once. Returns every interaction the collector has buffered for this correlation id since the last poll.
Sourcepub async fn deregister(&self) -> Result<(), InteractshError>
pub async fn deregister(&self) -> Result<(), InteractshError>
Tear down the registration. Idempotent on the server side; a failure to deregister is non-fatal — the server prunes inactive sessions after its retention window.
pub fn correlation_id(&self) -> &str
Auto Trait Implementations§
impl Freeze for InteractshClient
impl !RefUnwindSafe for InteractshClient
impl Send for InteractshClient
impl Sync for InteractshClient
impl Unpin for InteractshClient
impl UnsafeUnpin for InteractshClient
impl !UnwindSafe for InteractshClient
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> 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