pub struct BithumbAuth { /* private fields */ }Expand description
Bithumb authentication handler
Implementations§
Source§impl BithumbAuth
impl BithumbAuth
Sourcepub const fn new(config: BithumbAuthConfig) -> Self
pub const fn new(config: BithumbAuthConfig) -> Self
Create a new authentication handler
Sourcepub fn generate_nonce() -> u64
pub fn generate_nonce() -> u64
Sourcepub fn encode_params_zero_copy(input: &str, buffer: &mut String) -> Result<()>
pub fn encode_params_zero_copy(input: &str, buffer: &mut String) -> Result<()>
URL-encode the provided string into a preallocated buffer.
This avoids heap allocations on critical paths.
Sourcepub fn generate_signature(
&self,
endpoint: &str,
params: &str,
nonce: u64,
) -> Result<String>
pub fn generate_signature( &self, endpoint: &str, params: &str, nonce: u64, ) -> Result<String>
Sourcepub fn build_param_string(params: &[(&str, &str)]) -> Result<String>
pub fn build_param_string(params: &[(&str, &str)]) -> Result<String>
Sourcepub fn generate_auth_headers(
&self,
endpoint: &str,
params: Option<&[(&str, &str)]>,
) -> Result<(String, String, u64)>
pub fn generate_auth_headers( &self, endpoint: &str, params: Option<&[(&str, &str)]>, ) -> Result<(String, String, u64)>
Sourcepub fn generate_websocket_auth(&self) -> Result<BithumbWebSocketAuth>
pub fn generate_websocket_auth(&self) -> Result<BithumbWebSocketAuth>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for BithumbAuth
impl RefUnwindSafe for BithumbAuth
impl Send for BithumbAuth
impl Sync for BithumbAuth
impl Unpin for BithumbAuth
impl UnwindSafe for BithumbAuth
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
Mutably borrows from an owned value. Read more