0.0.3 • Published 4 years ago

@axolo/egg-cos-sts v0.0.3

Weekly downloads
1
License
MIT
Repository
github
Last release
4 years ago

egg-cos-sts

Tencent cloud COS STS SDK plugin for Egg.js.

Install

npm i @axolo/egg-cos-sts --save

Usage

// {app_root}/config/plugin.js
exports.cosSts = {
  enable: true,
  package: '@axolo/egg-cos-sts',
};

Configuration

// {app_root}/config/config.default.js
exports.cosSts = {
};

see config/config.default.js for more detail.

API

getCredential( options )

paramstypedesc
optionsObjectmerge to plugin options
returnPromiseSTS Credential

getPolicy(scope)

paramstypedesc
scopeArraystatement array of COS STS
returnObjectCOS STS policy like options

Questions & Suggestions

Please open an issue here.

License

MIT

TODO

  • Cache Adapter