安装
pip install nonebot-plugin-shorturl
poetry add nonebot-plugin-shorturl
pdm add nonebot-plugin-shorturl
# 特定后端
pip install nonebot-plugin-shorturl[redis]
pip install nonebot-plugin-shorturl[diskcache]
# 所有后端
pip install nonebot-plugin-shorturl[all]
使用方式
在 .env 文件中添加必填的配置项
配置项
通用配置项
SHORTURL_HOST(必填):用于为外部插件构造完整的包含域名的短链接。示例值:http://localhost:8080SHORTURL_ENDPOINT:指定短链接服务的入口点模板。默认值:/shorturl/{token},可以自定义为/s/{token}等SHORTURL_CACHE_TYPE:指定短链接服务的后端缓存类型,可选值:memory|diskcache|redis
差分配置项
Redis
SHORTURL_REDIS_HOST:Redis 后端的地址SHORTURL_REDIS_PORT:Redis 后端的端口SHORTURL_REDIS_DB:Redis DB 配置项SHORTURL_REDIS_USERNAME:Redis 用户名SHORTURL_REDIS_PASSWORD:Redis 密码
Diskcache
SHORTURL_DISKCACHE_FOLDER:Diskcache 文件持久化目录
Metadata
Release files for nonebot-plugin-shorturl 0.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| nonebot_plugin_shorturl-0.4.0.tar.gz | 5.0 kB | Without provenance | Details for nonebot_plugin_shorturl-0.4.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nonebot_plugin_shorturl-0.4.0-py3-none-any.whl | Python 3 | none | any | Details for nonebot_plugin_shorturl-0.4.0-py3-none-any.whl |
Total release size: 12.0 kB
Release files / nonebot_plugin_shorturl-0.4.0.tar.gz
| Download URL | nonebot_plugin_shorturl-0.4.0.tar.gz |
|---|---|
| Size | 5.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9412cb5a27b69e1fa84d007257c7653ebcb0be8f2195674f9cc50668927fc04d
|
|
BLAKE2b-256 checksum How to use checksums |
6a0196d3fdc335a73886ba459b46c6abce0fb61eed7c1f4466309db507b7aa5f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/4.0.2 CPython/3.11.8
|
Release files / nonebot_plugin_shorturl-0.4.0-py3-none-any.whl
| Download URL | nonebot_plugin_shorturl-0.4.0-py3-none-any.whl |
|---|---|
| Size | 7.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
34f193ca06b2c5e7b7a793513c823c83d66d48d2116318e638b247be007d33d4
|
|
BLAKE2b-256 checksum How to use checksums |
5bfa977b2b053709be2abe2a62f9e7bb5b0892811888c8d4c3f4671c893be4d1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/4.0.2 CPython/3.11.8
|
Security for nonebot-plugin-shorturl 0.4.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.