const codeController = require('../controllers/code') const koa_router = require('koa-router'); const router = koa_router(); /** * @api {post} code/slide 获取滑块验证码 * @apiVersion 1.0.0 * @apiName getSlide * @apiGroup code * @apiHeader {String} authorization 用户授权token * @apiSuccessExample Success-Response: * HTTP/1.1 200 OK * { * "data": { * "image": "", // 主图 * "fragment": "" // 滑块图 * }, * "success": true * } * @apiErrorExample Error-Response: * * { * "success": false, * "msg": "服务器错误..." * } * * */ router.post('/slide', codeController.getSlide) module.exports = router