hapi-upyun
0.0.1 • Public • Published
{
plugin: 'hapi-upyun',
options: {
username: 'your username of upyun',
password: 'your password',
domain: 'url prefix',
bucket: 'bucket'
}
}
// const Joi = require('joi')
module.exports = ({ server }) => {
const { upload } = server.plugins['hapi-upyun']
return {
tags: ['api'],
description: '生成上传又拍云时需要的参数',
async handler (request, h) {
const data = upload.getBodyParams({ date: new Date() })
return data
}
}
}
Readme
Keywords
nonePackage Sidebar
Install
Weekly Downloads