Files
mengyalinkfly/mengyalinkfly-backend/README.md
2025-12-14 15:11:17 +08:00

31 lines
608 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 萌芽短链接分发系统 - 后端
## 功能说明
- 生成4位随机字母数字组合的短链接支持大小写
- 检查短链接是否已被使用
- 创建和保存短链接
- 重定向到目标URL
## 安装依赖
```bash
pip install -r requirements.txt
```
## 运行
```bash
python app.py
```
服务将在 `http://localhost:5000` 启动
## API 接口
- `GET /api/check/<code>` - 检查短链接是否可用
- `GET /api/generate` - 生成随机可用短链接
- `POST /api/create` - 创建短链接
- `GET /<code>` - 跳转到目标链接
- `GET /api/links` - 获取所有链接列表