nonebot.adapters.feishu.bot
async def send(bot, event, message, at_sender=False, **kwargs)
说明: 默认回复消息处理函数。
参数
bot(Bot)event(Event)message(str | Message | MessageSegment)at_sender(bool)**kwargs(Any)
返回
- Any
class Bot(adapter, self_id, *, bot_config, bot_info)
async method send_handler(event, message, at_sender=False, **kwargs)
说明: 默认回复消息处理函数。
参数
event(Event)message(str | Message | MessageSegment)at_sender(bool)**kwargs(Any)
返回
- Any
async method get_msgs(container_id_type, container_id, **params)
参数
container_id_type(Literal['chat'])container_id(str)**params(Any)
返回
- untyped
async method get_msg_resource(message_id, file_key, type_)
参数
message_id(str)file_key(str)type_(Literal['image', 'file'])
返回
- untyped
async method get_msg(message_id)
参数
message_id(str)
返回
- untyped
async method get_msg_read_users(message_id, user_id_type, page_size=None, page_token=None)
参数
message_id(str)user_id_type(str)page_size(int | None)page_token(str | None)
返回
- untyped
async method merge_forward_msg(receive_id_type, receive_id, message_id_list, uuid=None)
参数
receive_id_type(str)receive_id(str)message_id_list(list[str])uuid(str | None)
返回
- untyped
async method forward_msg(message_id, receive_id, receive_id_type, uuid=None)
参数
message_id(str)receive_id(str)receive_id_type(str)uuid(str | None)
返回
- untyped
async method delete_msg(message_id)
参数
message_id(str)
返回
- untyped
async method edit_msg(message_id, content, msg_type)
参数
message_id(str)content(str)msg_type(str)
返回
- untyped
async method reply_msg(message_id, content, msg_type, uuid=None)
参数
message_id(str)content(str)msg_type(str)uuid(str | None)
返回
- untyped
async method send_msg(receive_id_type, receive_id, content, msg_type)
参数
receive_id_type(Literal['chat_id', 'open_id'])receive_id(str)content(str)msg_type(str)
返回
- untyped
async method send(event, message, **kwargs)
说明: 根据
event向触发事件的主体回复消息。参数
event(Event): Event 对象message(str | Message | MessageSegment): 要发送的消息at_sender(bool): 是否 @ 事件主体**kwargs(Any): 其他参数,可以与 Adapter.custom_send 配合使用
返回
- Any: API 调用返回数据
异常
ValueError: 缺少
user_id,group_idNetworkError: 网络错误
ActionFailed: API 调用失败
async method call_api(api, **data)
说明: :说明: 调用 飞书 协议 API :参数:
api: str: API 名称**data: Any: API 参数 :返回: -Any: API 调用返回数据 :异常: -NetworkError: 网络错误 -ActionFailed: API 调用失败参数
api(str)**data
返回
- Any
async method handle_event(event)
参数
event(Event)
返回
- None