pub struct SecurityConfig {
pub app_id: String,
pub app_secret: String,
pub base_url: String,
}Expand description
安全服务配置
Fields§
§app_id: String应用ID
app_secret: String应用密钥
base_url: String基础URL
Implementations§
Source§impl SecurityConfig
impl SecurityConfig
Sourcepub fn with_base_url(self, base_url: &str) -> Self
pub fn with_base_url(self, base_url: &str) -> Self
设置基础URL
Sourcepub async fn get_app_access_token(&self) -> SecurityResult<String>
pub async fn get_app_access_token(&self) -> SecurityResult<String>
获取应用访问令牌
使用 openlark-auth 的 AuthTokenProvider 获取真实的 app_access_token
Trait Implementations§
Source§impl Clone for SecurityConfig
impl Clone for SecurityConfig
Source§fn clone(&self) -> SecurityConfig
fn clone(&self) -> SecurityConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SecurityConfig
impl Debug for SecurityConfig
Auto Trait Implementations§
impl Freeze for SecurityConfig
impl RefUnwindSafe for SecurityConfig
impl Send for SecurityConfig
impl Sync for SecurityConfig
impl Unpin for SecurityConfig
impl UnsafeUnpin for SecurityConfig
impl UnwindSafe for SecurityConfig
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