aozhiwei 4802d24510 1
2024-05-11 16:45:27 +08:00

81 lines
2.1 KiB
JavaScript

const common = require('./common');
module.exports = class {
constructor() {
this.apis = [
{
'method': 'GET',
'name': 'list',
'desc': '获取邮件列表',
'group': 'mail',
'url': 'api/v1/mail/list',
'header': [
],
'is_json_params': true,
'params': [
],
'response': [
new common.RspHead(),
['!data', common.Mail()]
]
},
{
'method': 'POST',
'name': 'add',
'desc': '添加邮件',
'group': 'mail',
'url': 'api/v1/mail/add',
'header': [
],
'is_json_params': true,
'params': [
new common.RspHead(),
['mail_type', 0, '邮件类型'],
['subject', '', '邮件标题'],
['content', '', '邮件内容'],
['!recipients', '', '收件人列表'],
['!attachments', common.Attachment(), '邮件附件'],
['sendtime', 0, '发送时间'],
['user_reg_start_time', 0, '用户注册开始时间'],
['user_reg_end_time', 0, '用户注册结束时间'],
['expiretime', 0, '过期时间'],
],
'response': [
new common.RspHead(),
]
},
{
'method': 'POST',
'name': 'edit',
'desc': '添加邮件',
'group': 'mail',
'url': 'api/v1/mail/edit',
'header': [
],
'is_json_params': true,
'params': [
new common.RspHead(),
['mail_id', '', '邮件id'],
['mail_type', 0, '邮件类型'],
['subject', '', '邮件标题'],
['content', '', '邮件内容'],
['!recipients', '', '收件人列表'],
['!attachments', common.Attachment(), '邮件附件'],
['sendtime', 0, '发送时间'],
['user_reg_start_time', 0, '用户注册开始时间'],
['user_reg_end_time', 0, '用户注册结束时间'],
['expiretime', 0, '过期时间'],
],
'response': [
new common.RspHead(),
]
},
];
}
};