No project description provided
Project description
Poste-sdk
poste操作助手
Poste服务部署
- 生成文档
cd docs && make html
- 在线文档
安装
pip install poste-sdk
简要使用
from poste_sdk.client import PosteClient
from poste_sdk.client import BoxClient
from poste_sdk.models import Mail
with PosteClient(address='管理账户', password='密码', domain='域名/ip', verify_ssl=False) as client:
# 初始化
box_client = client.init_box_client(email_prefix='test', password='test',domain=None)
assert isinstance(box_client, BoxClient)
# 获取最近1条邮件
mail = box_client.get_latest()
assert isinstance(mail, Mail)
# email 总数量
box_client.get_email_cnt()
# 获取指定邮件
mail = box_client.get_email(id_=1)
assert isinstance(mail, Mail)
# 删除邮件
box_client.delete_by_id(1)
# 清空邮件
box_client.drop_mails()
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
poste-sdk-0.1.11.tar.gz
(4.6 kB
view hashes)
Built Distribution
Close
Hashes for poste_sdk-0.1.11-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c0d408067458ae922c5947e3bfb56350e1e36bb04bac5d79cb611ac4d5e3a693 |
|
MD5 | ab3f09f6d74f10893475fa5620fda97f |
|
BLAKE2b-256 | 1b82eb3f364bc6b07cb0673a6c50fcec0cc7926596b3bb56df30bba8dca9d895 |