feishu chatbot api
Project description
简介
基于飞书官方文档,封装的飞书消息机器人接口。支持简单的消息格式校验,获取发送消息所需 file_key, image_key 等。更多使用示例,可参考接口文档。
使用示例
安装
pip install -U feishu-chatbot
发送文本
from chatbot import ChatBotClient, TextChatBot
client = ChatBotClient(app_id="xxx", app_secret='xxx')
user = client.get_user_id_by_email("jack@gmail.com")
data = {
"msg_type": "text",
"content": {"text": "示例文本消息"},
"receive_id": user["open_id"],
}
chatbot = TextChatBot.set_client(client).set_data(data).build()
chatbot.send()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
feishu_chatbot-0.0.5.tar.gz
(15.3 kB
view hashes)
Built Distribution
Close
Hashes for feishu_chatbot-0.0.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d3c0629d749089fb9077f309aed5a2a1bffb4439d894e1fdb649e0da758b5085 |
|
MD5 | be28277a6ad49283c7db6693e71a91aa |
|
BLAKE2b-256 | bfa71a783ba3e0c8127386bfb2414bc937f01f9665a8ed4c2014fa09c28ac2b7 |