1.0.4 • Published 11 months ago
egg-feishu v1.0.4
egg-feishu
Egg's feishu plugin.
Install
$ npm i egg-feishu --save
Configuration
Change {app_root}/config/plugin.js
to enable egg-feishu
plugin:
exports.feishu = {
enable: true,
package: 'egg-feishu',
};
Simple connection
Config
// {app_root}/config/config.default.js
// const lark = require('@larksuiteoapi/node-sdk');
exports.feishu = {
appId: 'app id',
appSecret: 'app secret',
// appType: lark.AppType.SelfBuild,
// domain: lark.Domain.Feishu,
};
Example
// {app_root}/app/controller/user.js
exports.index = function* (ctx) {
ctx.body = yield ctx.app.feishu.contact.department.list();
}
Questions & Suggestions
Please open an issue here.
Contribution
If you are a contributor, follow CONTRIBUTING.