pub struct LarkConfig {
pub app_id: String,
pub app_secret: String,
pub encrypt_key: Option<String>,
pub verification_token: Option<String>,
pub allowed_users: Vec<String>,
pub mention_only: bool,
pub use_feishu: bool,
pub receive_mode: LarkReceiveMode,
pub port: Option<u16>,
pub proxy_url: Option<String>,
}Expand description
Lark/Feishu configuration for messaging integration. Lark is the international version; Feishu is the Chinese version.
Fields§
§app_id: StringApp ID from Lark/Feishu developer console
app_secret: StringApp Secret from Lark/Feishu developer console
encrypt_key: Option<String>Encrypt key for webhook message decryption (optional)
verification_token: Option<String>Verification token for webhook validation (optional)
allowed_users: Vec<String>Allowed user IDs or union IDs (empty = deny all, “*” = allow all)
mention_only: boolWhen true, only respond to messages that @-mention the bot in groups. Direct messages are always processed.
use_feishu: boolWhether to use the Feishu (Chinese) endpoint instead of Lark (International)
receive_mode: LarkReceiveModeEvent receive mode: “websocket” (default) or “webhook”
port: Option<u16>HTTP port for webhook mode only. Must be set when receive_mode = “webhook”. Not required (and ignored) for websocket mode.
proxy_url: Option<String>Per-channel proxy URL (http, https, socks5, socks5h).
Overrides the global [proxy] setting for this channel only.
Trait Implementations§
Source§impl ChannelConfig for LarkConfig
impl ChannelConfig for LarkConfig
Source§impl Clone for LarkConfig
impl Clone for LarkConfig
Source§fn clone(&self) -> LarkConfig
fn clone(&self) -> LarkConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for LarkConfig
impl Debug for LarkConfig
Source§impl<'de> Deserialize<'de> for LarkConfig
impl<'de> Deserialize<'de> for LarkConfig
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>,
Source§impl JsonSchema for LarkConfig
impl JsonSchema for LarkConfig
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreAuto Trait Implementations§
impl Freeze for LarkConfig
impl RefUnwindSafe for LarkConfig
impl Send for LarkConfig
impl Sync for LarkConfig
impl Unpin for LarkConfig
impl UnsafeUnpin for LarkConfig
impl UnwindSafe for LarkConfig
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> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for 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