Skip to main content

This is a msg-robot for FeiShu.

Project description

PyFeishu

GitHub issues GitHub forks GitHub stars GitHub license contributors PyPI PyPI - Python Version Downloads

This is a msg-robot for feishu

Install

python -m pip install pyfeishu

Getting Started

send text msg

import pyfeishu
bot = pyfeishu.FeishuBot(app_id, app_secret)
msg = {"text": "test content"}
# @single user
# msg = {"text": "<at user_id='ou_xxx'>LiuKe</at>  \ntest content"}
# @all user
# msg = {"text": "<at  user_id='all'>所有人</at>  \ntest content"}
bot.send_msg(msg, 'chat_id'))

send image msg

image_key = bot.upload_image("img_path")
msg = {"image_key": image_key}
bot.send_msg(msg, 'chat_id', 'image')

Features

  • Automatically token management
  • Get chat id
  • Send text msg
  • Send rich text
  • Send image msg

Contributing

Contributions are welcome.
If you've found a bug within this project, please open an issue to discuss what you would like to change.
If it's an issue with the API, please report any new issues at pyfeishu issues

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

PyFeishu-0.2.0-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file PyFeishu-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: PyFeishu-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.26.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.7.9

File hashes

Hashes for PyFeishu-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 78da879c428832d31018933cc890118666dac8ca80f8d7ea99457cd9f4fa52e4
MD5 68ec7dc12c744420ae043d73000ce6a2
BLAKE2b-256 508934ef285b8ed44c9471429185beaa4061a55ca28d3e76e84c10cd2bc8e18f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page