> ## Documentation Index
> Fetch the complete documentation index at: https://docs.subotiz.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 业务对象

订阅（Subscription）业务对象字段说明

| 属性名                    | 类型                 | 描述                                                                                                                                                           |
| ---------------------- | ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| id                     | string             | 订阅唯一标识                                                                                                                                                       |
| customer\_id           | string             | Subotiz 顾客唯一标识                                                                                                                                               |
| email                  | string             | 顾客邮箱                                                                                                                                                         |
| cycle\_index           | int                | 订阅当前所处周期                                                                                                                                                     |
| metadata               | map\[string]string | 元数据                                                                                                                                                          |
| cancel\_reason         | string             | 终止订阅的原因                                                                                                                                                      |
| sub\_merchant\_id      | string             | 商户唯一标识                                                                                                                                                       |
| status                 | string             | 订阅业务状态：<br />init - 待生效<br />trial - 试用期<br />active - 生效中<br />paused - 已暂停<br />past\_due - 逾期<br />unpaid - 未支付<br />canceled - 已终止<br />incomplete - 未完成 |
| price\_id              | string             | 商品定价方案唯一标识                                                                                                                                                   |
| total\_cycles          | int                | 总周期数（0表示无限期）                                                                                                                                                 |
| current\_period\_start | string             | 当前计费周期开始时间                                                                                                                                                   |
| current\_period\_end   | string             | 当前计费周期结束时间                                                                                                                                                   |
| next\_invoice\_date    | string             | 下一次续订时间                                                                                                                                                      |
| created\_at            | string             | 创建时间                                                                                                                                                         |
| updated\_at            | string             | 更新时间                                                                                                                                                         |
| cancel\_at             | string             | 终止订阅时间（可选）                                                                                                                                                   |
| order\_id              | string             | 接入方订单 id，创建 checkout session 时传入的 order\_id 一致。                                                                                                              |
| source\_trade\_id      | string             | 来源交易订单 ID                                                                                                                                                    |
| price\_type            | string             | 定价模型                                                                                                                                                         |
| price\_version\_id     | string             | 商品定价方案版本唯一标识                                                                                                                                                 |
| first\_source\_channel | string             | 该结账会话的首次创建来源                                                                                                                                                 |
| last\_source\_channel  | string             | 该结账会话的最后访问来源                                                                                                                                                 |
| fixed\_term            | string             | 固定期限期数。`"0"` 表示持续订阅（无固定期限）                                                                                                                                   |
| is\_renewable          | bool               | 是否支持到期后自动转为持续订阅                                                                                                                                              |
| end\_at                | string             | 订阅结束时间。空字符串表示持续订阅（无结束时间）                                                                                                                                     |
| current\_period        | int                | 当前周期序号                                                                                                                                                       |
| is\_canceling          | bool               | 是否正在取消中                                                                                                                                                      |
| launch\_cancel\_at     | string             | 发起取消的时间                                                                                                                                                      |
| expected\_cancel\_at   | string             | 预期取消的时间                                                                                                                                                      |
