pub struct PuppetService { /* private fields */ }
Implementations§
Source§impl PuppetService
impl PuppetService
Sourcepub async fn new(options: PuppetOptions) -> Result<Puppet<Self>, PuppetError>
pub async fn new(options: PuppetOptions) -> Result<Puppet<Self>, PuppetError>
Create puppet instance from puppet options.
First use endpoint, if endpoint is not given, try token instead.
Trait Implementations§
Source§impl Clone for PuppetService
impl Clone for PuppetService
Source§fn clone(&self) -> PuppetService
fn clone(&self) -> PuppetService
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl PuppetImpl for PuppetService
impl PuppetImpl for PuppetService
fn contact_self_name_set<'life0, 'async_trait>(
&'life0 self,
name: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_self_qr_code<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<String, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_self_signature_set<'life0, 'async_trait>(
&'life0 self,
signature: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn tag_contact_add<'life0, 'async_trait>(
&'life0 self,
tag_id: String,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn tag_contact_remove<'life0, 'async_trait>(
&'life0 self,
tag_id: String,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn tag_contact_delete<'life0, 'async_trait>(
&'life0 self,
tag_id: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn tag_contact_list<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn tag_list<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_alias<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<String, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_alias_set<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
alias: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_avatar<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<FileBox, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_avatar_set<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
file: FileBox,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_phone_set<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
phone_list: Vec<String>,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_corporation_remark_set<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
corporation_remark: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_description_set<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
description: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_list<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn contact_raw_payload<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<ContactPayload, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_contact<'life0, 'async_trait>(
&'life0 self,
message_id: String,
) -> Pin<Box<dyn Future<Output = Result<String, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_file<'life0, 'async_trait>(
&'life0 self,
message_id: String,
) -> Pin<Box<dyn Future<Output = Result<FileBox, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_image<'life0, 'async_trait>(
&'life0 self,
message_id: String,
image_type: ImageType,
) -> Pin<Box<dyn Future<Output = Result<FileBox, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_mini_program<'life0, 'async_trait>(
&'life0 self,
message_id: String,
) -> Pin<Box<dyn Future<Output = Result<MiniProgramPayload, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_url<'life0, 'async_trait>(
&'life0 self,
message_id: String,
) -> Pin<Box<dyn Future<Output = Result<UrlLinkPayload, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_send_contact<'life0, 'async_trait>(
&'life0 self,
conversation_id: String,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_send_file<'life0, 'async_trait>(
&'life0 self,
conversation_id: String,
file: FileBox,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_send_mini_program<'life0, 'async_trait>(
&'life0 self,
conversation_id: String,
mini_program_payload: MiniProgramPayload,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_send_text<'life0, 'async_trait>(
&'life0 self,
conversation_id: String,
text: String,
mention_id_list: Vec<String>,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_send_url<'life0, 'async_trait>(
&'life0 self,
conversation_id: String,
url_link_payload: UrlLinkPayload,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn message_raw_payload<'life0, 'async_trait>(
&'life0 self,
message_id: String,
) -> Pin<Box<dyn Future<Output = Result<MessagePayload, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn friendship_accept<'life0, 'async_trait>(
&'life0 self,
friendship_id: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn friendship_add<'life0, 'async_trait>(
&'life0 self,
contact_id: String,
hello: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn friendship_search_phone<'life0, 'async_trait>(
&'life0 self,
phone: String,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn friendship_search_weixin<'life0, 'async_trait>(
&'life0 self,
weixin: String,
) -> Pin<Box<dyn Future<Output = Result<Option<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn friendship_raw_payload<'life0, 'async_trait>(
&'life0 self,
friendship_id: String,
) -> Pin<Box<dyn Future<Output = Result<FriendshipPayload, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_invitation_accept<'life0, 'async_trait>(
&'life0 self,
room_invitation_id: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_invitation_raw_payload<'life0, 'async_trait>(
&'life0 self,
room_invitation_id: String,
) -> Pin<Box<dyn Future<Output = Result<RoomInvitationPayload, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_add<'life0, 'async_trait>(
&'life0 self,
room_id: String,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_avatar<'life0, 'async_trait>(
&'life0 self,
room_id: String,
) -> Pin<Box<dyn Future<Output = Result<FileBox, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_create<'life0, 'async_trait>(
&'life0 self,
contact_id_list: Vec<String>,
topic: Option<String>,
) -> Pin<Box<dyn Future<Output = Result<String, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_del<'life0, 'async_trait>(
&'life0 self,
room_id: String,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_qr_code<'life0, 'async_trait>(
&'life0 self,
room_id: String,
) -> Pin<Box<dyn Future<Output = Result<String, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_quit<'life0, 'async_trait>(
&'life0 self,
room_id: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_topic<'life0, 'async_trait>(
&'life0 self,
room_id: String,
) -> Pin<Box<dyn Future<Output = Result<String, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_topic_set<'life0, 'async_trait>(
&'life0 self,
room_id: String,
topic: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_list<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_raw_payload<'life0, 'async_trait>(
&'life0 self,
room_id: String,
) -> Pin<Box<dyn Future<Output = Result<RoomPayload, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_announce<'life0, 'async_trait>(
&'life0 self,
room_id: String,
) -> Pin<Box<dyn Future<Output = Result<String, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_announce_set<'life0, 'async_trait>(
&'life0 self,
room_id: String,
text: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_member_list<'life0, 'async_trait>(
&'life0 self,
room_id: String,
) -> Pin<Box<dyn Future<Output = Result<Vec<String>, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn room_member_raw_payload<'life0, 'async_trait>(
&'life0 self,
room_id: String,
contact_id: String,
) -> Pin<Box<dyn Future<Output = Result<RoomMemberPayload, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn start<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn stop<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn ding<'life0, 'async_trait>(
&'life0 self,
data: String,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn version<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<String, PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn logout<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<(), PuppetError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Auto Trait Implementations§
impl Freeze for PuppetService
impl !RefUnwindSafe for PuppetService
impl Send for PuppetService
impl Sync for PuppetService
impl Unpin for PuppetService
impl !UnwindSafe for PuppetService
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
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> 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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request