Files
wx_service/docs/common
nepiedg 16844d4a42 Enhance AI and Redis integration for smoke logging features
- Added AI configuration options to .env.example and config.go for OpenAI integration.
- Implemented Redis caching for session management in main.go and auth middleware.
- Updated smoke logging service to support real smoking time (`smoke_at`) and AI advice retrieval.
- Enhanced API routes to include endpoints for AI advice and unlock functionality for non-members.
- Improved database schema with new tables for AI advice and unlock records.
- Expanded documentation to cover new AI features and Redis caching implementation.
2026-01-03 02:14:21 +00:00
..

公共说明

本目录存放所有小程序共用的接口约定与调用方式,避免每个子系统重复描述。

基础信息

  • 接口前缀:/api/v1
  • 健康检查:GET /healthz{"status":"ok"}

通用响应结构

本项目所有接口使用统一 JSON 结构(见:docs/common/response.md):

{
  "code": 200,
  "message": "success",
  "data": {}
}

认证方式

除登录接口外,其他接口都需要携带登录后返回的 session_key(见:docs/common/auth.md)。

上传(七牛直传)

  • docs/common/upload_qiniu.md

微信公众号

  • docs/common/wechat_official.md

Redis

  • docs/common/redis.md