docs: 同步英文 README,ZPay 链接明文显示,添加 release workflow

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
erio
2026-03-03 08:17:59 +08:00
parent 90ad0e0895
commit 5992c06d67
3 changed files with 67 additions and 8 deletions

44
.github/workflows/release.yml vendored Normal file
View File

@@ -0,0 +1,44 @@
name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
jobs:
release:
name: Create Release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Generate changelog
id: changelog
run: |
# Get previous tag
PREV_TAG=$(git tag --sort=-v:refname | sed -n '2p')
if [ -z "$PREV_TAG" ]; then
COMMITS=$(git log --pretty=format:"- %s (%h)" HEAD)
else
COMMITS=$(git log --pretty=format:"- %s (%h)" "${PREV_TAG}..HEAD")
fi
{
echo 'body<<EOF'
echo "## What's Changed"
echo ""
echo "$COMMITS"
echo ""
echo "**Full Changelog**: https://github.com/${{ github.repository }}/compare/${PREV_TAG:-$(git rev-list --max-parents=0 HEAD | head -1)}...${{ github.ref_name }}"
echo 'EOF'
} >> "$GITHUB_OUTPUT"
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
body: ${{ steps.changelog.outputs.body }}
generate_release_notes: false

View File

@@ -116,6 +116,17 @@ ENABLED_PAYMENT_TYPES=alipay,wxpay
#### EasyPay (Alipay / WeChat Pay)
Any payment provider compatible with the **EasyPay protocol** can be used, such as ZPay (`https://z-pay.cn/?uid=23808`) (this link contains the author's referral code — feel free to remove it).
<details>
<summary>ZPay Registration QR Code</summary>
![ZPay Preview](./docs/zpay-preview.png)
</details>
> **Disclaimer**: Please evaluate the security, reliability, and compliance of any third-party payment provider on your own. This project does not endorse or guarantee any specific provider.
| Variable | Description |
|----------|-------------|
| `EASY_PAY_PID` | EasyPay merchant ID |
@@ -256,13 +267,15 @@ docker compose exec app npx prisma migrate deploy
Configure the recharge URL in the Sub2API admin panel:
```
https://pay.example.com/pay?user_id={USER_ID}&token={TOKEN}&theme={THEME}
https://pay.example.com/pay
```
Sub2API **v0.1.88** and above will automatically append the following parameters — no manual query string needed:
| Parameter | Description |
|-----------|-------------|
| `user_id` | Sub2API user ID (required) |
| `token` | User login token (optional — required to view order history) |
| `user_id` | Sub2API user ID |
| `token` | User login token (required to view order history) |
| `theme` | `light` (default) or `dark` |
| `ui_mode` | `standalone` (default) or `embedded` (for iframe) |

View File

@@ -116,10 +116,10 @@ ENABLED_PAYMENT_TYPES=alipay,wxpay
#### EasyPay支付宝 / 微信支付)
支付提供商只需兼容**易支付EasyPay协议**即可接入,例如 [ZPay](https://z-pay.cn/?uid=23808) 等平台(链接含本项目作者的邀请码,介意可去掉)。
支付提供商只需兼容**易支付EasyPay协议**即可接入,例如 ZPay`https://z-pay.cn/?uid=23808`等平台(链接含本项目作者的邀请码,介意可去掉)。
<details>
<summary>ZPay 平台预览</summary>
<summary>ZPay 申请二维码</summary>
![ZPay 预览](./docs/zpay-preview.png)
@@ -267,13 +267,15 @@ docker compose exec app npx prisma migrate deploy
在 Sub2API 管理后台将充值链接配置为:
```
https://pay.example.com/pay?user_id={USER_ID}&token={TOKEN}&theme={THEME}
https://pay.example.com/pay
```
Sub2API **v0.1.88** 及以上版本会自动拼接以下参数,无需手动添加:
| 参数 | 说明 |
|------|------|
| `user_id` | Sub2API 用户 ID(必填) |
| `token` | 用户登录 Token可选,有 token 才能查看订单历史) |
| `user_id` | Sub2API 用户 ID |
| `token` | 用户登录 Token有 token 才能查看订单历史) |
| `theme` | `light`(默认)或 `dark` |
| `ui_mode` | `standalone`(默认)或 `embedded`iframe 嵌入) |