# 用户订阅订单 API 文档 本文档描述了用户订阅订单相关的接口规范。 ## 1. 订阅订单列表 * **URL**: `/v2/user/subscribe/order/list` * **Method**: `GET` * **描述**: 分页查询用户订阅订单,包含订单详情、关联的用户基础信息及订阅配置信息。 ### 请求参数 | 字段名 | 类型 | 必填 | 说明 | | :--- | :--- | :--- | :--- | | `page` | integer | 否 | 页码,默认 1 | | `size` | integer | 否 | 每页大小,默认 10 | | `userId` | long | 否 | 用户ID | | `productId` | string | 否 | 产品ID | | `transactionId` | string | 否 | 交易ID | | `originalTransactionId` | string | 否 | 原始交易ID | | `startTime` | string | 否 | 开始时间 (yyyy-MM-dd HH:mm:ss) | | `endTime` | string | 否 | 结束时间 (yyyy-MM-dd HH:mm:ss) | ### 响应参数 (`data` 字段) 返回 Mybatis-Plus `Page` 对象,包含 `records` (记录列表), `total` (总数), `size` (页大小), `current` (当前页) 等。 `records` 中的对象 (`UserSubscribeOrderVO`) 结构如下: | 字段名 | 类型 | 说明 | | :--- | :--- | :--- | | `id` | long | 订单ID | | `userId` | long | 用户ID | | `productId` | string | 产品ID | | `subscribeId` | integer | 订阅ID | | `originalTransactionId` | string | 原始交易ID | | `transactionId` | string | 交易ID | | `expireTime` | string | 订阅过期时间 | | `createTime` | string | 创建时间 | | `nickname` | string | 用户昵称 | | `email` | string | 用户邮箱 | | `appleUserId` | string | 苹果用户ID | | `platform` | string | 平台 | | `language` | string | 语言 | | `subscribeType` | integer | 订阅类型(0:连续包月,1:连续包年) | | `subscribeTokens` | integer | 订阅赠送积分 | ### 示例请求 ```http GET /v2/user/subscribe/order/list?page=1&size=10&userId=10001&productId=com.aitori.monthly ``` ### 示例响应 ```json { "code": 200, "message": "success", "success": true, "data": { "records": [ { "id": 8001, "userId": 10001, "productId": "com.aitori.monthly", "subscribeId": 1, "originalTransactionId": "txn_orig_001", "transactionId": "txn_curr_001", "expireTime": "2024-11-30 23:59:59", "createTime": "2023-11-01 10:00:00", "nickname": "TestUser", "email": "test@example.com", "appleUserId": "apple_001", "platform": "IOS", "language": "en-US", "subscribeType": 0, "subscribeTokens": 500 } ], "total": 1, "size": 10, "current": 1, "pages": 1 }, "timestamp": 1698805000000 } ```