对应 weibo-webhook 的提交器
Project description
weibo-poster
✨ 基于 weibo-webhook 的博文提交器 ✨
额 pip 会用不
pip install weibo-poster
python 会写不
from bilibili_api.live import LiveDanmaku
from weibo_poster import Poster, WeiboRequest
room = LiveDanmaku(21452505)
poster = Poster(188888131, "", "")
session = WeiboRequest("")
@room.on("DANMU_MSG")
async def recv(event):
print("1")
async def weibo(uid: str):
post = None
async for post in session.posts(uid):
await poster.update(post)
if post is not None:
async for comment in session.comments(post):
if comment.uid == uid:
await poster.update(comment)
Poster.add_job(fn=weibo, name="七海", count=1, start=2, args=["7198559139"])
Poster.run(room.connect, poster)
哦那你就会了
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
weibo-poster-0.0.2.tar.gz
(8.9 kB
view details)
File details
Details for the file weibo-poster-0.0.2.tar.gz
.
File metadata
- Download URL: weibo-poster-0.0.2.tar.gz
- Upload date:
- Size: 8.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f2ac2303e190f79bc06ba4915b55a6974289a24880254fd9d288ecd1bec6245b |
|
MD5 | 0724b0447a4d3950a14b2f1eaa7f1552 |
|
BLAKE2b-256 | 81ef95d9db9841fbdc036142dd24583807ce5313c1cd23df3b64768be8574fa7 |