新增订阅计划
POST
/consoleapi/plans
求参数
Header 参数
Body 参数application/json
示例
{"name":"月度会员","label":"","durationConfig":6,// 1-月度会员 2-季度会员 3-半年会员 4-年度会员 5-终身会员 6-自定义"duration":{"value":2,"unit":"天"},"billing":[{"levelId":"51906c06-2a90-4cec-846e-60f5f88eccd4","salesPrice":12.5,"originalPrice":22.8,"label":"","status":true}]}求示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
求示例求示例
Shell
JavaScript
Java
Swift
curl--location'http://prod-cn.your-api-server.com/consoleapi/plans'\--header'Authorization: Bearer {{token}}'\--header'Content-Type: application/json'\--data'{ "name": "月度会员", "label": "", "durationConfig": 6, // 1-月度会员 2-季度会员 3-半年会员 4-年度会员 5-终身会员 6-自定义 "duration": { "value": 2, "unit": "天" }, "billing": [ { "levelId": "51906c06-2a90-4cec-846e-60f5f88eccd4", "salesPrice": 12.5, "originalPrice": 22.8, "label": "", "status": true } ]
}'返回响应
🟢201成功
application/json
Bodyapplication/json
示例
{"code":0,"message":"string","data":{"id":"string","createdAt":"string","updatedAt":"string","name":"string","label":"string","durationConfig":0,"duration":{},"billing":[{"label":"string","status":true,"levelId":"string","salesPrice":0,"originalPrice":0}],"levelCount":0},"timestamp":0}修改于2026-05-25 07:30:07
共 319 篇文档 · 内容同步自官方帮助中心