JSPM

@jswork/next-tx-cos-sdk

1.0.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • 0
  • Score
    100M100P100Q28678F
  • License MIT

Tencent cos-nodejs-sdk wrapper.

Package Exports

  • @jswork/next-tx-cos-sdk

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@jswork/next-tx-cos-sdk) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

next-tx-cos-sdk

Tencent cos-nodejs-sdk wrapper.

version license size download

installation

npm install -S @jswork/next-tx-cos-sdk

apis

api params description
get - desc balabala
put - desc balabala
del - desc balabala

usage

import NxTxCosSdk from '@jswork/next-tx-cos-sdk';

const config = {
  id: 'xxx',
  SecretId: 'xxxx',
  SecretKey: 'xxxxx'
};

// https://console.cloud.tencent.com/cos5/bucket
const nxCos = new NxTxCosSdk(config);

// create
nxCos
  .get({
    Bucket: 'img3-1301823685',
    Region: 'ap-chengdu'
  })
  .then((res) => {
    console.log(res);
  });

// // get
// nxCos.get().then((res) => {
//   console.log(res);
// });

// //delete
// nxCos
//   .del({
//     Bucket: 'img1-xxx',
//     Region: 'ap-chengdu'
//   })
//   .catch((err) => {
//     console.log(err);
//   });

resources

license

Code released under the MIT license.