Delete Plan
删除套餐。默认软删(is_active=False),hard=True 才是物理删除。
默认软删的原因:订单/用户可能仍引用该套餐 id,物理删除会让历史订单的 套餐信息失去关联、也让 _load_plan_map 之外的地方出现悬空引用。
注意:硬删不会清理 User.current_plan_id 的引用,也不会给受影响用户补差, 属于"确需清理脏数据"时才用的操作。
副作用:写库(硬删=DELETE,软删=UPDATE)+ 清套餐缓存。
delete/admin/plans/{plan_id}
Request
- Base URL: https://api.twtapi.com (the document declares no server; this is the origin it was published from)
- URL: https://api.twtapi.com/admin/plans/{plan_id}
- Auth: none declared
Path parameters
plan_idinteger required
Query parameters
hardboolean
True = permanently delete, False = soft-delete (set is_active=False)
Response
Successful Response
unknown required
Changes
No recorded changes to this operation across all 2 revisions of this API.