{"_id":"@beajer-test/ali-oss","_rev":"2-b3f2f3f7b7b328051cb240506fa923f0","name":"@beajer-test/ali-oss","dist-tags":{"latest":"1.0.1"},"versions":{"1.0.0":{"name":"@beajer-test/ali-oss","version":"1.0.0","description":"aliyun oss(object storage service) node client","main":"lib/node/index.js","typings":"lib/node/index.d.ts","browser":{"lib/node/index.js":"lib/browser/","mime":"mime/lite","urllib":"./shims/xhr.js","utility":"./shims/utility.js","crypto":"./shims/crypto/crypto.js","debug":"./shims/debug","platform":"./shims/platform","fs":false,"child_process":false,"is-type-of":"./shims/is-type-of.js","constants":"constants-browserify","http":"stream-http","https":"stream-http","stream":"stream-browserify","path":"path-browserify","process":"./shims/process.js","url":"./shims/url/index.js","buffer":"buffer"},"scripts":{"build-change-log":"standard-version","test":"mocha -t 60000 -r thunk-mocha -r should -r dotenv/config test/node/*.test.js test/node/**/*.test.js","test-cov":"nyc --reporter=lcov node_modules/.bin/_mocha -t 60000 -r thunk-mocha -r should test/node/*.test.js test/node/**/*.test.js","jshint":"jshint .","autod":"autod","build-test":"MINIFY=1 node browser-build.js > test/browser/build/aliyun-oss-sdk.min.js && node -r dotenv/config task/browser-test-build.js > test/browser/build/tests.js","browser-test":"npm run build-test && karma start","build-dist":"npm run tsc && node browser-build.js > dist/aliyun-oss-sdk.js && MINIFY=1 node browser-build.js > dist/aliyun-oss-sdk.min.js","publish-to-npm":"node publish-npm-check.js && npm publish","publish-to-cdn":"node publish.js","snyk-protect":"snyk protect","prepublish":"npm run snyk-protect","lint-staged":"lint-staged","detect-secrets":"node task/detect-secrets","tsc":"npm run tsc:clean && npm run tsc:build","tsc:build":"tsc -b tsconfig-es.json tsconfig-cjs.json","tsc:watch":"tsc -b tsconfig-es.json tsconfig-cjs.json --watch","tsc:clean":"tsc -b tsconfig-es.json tsconfig-cjs.json --clean "},"git-pre-hooks":{"pre-release":"npm run build-dist","post-release":["npm run publish-to-npm","npm run publish-to-cdn"],"pre-commit":"npm run lint-staged"},"repository":{"type":"git","url":"git+https://github.com/beajer/ali-oss.git"},"keywords":["oss","client","file","aliyun"],"license":"MIT","bugs":{"url":"https://github.com/beajer/ali-oss/issues"},"engines":{"node":">=8"},"homepage":"https://github.com/beajer/ali-oss#readme","devDependencies":{"@babel/core":"^7.11.6","@babel/plugin-transform-regenerator":"^7.10.4","@babel/plugin-transform-runtime":"^7.11.5","@babel/preset-env":"^7.11.5","@babel/runtime":"^7.11.2","@types/node":"^14.0.12","@typescript-eslint/eslint-plugin":"^2.34.0","@typescript-eslint/parser":"^2.34.0","aliasify":"^2.0.0","autod":"^2.6.1","babelify":"^10.0.0","beautify-benchmark":"^0.2.4","benchmark":"^2.1.1","bluebird":"^3.1.5","browserify":"^16.5.2","buffer":"^6.0.3","co-fs":"^1.2.0","co-mocha":"^1.2.1","constants-browserify":"^1.0.0","core-js":"^3.6.5","crypto-js":"^3.1.9-1","dotenv":"^8.2.0","eslint":"^6.8.0","eslint-config-airbnb":"^16.1.0","eslint-config-ali":"^9.0.2","eslint-plugin-import":"^2.21.1","eslint-plugin-jsx-a11y":"^6.0.3","eslint-plugin-react":"^7.7.0","filereader":"^0.10.3","git-pre-hooks":"^1.2.0","https-browserify":"^1.0.0","immediate":"^3.3.0","karma":"^1.7.1","karma-browserify":"^5.1.1","karma-chrome-launcher":"^2.2.0","karma-firefox-launcher":"^1.0.1","karma-ie-launcher":"^1.0.0","karma-mocha":"^1.3.0","karma-safari-launcher":"^1.0.0","lint-staged":"^9.5.0","mm":"^2.0.0","mocha":"^3.5.3","nyc":"^13.3.0","path-browserify":"^1.0.1","promise-polyfill":"^6.0.2","request":"^2.88.0","should":"^11.0.0","sinon":"^1.17.7","snyk":"1.454.0","standard-version":"^8.0.1","stream-browserify":"^3.0.0","stream-equal":"^1.1.0","thunk-mocha":"^1.0.3","timemachine":"^0.3.0","typescript":"^3.9.5","uglify-js":"^2.8.29","watchify":"^3.9.0"},"dependencies":{"address":"^1.0.0","agentkeepalive":"^3.4.1","bowser":"^1.6.0","co-defer":"^1.0.0","copy-to":"^2.0.1","crc64-ecma182":"^1.0.0","dateformat":"^2.0.0","debug":"^2.2.0","destroy":"^1.0.4","end-or-error":"^1.0.1","get-ready":"^1.0.0","humanize-ms":"^1.2.0","is-type-of":"^1.0.0","js-base64":"^2.5.2","jstoxml":"^0.2.3","merge-descriptors":"^1.0.1","mime":"^2.4.5","mz-modules":"^2.1.0","platform":"^1.3.1","pump":"^3.0.0","sdk-base":"^2.0.1","stream-http":"2.8.2","stream-wormhole":"^1.0.4","urllib":"^2.33.1","utility":"^1.8.0"},"snyk":true,"lint-staged":{"**/!(dist)/*":["npm run detect-secrets --"]},"sideEffects":["src/browser/polyfill.ts","es/browser/polyfill.js","lib/browser/polyfill.js"],"contributors":[{"name":"PeterRao","email":"peizerao@gmail.com","url":"https://github.com/PeterRao"},{"name":"dead_horse","email":"dead_horse@qq.com"},{"name":"chunpu","email":"fengtong@mail.ustc.edu.cn"},{"name":"fengmk2","email":"m@fengmk2.com","url":"https://github.com/fengmk2"},{"name":"Yan Qing","email":"admin@zensh.com","url":"https://github.com/zensh"},{"name":"mars-coder","email":"mars.ll@alibaba-inc.com","url":"https://github.com/mars-coder"},{"name":"Jacky Tang","email":"jackytck@gmail.com","url":"https://github.com/jackytck"}],"gitHead":"dc793be355e2e9371733f7b74b2139eec74e575d","_id":"@beajer-test/ali-oss@1.0.0","_nodeVersion":"12.16.3","_npmVersion":"6.14.4","dist":{"integrity":"sha512-MntTXJJWfGYtG8bePWAR3SqB2jZ9cT4OjdN4FO3XAR70LNcQe4E5YgysoegwpwbMI7anX0psvfs7nuhwpspnpg==","shasum":"fa56b0c18ac2a630d7a4fd9b02bdac5ebceeeb12","tarball":"https://registry.npmjs.org/@beajer-test/ali-oss/-/ali-oss-1.0.0.tgz","fileCount":416,"unpackedSize":2410492,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgp2qzCRA9TVsSAnZWagAAJQ8P/2IPcZdHarsRoUykezXK\nmv+wEhb8rYmTzGjlbJaSizKyuvnglUFHP7OPh/DEQWJfLyE8NUlYj+sKIZW5\nIdU9GZXGxJKcAuGjPSmmy81lcJjf4GEXh/Hk3t+Mhv7KXvIQlIPNAxNMPm2d\ntom9Dk0NCDmnopGkkIesynYXNu+JK9wripHPqyb/qMbHcGMIAj8HAlbsgwpo\n2U+VWFweXrFfrl2XlSA6WAz//tEu3VB1eidWLXp6RzGq2/xmmCFX3BnF6+WO\n5TSK2EhIc/1y3/1w26rXz+iwqsD9cncfLJ+Tnm1v9fHvpPDYoYfuY6/5s4vI\njyV0o1sKG2hL7rM4OaDWzSIPQjmuaggXjXRJKgFjde69zxZOPiL0+d1/YKFS\n33gwAbumAC52lJemYRYlWMI3Li/QSIF7HqzbwkkecBS9rh5UR+c4CW+0HBkO\nwfV10xDwiuhFPvN4Y7aVN5DoYzyz3tPMCxpbTFBhm75BTNgSF60F+vqOrb0c\nUAamLEzfOGpZknY4fgC3ylGUyUSC0rZLEAVff3BRjNUr/bNEgxsR1PvcE06/\nqdBBLyg0mvs5imp7VaCrMfRY+hOL6f+QpHr+neHOl9bJGbis3QMPMHhQ910J\nQs7ZWOssTfryPurdG04wZALg4g5kxQy8imZS8iSR5aMl/JsS72fin9Q/J+iH\npG7T\r\n=zgdf\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBeRcpJjXrHqagWWZK3Yg/bHF2yN3Rgx43bIwZCIH45BAiEAtcu8x/jSrNQhPru2HefcHZ46MfjHj6UEKGiDvHOuApQ="}]},"_npmUser":{"name":"beajer","email":"919060679@qq.com"},"directories":{},"maintainers":[{"name":"beajer","email":"919060679@qq.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ali-oss_1.0.0_1621584562685_0.2048906148147711"},"_hasShrinkwrap":false},"1.0.1":{"name":"@beajer-test/ali-oss","version":"1.0.1","description":"aliyun oss(object storage service) node client","main":"lib/node/index.js","typings":"lib/node/index.d.ts","browser":{"lib/node/index.js":"lib/browser/","mime":"mime/lite","urllib":"./shims/xhr.js","utility":"./shims/utility.js","crypto":"./shims/crypto/crypto.js","debug":"./shims/debug","platform":"./shims/platform","fs":false,"child_process":false,"is-type-of":"./shims/is-type-of.js","constants":"constants-browserify","http":"stream-http","https":"stream-http","stream":"stream-browserify","path":"path-browserify","process":"./shims/process.js","url":"./shims/url/index.js","buffer":"buffer"},"scripts":{"build-change-log":"standard-version","test":"mocha -t 60000 -r thunk-mocha -r should -r dotenv/config test/node/*.test.js test/node/**/*.test.js","test-cov":"nyc --reporter=lcov node_modules/.bin/_mocha -t 60000 -r thunk-mocha -r should test/node/*.test.js test/node/**/*.test.js","jshint":"jshint .","autod":"autod","build-test":"MINIFY=1 node browser-build.js > test/browser/build/aliyun-oss-sdk.min.js && node -r dotenv/config task/browser-test-build.js > test/browser/build/tests.js","browser-test":"npm run build-test && karma start","build-dist":"npm run tsc && node browser-build.js > dist/aliyun-oss-sdk.js && MINIFY=1 node browser-build.js > dist/aliyun-oss-sdk.min.js","publish-to-npm":"node publish-npm-check.js && npm publish","publish-to-cdn":"node publish.js","snyk-protect":"snyk protect","prepublish":"npm run snyk-protect","lint-staged":"lint-staged","detect-secrets":"node task/detect-secrets","tsc":"npm run tsc:clean && npm run tsc:build","tsc:build":"tsc -b tsconfig-es.json tsconfig-cjs.json","tsc:watch":"tsc -b tsconfig-es.json tsconfig-cjs.json --watch","tsc:clean":"tsc -b tsconfig-es.json tsconfig-cjs.json --clean "},"git-pre-hooks":{"pre-release":"npm run build-dist","post-release":["npm run publish-to-npm","npm run publish-to-cdn"],"pre-commit":"npm run lint-staged"},"repository":{"type":"git","url":"git+https://github.com/beajer/ali-oss.git"},"keywords":["oss","client","file","aliyun"],"license":"MIT","bugs":{"url":"https://github.com/beajer/ali-oss/issues"},"engines":{"node":">=8"},"homepage":"https://github.com/beajer/ali-oss#readme","devDependencies":{"@babel/core":"^7.11.6","@babel/plugin-transform-regenerator":"^7.10.4","@babel/plugin-transform-runtime":"^7.11.5","@babel/preset-env":"^7.11.5","@babel/runtime":"^7.11.2","@types/node":"^14.0.12","@typescript-eslint/eslint-plugin":"^2.34.0","@typescript-eslint/parser":"^2.34.0","aliasify":"^2.0.0","autod":"^2.6.1","babelify":"^10.0.0","beautify-benchmark":"^0.2.4","benchmark":"^2.1.1","bluebird":"^3.1.5","browserify":"^16.5.2","buffer":"^6.0.3","co-fs":"^1.2.0","co-mocha":"^1.2.1","constants-browserify":"^1.0.0","core-js":"^3.6.5","crypto-js":"^3.1.9-1","dotenv":"^8.2.0","eslint":"^6.8.0","eslint-config-airbnb":"^16.1.0","eslint-config-ali":"^9.0.2","eslint-plugin-import":"^2.21.1","eslint-plugin-jsx-a11y":"^6.0.3","eslint-plugin-react":"^7.7.0","filereader":"^0.10.3","git-pre-hooks":"^1.2.0","https-browserify":"^1.0.0","immediate":"^3.3.0","karma":"^1.7.1","karma-browserify":"^5.1.1","karma-chrome-launcher":"^2.2.0","karma-firefox-launcher":"^1.0.1","karma-ie-launcher":"^1.0.0","karma-mocha":"^1.3.0","karma-safari-launcher":"^1.0.0","lint-staged":"^9.5.0","mm":"^2.0.0","mocha":"^3.5.3","nyc":"^13.3.0","path-browserify":"^1.0.1","promise-polyfill":"^6.0.2","request":"^2.88.0","should":"^11.0.0","sinon":"^1.17.7","snyk":"1.454.0","standard-version":"^8.0.1","stream-browserify":"^3.0.0","stream-equal":"^1.1.0","thunk-mocha":"^1.0.3","timemachine":"^0.3.0","typescript":"^3.9.5","uglify-js":"^2.8.29","watchify":"^3.9.0"},"dependencies":{"address":"^1.0.0","agentkeepalive":"^3.4.1","bowser":"^1.6.0","co-defer":"^1.0.0","copy-to":"^2.0.1","crc64-ecma182":"^1.0.0","dateformat":"^2.0.0","debug":"^2.2.0","destroy":"^1.0.4","end-or-error":"^1.0.1","get-ready":"^1.0.0","humanize-ms":"^1.2.0","is-type-of":"^1.0.0","js-base64":"^2.5.2","jstoxml":"^0.2.3","merge-descriptors":"^1.0.1","mime":"^2.4.5","mz-modules":"^2.1.0","platform":"^1.3.1","pump":"^3.0.0","sdk-base":"^2.0.1","stream-http":"2.8.2","stream-wormhole":"^1.0.4","urllib":"^2.33.1","utility":"^1.8.0"},"snyk":true,"lint-staged":{"**/!(dist)/*":["npm run detect-secrets --"]},"sideEffects":["src/browser/polyfill.ts","es/browser/polyfill.js","lib/browser/polyfill.js"],"contributors":[{"name":"PeterRao","email":"peizerao@gmail.com","url":"https://github.com/PeterRao"},{"name":"dead_horse","email":"dead_horse@qq.com"},{"name":"chunpu","email":"fengtong@mail.ustc.edu.cn"},{"name":"fengmk2","email":"m@fengmk2.com","url":"https://github.com/fengmk2"},{"name":"Yan Qing","email":"admin@zensh.com","url":"https://github.com/zensh"},{"name":"mars-coder","email":"mars.ll@alibaba-inc.com","url":"https://github.com/mars-coder"},{"name":"Jacky Tang","email":"jackytck@gmail.com","url":"https://github.com/jackytck"}],"gitHead":"9a96508f04611255cec447cd0aed7bed82ec293c","_id":"@beajer-test/ali-oss@1.0.1","_nodeVersion":"12.16.3","_npmVersion":"6.14.4","dist":{"integrity":"sha512-goYapzXUjHqcNHtKDR4PDdFv1tm8GMN40NiikHIi++qXqQTTgm2R9lxkECbf5q6AB9FqxlJOLIunMHJZQ8T/fg==","shasum":"78dac31469980d36e4d405f2e3c65745732e717a","tarball":"https://registry.npmjs.org/@beajer-test/ali-oss/-/ali-oss-1.0.1.tgz","fileCount":755,"unpackedSize":2647654,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgp3AHCRA9TVsSAnZWagAAgvwP/j6tq+pQppxkJbb8+r7o\nuy9mPdPn12AfNojGodxU9g4UQ8pp2hG7FzkEIn5xl8uq6Uigc6/BMfe+zzaC\nBCWk/J0Cilk+m1KiGB/mrmCyyE6iFKVeWBM4/p2pF+eM4ASZ19dpd/qaKOgl\nzGZLslfvLhogZ4bICBTnWGOC4z1rZ8MJFXvlhuEjgfAHhyCZTjPkd+cghSpw\nvigehe8IjFIuYUMOlrkCBW0q8blOLqayo2/5SbsWonLdB4uoL8teW8audeax\nApDsUo9nb+oQPNt+XKnpOg3vMsx8Ah+GvVu+VPrFa4tmtwLlh5/KvFcXUv+4\ns5UKMjSn/JJ4N2ig/zF4aujYPNjySTGd+Lr8RF0mtiHMaKh5jJR5j92Tt/5+\naT4GxZqSgs3RTWvemzH0Ky/e0lAI929d0iVA5wUfO3XYuUNAq3LgFpD9NQnk\nfblfdTUn6ch4aPWkayN8ELaOs8wiT9YNZaZJD/OHPxSAsLh+4cgJpH0w1pVn\n3Emzj+8zXs7FfvhhDRJhxcMBciYWbLDHdKj8JZVVvJkEN0Ef5AasctA2cMR4\n1eyJD5d3eKXqtAwpW7HpfHZYCkLlbhUZspq1cacy3QZY1Vi/xRE4kB682eSy\naKCsscxS1IlFC4/AeVu4QPP/RcRuxXTbVOfrEtTmdcEV3XIeLJ/5t/ezuix4\nTPkd\r\n=26xI\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGtKDkfwZB/nklQncZF3ZGpPyc46CUbpPeBbWBrmeK4jAiBi1B+Ejy5sEfoPvMmLilhpjtDFW+ZklH0glJe142ZaZQ=="}]},"_npmUser":{"name":"beajer","email":"919060679@qq.com"},"directories":{},"maintainers":[{"name":"beajer","email":"919060679@qq.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ali-oss_1.0.1_1621585926455_0.6743123853594666"},"_hasShrinkwrap":false}},"time":{"created":"2021-05-21T08:09:22.342Z","1.0.0":"2021-05-21T08:09:22.925Z","modified":"2022-04-04T18:05:06.801Z","1.0.1":"2021-05-21T08:32:06.756Z"},"maintainers":[{"name":"beajer","email":"919060679@qq.com"}],"description":"aliyun oss(object storage service) node client","homepage":"https://github.com/beajer/ali-oss#readme","keywords":["oss","client","file","aliyun"],"repository":{"type":"git","url":"git+https://github.com/beajer/ali-oss.git"},"contributors":[{"name":"PeterRao","email":"peizerao@gmail.com","url":"https://github.com/PeterRao"},{"name":"dead_horse","email":"dead_horse@qq.com"},{"name":"chunpu","email":"fengtong@mail.ustc.edu.cn"},{"name":"fengmk2","email":"m@fengmk2.com","url":"https://github.com/fengmk2"},{"name":"Yan Qing","email":"admin@zensh.com","url":"https://github.com/zensh"},{"name":"mars-coder","email":"mars.ll@alibaba-inc.com","url":"https://github.com/mars-coder"},{"name":"Jacky Tang","email":"jackytck@gmail.com","url":"https://github.com/jackytck"}],"bugs":{"url":"https://github.com/beajer/ali-oss/issues"},"license":"MIT","readme":"# oss-js-sdk\r\n\r\n[![NPM version][npm-image]][npm-url]\r\n[![build status][travis-image]][travis-url]\r\n[![coverage][cov-image]][cov-url]\r\n[![David deps][david-image]][david-url]\r\n\r\n[npm-image]: https://img.shields.io/npm/v/ali-oss.svg?style=flat-square\r\n[npm-url]: https://npmjs.org/package/ali-oss\r\n[travis-image]: https://img.shields.io/travis/ali-sdk/ali-oss/master.svg?style=flat-square\r\n[travis-url]: https://travis-ci.org/ali-sdk/ali-oss.svg?branch=master\r\n[cov-image]: http://codecov.io/github/ali-sdk/ali-oss/coverage.svg?branch=master\r\n[cov-url]: http://codecov.io/github/ali-sdk/ali-oss?branch=master\r\n[david-image]: https://img.shields.io/david/ali-sdk/ali-oss.svg?style=flat-square\r\n[david-url]: https://david-dm.org/ali-sdk/ali-oss\r\n\r\naliyun OSS(Object Storage Service) js client for Node and Browser env.\r\n\r\n`NOTE`： For SDK `5.X` document, please go to [README.md](https://github.com/ali-sdk/ali-oss/blob/5.x/README.md)\r\n\r\n## Install\r\n\r\n```bash\r\nnpm install ali-oss --save\r\n```\r\n\r\n## Compatibility\r\n\r\n### Node\r\n\r\nNode.js >= 8.0.0 required. You can use 4.x in Node.js < 8.\r\n\r\n### Browser\r\n\r\n- IE >= 10 & Edge\r\n- Major versions of Chrome/Firefox/Safari\r\n- Major versions of Android/iOS/WP\r\n\r\n`Note`:\r\n\r\n- For Lower browsers you can refer to [PostObject](https://help.aliyun.com/document_detail/31988.html), if you want to see more practices ,please refer to [Web Post](https://help.aliyun.com/document_detail/31923.html)\r\n\r\n### Tree Shaking\r\n\r\n- [Guide](https://github.com/ali-sdk/ali-oss/blob/ts/ts-guide.md)\r\n\r\n### QA\r\n\r\nYou can join DingDing Talk Group, [Group Link](https://qr.dingtalk.com/action/joingroup?code=v1,k1,inkSDqCxm7LilkaR/kknRVBDQ8PDA0Lj5hj4Cf9io3w=&_dt_no_comment=1&origin=11)\r\n\r\n<img src=\"task/dingding.jpg\" height=\"400\" title=\"dingding\" width=\"300\">\r\n\r\n## License\r\n\r\n[MIT](LICENSE)\r\n\r\n# OSS Usage\r\n\r\nOSS, Object Storage Service. Equal to well known Amazon [S3](http://aws.amazon.com/s3/).\r\n\r\nAll operation use es7 async/await to implement. All api is async function.\r\n\r\n## Summary\r\n\r\n- [Node Usage](#node-usage)\r\n- [Browser Usage](#browser-usage)\r\n- [Data Regions](#data-regions)\r\n- [Create Account](#create-account)\r\n- [Create A Bucket Instance](#create-a-bucket-instance)\r\n  - [oss(options)](#ossoptions)\r\n- [Bucket Operations](#bucket-operations)\r\n  - Base\r\n    - [.listBuckets(query[, options])](#listbucketsquery-options)\r\n    - [.putBucket(name[, options])](#putbucketname-options)\r\n    - [.useBucket(name)](#usebucketname)\r\n    - [.deleteBucket(name[, options])](#deletebucketname-options)\r\n    - [.getBucketInfo(name)](#getbucketinfoname)\r\n    - [.getBucketLocation(name)](#getbucketlocationname)\r\n  - ACL\r\n    - [.putBucketACL(name, acl[, options])](#putbucketaclname-acl-options)\r\n    - [.getBucketACL(name[, options])](#getbucketaclname-options)\r\n  - Logging\r\n    - [.putBucketLogging(name, prefix[, options])](#putbucketloggingname-prefix-options)\r\n    - [.getBucketLogging(name[, options])](#getbucketloggingname-options)\r\n    - [.deleteBucketLogging(name[, options])](#deletebucketloggingname-options)\r\n  - Website\r\n    - [.putBucketWebsite(name, config[, options])](#putbucketwebsitename-config-options)\r\n    - [.getBucketWebsite(name[, options])](#getbucketwebsitename-options)\r\n    - [.deleteBucketWebsite(name, region[, options])](#deletebucketwebsitename-options)\r\n  - Referer\r\n    - [.putBucketReferer(name, allowEmpty, referers[, options])](#putbucketreferername-allowempty-referers-options)\r\n    - [.getBucketReferer(name[, options])](#getbucketreferername-options)\r\n    - [.deleteBucketReferer(name[, options])](#deletebucketreferername-options)\r\n  - Lifecycle\r\n    - [.putBucketLifecycle(name, rules[, options])](#putbucketlifecyclename-rules-options)\r\n    - [.getBucketLifecycle(name[, options])](#getbucketlifecyclename-options)\r\n    - [.deleteBucketLifecycle(name[, options])](#deletebucketlifecyclename-options)\r\n  - CORS\r\n    - [.putBucketCORS(name, rules[, options])](#putbucketcorsname-rules-options)\r\n    - [.getBucketCORS(name[, options])](#getbucketcorsname-options)\r\n    - [.deleteBucketCORS(name[, options])](#deletebucketcorsname-options)\r\n  - RequestPayment\r\n    - [.getBucketRequestPayment(bucketName[, options])](#getbucketrequestpaymentbucketname-options)\r\n    - [.putBucketRequestPayment(bucketName, payer[, options])](#putBucketRequestpaymentbucketname-payer-options)\r\n  - BucketEncryption\r\n    - [.putBucketEncryption(name[, rules])](#putbucketencryptionname-rules)\r\n    - [.getBucketEncryption(name)](#getbucketencryptionname)\r\n    - [.deleteBucketEncryption(name)](#deletebucketencryptionname)\r\n  - tagging\r\n    - [.putBucketTags(name, tag[, options])](#putBucketTagsname-tag-options)\r\n    - [.getBucketTags(name, [, options])](#getBucketTagsname-options)\r\n    - [.deleteBucketTags(name, [, options])](#deleteBucketTagsname-options)\r\n  - policy\r\n    - [.putBucketPolicy(name, policy[, options])](#putBucketPolicyname-policy-options)\r\n    - [.getBucketPolicy(name, [, options])](#getBucketPolicyname-options)\r\n    - [.deleteBucketPolicy(name, [, options])](#deleteBucketPolicyname-options)\r\n  - versioning\r\n    - [.getBucketVersioning(name, [, options])](#getBucketVersioningname-options)\r\n    - [.putBucketVersioning(name, status[, options])](#putBucketVersioningname-status-options)\r\n  - worm\r\n    - [.abortBucketWorm(name[, options])](#abortBucketWormname-options)\r\n    - [.completeBucketWorm(name, wormId[, options])](#completeBucketWormname-wormId-options)\r\n    - [.extendBucketWorm(name, wormId, days[, options])](#extendBucketWormname-wormId-days-options)\r\n    - [.getBucketWorm(name[, options])](#getBucketWormname-options)\r\n    - [.initiateBucketWorm(name, days[, options])](#initiateBucketWormname-days-options)\r\n- inventory\r\n\r\n  - [.getBucketInventory(name, inventoryId[, options])](#getBucketInventoryname-inventoryid-options)\r\n  - [.putBucketInventory(name, inventory[, options])](#putBucketInventoryname-inventory-options)\r\n  - [.deleteBucketInventory(name, inventoryId[, options])](#deleteBucketInventoryname-inventoryid-options)\r\n  - [.listBucketInventory(name, [, options])](#listBucketInventoryname-options)\r\n\r\n- [Object Operations](#object-operations)\r\n  - [.list(query[, options])](#listquery-options)\r\n  - [.listV2(query[, options])](#listV2query-options)\r\n  - [.getBucketVersions(query[, options])](#getBucketVersionsquery-options)\r\n  - [.put(name, file[, options])](#putname-file-options)\r\n  - [.putStream(name, stream[, options])](#putstreamname-stream-options)\r\n  - [.append(name, file[, options])](#appendname-file-options)\r\n  - [.getObjectUrl(name[, baseUrl])](#getobjecturlname-baseurl)\r\n  - [.generateObjectUrl(name[, baseUrl])](#generateobjecturlname-baseurl)\r\n  - [.head(name[, options])](#headname-options)\r\n  - [.getObjectMeta(name[, options])](#getobjectmetaname-options)\r\n  - [.get(name[, file, options])](#getname-file-options)\r\n  - [.getStream(name[, options])](#getstreamname-options)\r\n  - [.delete(name[, options])](#deletename-options)\r\n  - [.copy(name, sourceName[, sourceBucket, options])](#copyname-sourcename-sourcebucket-options)\r\n  - [.putMeta(name, meta[, options])](#putmetaname-meta-options)\r\n  - [.deleteMulti(names[, options])](#deletemultinames-options)\r\n  - [.signatureUrl(name[, options])](#signatureurlname-options)\r\n  - [.putACL(name, acl[, options])](#putaclname-acl-options)\r\n  - [.getACL(name[, options])](#getaclname-options)\r\n  - [.restore(name[, options])](#restorename-options)\r\n  - [.putSymlink(name, targetName[, options])](#putsymlinkname-targetname-options)\r\n  - [.getSymlink(name[, options])](#getsymlinkname-options)\r\n  - [.initMultipartUpload(name[, options])](#initmultipartuploadname-options)\r\n  - [.uploadPart(name, uploadId, partNo, file, start, end[, options])](#uploadpartname-uploadid-partno-file-start-end-options)\r\n  - [.uploadPartCopy(name, uploadId, partNo, range, sourceData[, options])](#uploadpartcopyname-uploadid-partno-range-sourcedata-options)\r\n  - [.completeMultipartUpload(name, uploadId, parts[, options])](#completemultipartuploadname-uploadid-parts-options)\r\n  - [.multipartUpload(name, file[, options])](#multipartuploadname-file-options)\r\n  - [.multipartUploadCopy(name, sourceData[, options])](#multipartuploadcopyname-sourcedata-options)\r\n  - [.listParts(name, uploadId[, query, options])](#listpartsname-uploadid-query-options)\r\n  - [.listUploads(query[, options])](#listuploadsquery-options)\r\n  - [.abortMultipartUpload(name, uploadId[, options])](#abortmultipartuploadname-uploadid-options)\r\n  - [.calculatePostSignature(policy)](#calculatePostSignaturepolicy)\r\n  - [.getObjectTagging(name, [, options])](#getObjectTaggingname-options)\r\n  - [.putObjectTagging(name, tag[, options])](#putObjectTaggingname-tag-options)\r\n  - [.deleteObjectTagging(name, [, options])](#deleteObjectTaggingname-options)\r\n- [RTMP Operations](#rtmp-operations)\r\n  - [.putChannel(id, conf[, options])](#putchannelid-conf-options)\r\n  - [.getChannel(id[, options])](#getchannelid-options)\r\n  - [.deleteChannel(id[, options])](#deletechannelid-options)\r\n  - [.putChannelStatus(id, status[, options])](#putchannelstatusid-status-options)\r\n  - [.getChannelStatus(id[, options])](#getchannelstatusid-options)\r\n  - [.listChannels(query[, options])](#listchannelsquery-options)\r\n  - [.getChannelHistory(id[, options])](#getchannelhistoryid-options)\r\n  - [.createVod(id, name, time[, options])](#createvodid-name-time-options)\r\n  - [.getRtmpUrl(channelId[, options])](#getrtmpurlchannelid-options)\r\n- [Create A Image Service Instance](#create-a-image-service-instance)\r\n  - [oss.ImageClient(options)](#ossimageclientoptions)\r\n- [Image Operations](#image-operations)\r\n  - [imgClient.get(name, file[, options])](#imgclientgetname-file-options)\r\n  - [imgClient.getStream(name[, options])](#imgclientgetstreamname-options)\r\n  - [imgClient.getExif(name[, options])](#imgclientgetexifname-options)\r\n  - [imgClient.getInfo(name[, options])](#imgclientgetinfoname-options)\r\n  - [imgClient.putStyle(name, style[, options])](#imgclientputstylename-style-options)\r\n  - [imgClient.getStyle(name[, options])](#imgclientgetstylename-options)\r\n  - [imgClient.listStyle([options])](#imgclientliststyleoptions)\r\n  - [imgClient.deleteStyle(name[, options])](#imgclientdeletestylename-options)\r\n  - [imgClient.signatureUrl(name)](#imgclientsignatureurlname)\r\n- [Known Errors](#known-errors)\r\n\r\n## Node Usage\r\n\r\n### Compatibility\r\n\r\n- Node: >= 8.0.0\r\n\r\n### Basic usage\r\n\r\n1.install SDK using npm\r\n\r\n```\r\nnpm install ali-oss --save\r\n```\r\n\r\n2.for example:\r\n\r\n```js\r\nconst OSS = require('ali-oss');\r\nconst client = new OSS({\r\n  region: '<oss region>',\r\n  accessKeyId: '<Your accessKeyId>',\r\n  accessKeySecret: '<Your accessKeySecret>',\r\n  bucket: '<Your bucket name>'\r\n});\r\n```\r\n\r\n## Browser Usage\r\n\r\nYou can use most of the functionalities of `ali-oss` in browser with\r\nsome exceptions:\r\n\r\n- put object with streaming: no chunked encoding, we use multipart\r\n  upload instead\r\n- get object to local file: we cannot manipulate file system in\r\n  browser, we provide signed object url for downloading needs\r\n- bucket operations(listBuckets, putBucketLogging, etc) will fail: OSS\r\n  server currently do not support CORS requests for bucket operations\r\n  (will probably be fixed later)\r\n\r\n### Compatibility\r\n\r\n- IE >= 10 & Edge\r\n- Major versions of Chrome/Firefox/Safari\r\n- Major versions of Android/iOS/WP\r\n  > Note: Because some browsers do not support promises, you need to introduce promise compatible libraries.<br>\r\n  > For example: IE10 and IE11 need to introduce a promise-polyfill.\r\n\r\n### Setup\r\n\r\n#### Bucket setup\r\n\r\nAs browser-side javascript involves CORS operations. You need to setup\r\nyour bucket CORS rules to allow CORS operations:\r\n\r\n- set allowed origins to '\\*'\r\n- allowed methods to 'PUT, GET, POST, DELETE, HEAD'\r\n- set allowed headers to '\\*'\r\n- expose 'ETag' in expose headers\r\n\r\n#### STS setup\r\n\r\nAs we don't want to expose the accessKeyId/accessKeySecret in the\r\nbrowser, a [common practice][oss-sts] is to use STS to grant temporary\r\naccess.\r\n\r\n### Basic usage\r\n\r\nInclude the sdk lib in the `<script>` tag and you have `OSS` available\r\nfor creating client.\r\n\r\n```html\r\n// x.x.x The specific version number represented // we recommend introducing offline resources, because the usability of\r\nonline resources depends on the stability of the cdn server.\r\n<!-- Introducing online resources -->\r\n<script src=\"http://gosspublic.alicdn.com/aliyun-oss-sdk-x.x.x.min.js\"></script>\r\n<!-- Introducing offline resources -->\r\n<script src=\"./aliyun-oss-sdk-x.x.x.min.js\"></script>\r\n\r\n<script type=\"text/javascript\">\r\n  const client = new OSS({\r\n    region: 'oss-cn-hangzhou',\r\n    accessKeyId: '<access-key-id>',\r\n    accessKeySecret: '<access-key-secret>',\r\n    bucket: '<bucket-name>',\r\n    stsToken: '<security-token>'\r\n  });\r\n\r\n  client\r\n    .list()\r\n    .then(result => {\r\n      console.log('objects: %j', result.objects);\r\n      return client.put('my-obj', new File(['hello world'], 'a'));\r\n    })\r\n    .then(result => {\r\n      console.log('put result: %j', result);\r\n      return client.get('my-obj');\r\n    })\r\n    .then(result => {\r\n      console.log('get result: %j', result.content.toString());\r\n    });\r\n</script>\r\n```\r\n\r\nThe full sample can be found [here][browser-sample].\r\n\r\n### How to build\r\n\r\n```bash\r\nnpm run build-dist\r\n```\r\n\r\nAnd see the build artifacts under `dist/`.\r\n\r\n## Data Regions\r\n\r\n[OSS current data regions](https://help.aliyun.com/document_detail/oss/user_guide/endpoint_region.html).\r\n\r\n| region             | country   | city           | endpoint                        | internal endpoint                        |\r\n| ------------------ | --------- | -------------- | ------------------------------- | ---------------------------------------- |\r\n| oss-cn-hangzhou    | China     | HangZhou       | oss-cn-hangzhou.aliyuncs.com    | oss-cn-hangzhou-internal.aliyuncs.com    |\r\n| oss-cn-shanghai    | China     | ShangHai       | oss-cn-shanghai.aliyuncs.com    | oss-cn-shanghai-internal.aliyuncs.com    |\r\n| oss-cn-qingdao     | China     | QingDao        | oss-cn-qingdao.aliyuncs.com     | oss-cn-qingdao-internal.aliyuncs.com     |\r\n| oss-cn-beijing     | China     | BeiJing        | oss-cn-beijing.aliyuncs.com     | oss-cn-beijing-internal.aliyuncs.com     |\r\n| oss-cn-shenzhen    | China     | ShenZhen       | oss-cn-shenzhen.aliyuncs.com    | oss-cn-shenzhen-internal.aliyuncs.com    |\r\n| oss-cn-hongkong    | China     | HongKong       | oss-cn-hongkong.aliyuncs.com    | oss-cn-hongkong-internal.aliyuncs.com    |\r\n| oss-us-west-1      | US        | Silicon Valley | oss-us-west-1.aliyuncs.com      | oss-us-west-1-internal.aliyuncs.com      |\r\n| oss-ap-southeast-1 | Singapore | Singapore      | oss-ap-southeast-1.aliyuncs.com | oss-ap-southeast-1-internal.aliyuncs.com |\r\n\r\n## Create Account\r\n\r\nGo to [OSS website](http://www.aliyun.com/product/oss/?lang=en), create a new account for new user.\r\n\r\nAfter account created, you can create the OSS instance and get the `accessKeyId` and `accessKeySecret`.\r\n\r\n## Create A Bucket Instance\r\n\r\nEach OSS instance required `accessKeyId`, `accessKeySecret` and `bucket`.\r\n\r\n## new OSS(options)\r\n\r\nCreate a Bucket store instance.\r\n\r\noptions:\r\n\r\n- accessKeyId {String} access key you create on aliyun console website\r\n- accessKeySecret {String} access secret you create\r\n- [stsToken] {String} used by temporary authorization, detail [see](https://www.alibabacloud.com/help/doc-detail/32077.htm)\r\n- [refreshSTSToken] {Function} used by auto set `stsToken`、`accessKeyId`、`accessKeySecret` when sts info expires. return value must be object contains `stsToken`、`accessKeyId`、`accessKeySecret`\r\n- [bucket] {String} the default bucket you want to access\r\n  If you don't have any bucket, please use `putBucket()` create one first.\r\n- [endpoint] {String} oss region domain. It takes priority over `region`. Set as extranet domain name, intranet domain name, accelerated domain name, etc. according to different needs. please see [endpoints](https://www.alibabacloud.com/help/doc-detail/31837.htm)\r\n- [region] {String} the bucket data region location, please see [Data Regions](#data-regions),\r\n  default is `oss-cn-hangzhou`.\r\n- [internal] {Boolean} access OSS with aliyun internal network or not, default is `false`.\r\n  If your servers are running on aliyun too, you can set `true` to save lot of money.\r\n- [secure] {Boolean} instruct OSS client to use HTTPS (secure: true) or HTTP (secure: false) protocol.\r\n- [timeout] {String|Number} instance level timeout for all operations, default is `60s`.\r\n- [cname] {Boolean}, default false, access oss with custom domain name. if true, you can fill `endpoint` field with your custom domain name,\r\n- [isRequestPay] {Boolean}, default false, whether request payer function of the bucket is open, if true, will send headers `'x-oss-request-payer': 'requester'` to oss server.\r\n  the details you can see [requestPay](https://help.aliyun.com/document_detail/91337.htm)\r\n- [useFetch] {Boolean}, default false, it just work in Browser, if true,it means upload object with\r\n  `fetch` mode ,else `XMLHttpRequest`\r\n- [enableProxy] {Boolean}, Enable proxy request, default is false.\r\n- [proxy] {String | Object}, proxy agent uri or options, default is null.\r\n- [retryMax] {Number}, used by auto retry send request count when request error is net error or timeout.**_NOTE:_** Not support `put` with stream, `putStream`, `append` with stream because the stream can only be consumed once\r\n\r\nexample:\r\n\r\n1. basic usage\r\n\r\n```js\r\nconst OSS = require('ali-oss');\r\nconst store = new OSS({\r\n  accessKeyId: 'your access key',\r\n  accessKeySecret: 'your access secret',\r\n  bucket: 'your bucket name',\r\n  region: 'oss-cn-hangzhou'\r\n});\r\n```\r\n\r\n2. use accelerate endpoint\r\n\r\n- Global accelerate endpoint: oss-accelerate.aliyuncs.com\r\n- Accelerate endpoint of regions outside mainland China: oss-accelerate-overseas.aliyuncs.com\r\n\r\n```js\r\nconst OSS = require('ali-oss');\r\nconst store = new OSS({\r\n  accessKeyId: 'your access key',\r\n  accessKeySecret: 'your access secret',\r\n  bucket: 'your bucket name',\r\n  endpoint: 'oss-accelerate.aliyuncs.com'\r\n});\r\n```\r\n\r\n3. use custom domain\r\n\r\n```js\r\nconst OSS = require('ali-oss');\r\nconst store = new OSS({\r\n  accessKeyId: 'your access key',\r\n  accessKeySecret: 'your access secret',\r\n  cname: true,\r\n  endpoint: 'your custome domain'\r\n});\r\n```\r\n\r\n4. use STS and refreshSTSToken\r\n\r\n```js\r\nconst OSS = require('ali-oss');\r\nconst store = new OSS({\r\n  accessKeyId: 'your STS key',\r\n  accessKeySecret: 'your STS secret',\r\n  stsToken: 'your STS token',\r\n  refreshSTSToken: async () => {\r\n    return {\r\n      accessKeyId: 'your refreshed STS key',\r\n      accessKeySecret: 'your refreshed STS secret',\r\n      stsToken: 'your refreshed STS stoken'\r\n    };\r\n  }\r\n});\r\n```\r\n\r\n5. retry request with stream\r\n\r\n```js\r\nfor (let i = 0; i <= store.options.retryMax; i++) {\r\n  try {\r\n    const result = await store.putStream('<example-object>', fs.createReadStream('<example-path>'));\r\n    console.log(result);\r\n    break; // break if success\r\n  } catch (e) {\r\n    console.log(e);\r\n  }\r\n}\r\n```\r\n\r\n## Bucket Operations\r\n\r\n### .listBuckets(query[, options])\r\n\r\nList buckets in this account.\r\n\r\nparameters:\r\n\r\n- [query] {Object} query parameters, default is `null`\r\n  - [prefix] {String} search buckets using `prefix` key\r\n  - [marker] {String} search start from `marker`, including `marker` key\r\n  - [max-keys] {String|Number} max buckets, default is `100`, limit to `1000`\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return buckets list on `buckets` properties.\r\n\r\n- buckets {Array<BucketMeta>} bucket meta info list\r\n  Each `BucketMeta` will contains blow properties:\r\n  - name {String} bucket name\r\n  - region {String} bucket store data region, e.g.: `oss-cn-hangzhou-a`\r\n  - creationDate {String} bucket create GMT date, e.g.: `2015-02-19T08:39:44.000Z`\r\n  - storageClass {String} e.g.: `Standard`, `IA`, `Archive`\r\n- owner {Object} object owner, including `id` and `displayName`\r\n- isTruncated {Boolean} truncate or not\r\n- nextMarker {String} next marker string\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- List top 10 buckets\r\n\r\n```js\r\nstore\r\n  .listBuckets({\r\n    'max-keys': 10\r\n  })\r\n  .then(result => {\r\n    console.log(result);\r\n  });\r\n```\r\n\r\n### .putBucket(name[, options])\r\n\r\nCreate a new bucket.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n  If bucket exists and not belong to current account, will throw BucketAlreadyExistsError.\r\n  If bucket not exists, will create a new bucket and set it's ACL.\r\n- [options] {Object} optional parameters\r\n  - [acl] {String} include `private`,`public-read`,`public-read-write`\r\n  - [storageClass] {String} the storage type include (Standard,IA,Archive)\r\n  - [dataRedundancyType] {String} default `LRS`, include `LRS`,`ZRS`\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return the bucket name on `bucket` properties.\r\n\r\n- bucket {String} bucket name\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Create a bucket name `helloworld` location on HongKong\r\n\r\n```js\r\nstore.putBucket('helloworld').then(result => {\r\n  // use it by default\r\n  store.useBucket('helloworld');\r\n});\r\n```\r\n\r\n- Create a bucket name `helloworld` location on HongKong StorageClass `Archive`\r\n\r\n```js\r\nawait store.putBucket('helloworld', { StorageClass: 'Archive' });\r\n// use it by default\r\nstore.useBucket('helloworld');\r\n```\r\n\r\n### .deleteBucket(name[, options])\r\n\r\nDelete an empty bucket.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n  If bucket is not empty, will throw BucketNotEmptyError.\r\n  If bucket is not exists, will throw NoSuchBucketError.\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Delete the exists 'helloworld' bucket on 'oss-cn-hongkong'\r\n\r\n```js\r\nstore.deleteBucket('helloworld').then(result => {});\r\n```\r\n\r\n### .useBucket(name)\r\n\r\nUse the bucket.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n\r\nexample:\r\n\r\n- Use `helloworld` as the default bucket\r\n\r\n```js\r\nstore.useBucket('helloworld');\r\n```\r\n\r\n### .getBucketInfo(name)\r\n\r\nGet bucket information,include CreationDate、ExtranetEndpoint、IntranetEndpoint、Location、Name、StorageClass、\r\nOwner、AccessControlList、Versioning\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n\r\nexample:\r\n\r\n- Use `helloworld` as the default bucket\r\n\r\n```js\r\nstore.getBucketInfo('helloworld').then(res => {\r\n  console.log(res.bucket);\r\n});\r\n```\r\n\r\n### .getBucketLocation(name)\r\n\r\nGet bucket location\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n\r\nexample:\r\n\r\n- Use `helloworld` as the default bucket\r\n\r\n```js\r\nstore.getBucketLocation('helloworld').then(res => {\r\n  console.log(res.location);\r\n});\r\n```\r\n\r\n---\r\n\r\n### .putBucketACL(name, acl[, options])\r\n\r\nUpdate the bucket ACL.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- acl {String} access control list, current available: `public-read-write`, `public-read` and `private`\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Set bucket `helloworld` to `public-read-write`\r\n\r\n```js\r\nstore.putBucketACL('helloworld', 'public-read-write').then(result => {});\r\n```\r\n\r\n### .getBucketACL(name[, options])\r\n\r\nGet the bucket ACL.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- acl {String} acl settiongs string\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Get bucket `helloworld`\r\n\r\n```js\r\nstore.getBucketACL('helloworld').then(result => {\r\n  console.log(result.acl);\r\n});\r\n```\r\n\r\n---\r\n\r\n### .putBucketLogging(name, prefix[, options])\r\n\r\nUpdate the bucket logging settings.\r\nLog file will create every one hour and name format: `<prefix><bucket>-YYYY-mm-DD-HH-MM-SS-UniqueString`.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [prefix] {String} prefix path name to store the log files\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Enable bucket `helloworld` logging and save with prefix `logs/`\r\n\r\n```js\r\nstore.putBucketLogging('helloworld', 'logs/').then(result => {});\r\n```\r\n\r\n### .getBucketLogging(name[, options])\r\n\r\nGet the bucket logging settings.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- enable {Boolean} enable logging or not\r\n- prefix {String} prefix path name to store the log files, maybe `null`\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Get bucket `helloworld` logging settings\r\n\r\n```js\r\nstore.getBucketLogging('helloworld').then(result => {\r\n  console.log(result.enable, result.prefix);\r\n});\r\n```\r\n\r\n### .deleteBucketLogging(name[, options])\r\n\r\nDelete the bucket logging settings.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n---\r\n\r\n### .putBucketWebsite(name, config[, options])\r\n\r\nSet the bucket as a static website.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- config {Object} website config, contains blow properties:\r\n  - index {String} default page, e.g.: `index.html`\r\n  - [error] {String} error page, e.g.: 'error.html'\r\n  - [supportSubDir] {String} default vaule false\r\n  - [type] {String} default value 0\r\n  - [routingRules] {Array} RoutingRules\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n```js\r\nstore\r\n  .putBucketWebsite('hello', {\r\n    index: 'index.html'\r\n  })\r\n  .then(result => {});\r\n```\r\n\r\n### .getBucketWebsite(name[, options])\r\n\r\nGet the bucket website config.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- index {String} index page\r\n- error {String} error page, maybe `null`\r\n- supportSubDir {String}\r\n- type {String}\r\n- routingRules {Array}\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n### .deleteBucketWebsite(name[, options])\r\n\r\nDelete the bucket website config.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n---\r\n\r\n### .putBucketReferer(name, allowEmpty, referers[, options])\r\n\r\nSet the bucket request `Referer` white list.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- allowEmpty {Boolean} allow empty request referer or not\r\n- referers {Array<String>} `Referer` white list, e.g.:\r\n  ```js\r\n  ['https://npm.taobao.org', 'http://cnpmjs.org'];\r\n  ```\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n```js\r\nstore.putBucketReferer('hello', false, ['https://npm.taobao.org', 'http://cnpmjs.org']).then(result => {});\r\n```\r\n\r\n### .getBucketReferer(name[, options])\r\n\r\nGet the bucket request `Referer` white list.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- allowEmpty {Boolean} allow empty request referer or not\r\n- referers {Array<String>} `Referer` white list\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n### .deleteBucketReferer(name[, options])\r\n\r\nDelete the bucket request `Referer` white list.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n---\r\n\r\n### .putBucketLifecycle(name, rules[, options])\r\n\r\nSet the bucket object lifecycle.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- rules {Array<Rule>} rule config list, each `Rule` will contains blow properties:\r\n  - [id] {String} rule id, if not set, OSS will auto create it with random string.\r\n  - prefix {String} store prefix\r\n  - status {String} rule status, allow values: `Enabled` or `Disabled`\r\n  - [expiration] {Object} specifies the expiration attribute of the lifecycle rules for the object.\r\n    - [days] {Number|String} expire after the `days`\r\n    - [createdBeforeDate] {String} expire date, e.g.: `2022-10-11T00:00:00.000Z`\r\n    - [expiredObjectDeleteMarker] {String} value `true`\r\n      `createdBeforeDate` and `days` and `expiredObjectDeleteMarker` must have one.\r\n  - [abortMultipartUpload] {Object} Specifies the expiration attribute of the multipart upload tasks that are not complete.\r\n    - [days] {Number|String} expire after the `days`\r\n    - [createdBeforeDate] {String} expire date, e.g.: `2022-10-11T00:00:00.000Z`\r\n      `createdBeforeDate` and `days` must have one.\r\n  - [transition] {Object} Specifies the time when an object is converted to the IA or archive storage class during a valid life cycle.\r\n    - storageClass {String} Specifies the storage class that objects that conform to the rule are converted into. allow values: `IA` or `Archive`\r\n    - [days] {Number|String} expire after the `days`\r\n    - [createdBeforeDate] {String} expire date, e.g.: `2022-10-11T00:00:00.000Z`\r\n      `createdBeforeDate` and `days` must have one.\r\n  - [noncurrentVersionTransition] {Object} Specifies the time when an object is converted to the IA or archive storage class during a valid life cycle.\r\n    - storageClass {String} Specifies the storage class that history objects that conform to the rule are converted into. allow values: `IA` or `Archive`\r\n    - noncurrentDays {String} expire after the `noncurrentDays`\r\n      `expiration`、 `abortMultipartUpload`、 `transition`、 `noncurrentVersionTransition` must have one.\r\n  - [noncurrentVersionExpiration] {Object} specifies the expiration attribute of the lifecycle rules for the history object.\r\n    - noncurrentDays {String} expire after the `noncurrentDays`\r\n  - [tag] {Object} Specifies the object tag applicable to a rule. Multiple tags are supported.\r\n    - key {String} Indicates the tag key.\r\n    - value {String} Indicates the tag value.\r\n      `tag` cannot be used with `abortMultipartUpload`\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n```js\r\nstore\r\n  .putBucketLifecycle('hello', [\r\n    {\r\n      id: 'delete after one day',\r\n      prefix: 'logs/',\r\n      status: 'Enabled',\r\n      days: 1\r\n    },\r\n    {\r\n      prefix: 'logs2/',\r\n      status: 'Disabled',\r\n      date: '2022-10-11T00:00:00.000Z'\r\n    }\r\n  ])\r\n  .then(result => {});\r\n```\r\n\r\nexample: for history with noncurrentVersionExpiration\r\n\r\n```js\r\nconst result = await store.putBucketLifecycle(bucket, [\r\n  {\r\n    id: 'expiration1',\r\n    prefix: 'logs/',\r\n    status: 'Enabled',\r\n    expiration: {\r\n      days: '1'\r\n    },\r\n    noncurrentVersionExpiration: {\r\n      noncurrentDays: '1'\r\n    }\r\n  }\r\n]);\r\nconsole.log(result);\r\n```\r\n\r\nexample: for history with expiredObjectDeleteMarker\r\n\r\n```js\r\nconst result = await store.putBucketLifecycle(bucket, [\r\n  {\r\n    id: 'expiration1',\r\n    prefix: 'logs/',\r\n    status: 'Enabled',\r\n    expiration: {\r\n      expiredObjectDeleteMarker: 'true'\r\n    },\r\n    noncurrentVersionExpiration: {\r\n      noncurrentDays: '1'\r\n    }\r\n  }\r\n]);\r\nconsole.log(result);\r\n```\r\n\r\nexample: for history with noncurrentVersionTransition\r\n\r\n```js\r\nconst result = await store.putBucketLifecycle(bucket, [\r\n  {\r\n    id: 'expiration1',\r\n    prefix: 'logs/',\r\n    status: 'Enabled',\r\n    noncurrentVersionTransition: {\r\n      noncurrentDays: '10',\r\n      storageClass: 'IA'\r\n    }\r\n  }\r\n]);\r\nconsole.log(result);\r\n```\r\n\r\n### .getBucketLifecycle(name[, options])\r\n\r\nGet the bucket object lifecycle.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- rules {Array<Rule>} the lifecycle rule list\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n### .deleteBucketLifecycle(name[, options])\r\n\r\nDelete the bucket object lifecycle.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n---\r\n\r\n### .putBucketCORS(name, rules[, options])\r\n\r\nSet CORS rules of the bucket object\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- rules {Array<Rule>} rule config list, each `Rule` will contains below properties:\r\n  - allowedOrigin {String/Array} configure for Access-Control-Allow-Origin header\r\n  - allowedMethod {String/Array} configure for Access-Control-Allow-Methods header\r\n  - [allowedHeader] {String/Array} configure for Access-Control-Allow-Headers header\r\n  - [exposeHeader] {String/Array} configure for Access-Control-Expose-Headers header\r\n  - [maxAgeSeconds] {String} configure for Access-Control-Max-Age header\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n```js\r\nstore\r\n  .putBucketCORS('hello', [\r\n    {\r\n      allowedOrigin: '*',\r\n      allowedMethod: ['GET', 'HEAD']\r\n    }\r\n  ])\r\n  .then(result => {});\r\n```\r\n\r\n### .getBucketCORS(name[, options])\r\n\r\nGet CORS rules of the bucket object.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- rules {Array<Rule>} the CORS rule list\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n### .deleteBucketCORS(name[, options])\r\n\r\nDelete CORS rules of the bucket object.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n\r\nSuccess will return:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\n### .getBucketRequestPayment(bucketName[, options])\r\n\r\nget RequestPayment value of the bucket object.\r\n\r\nparameters:\r\n\r\n- bucketName {String} bucket name\r\n- [options] {Object} optional parameters\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- payer {String} payer, BucketOwner or Requester\r\n- res {Object} response info, including\r\n  - data {Buffer} xml\r\n\r\n---\r\n\r\n### .putBucketRequestPayment(bucketName, payer[, options])\r\n\r\nput RequestPayment value of the bucket object.\r\n\r\nparameters:\r\n\r\n- bucketName {String}\r\n- payer {String} payer\r\n- [options] {Object} optional parameters\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .putBucketEncryption(name, rules)\r\n\r\nput BucketEncryption value of the bucket object.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n- [rules] {Object} parameters\r\n  - SSEAlgorithm {String} encryption type, expect AES256 or KMS\r\n  - {KMSMasterKeyID} {String} needed when encryption type is KMS\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .getBucketEncryption(name)\r\n\r\nget BucketEncryption rule value of the bucket object.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n- encryption {Object} rules\r\n  - SSEAlgorithm {String} encryption type, AES256 or KMS\r\n  - {KMSMasterKeyID} {String} will be return when encryption type is KMS\r\n\r\n---\r\n\r\n### .deleteBucketEncryption(name)\r\n\r\ndelete BucketEncryption rule value of the bucket object.\r\n\r\nparameters:\r\n\r\n- name {String} bucket name\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .putBucketTags(name, tag[, options])\r\n\r\nAdds tags for a bucket or modify the tags for a bucket.\r\n\r\nparameters:\r\n\r\n- name {String} the object name\r\n- tag {Object} tag, eg. `{var1: value1,var2:value2}`\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .getBucketTags(name[, options])\r\n\r\nObtains the tags for a bucket.\r\n\r\nparameters:\r\n\r\n- name {String} the object name\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- tag {Object} the tag of object\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .deleteBucketTags(name[, options])\r\n\r\nDeletes the tags added for a bucket.\r\n\r\nparameters:\r\n\r\n- name {String} the object name\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .putBucketPolicy(name, policy[, options])\r\n\r\nAdds or modify policy for a bucket.\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- policy {Object} bucket policy\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\nexample:\r\n\r\n```js\r\nconst policy = {\r\n  Version: '1',\r\n  Statement: [\r\n    {\r\n      Action: ['oss:PutObject', 'oss:GetObject'],\r\n      Effect: 'Deny',\r\n      Principal: ['1234567890'],\r\n      Resource: ['acs:oss:*:1234567890:*/*']\r\n    }\r\n  ]\r\n};\r\nconst result = await store.putBucketPolicy(bucket, policy);\r\nconsole.log(result);\r\n```\r\n\r\n---\r\n\r\n### .getBucketPolicy(name[, options])\r\n\r\nObtains the policy for a bucket.\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- policy {Object} the policy of bucket, if not exist, the value is null\r\n- res {Object} response info\r\n- status {Number} response status\r\n\r\n---\r\n\r\n### .deleteBucketPolicy(name[, options])\r\n\r\nDeletes the policy added for a bucket.\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .getBucketVersioning(name[, options])\r\n\r\nObtains the version status of an object\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- versionStatus {String | undefined} version status, `Suspended` or `Enabled`. default value: `undefined`\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .putBucketVersioning(name, status[, options])\r\n\r\nset the version status of an object\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- status {String} version status, allow values: `Enabled` or `Suspended`\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .abortBucketWorm(name[, options])\r\n\r\nused to delete an unlocked retention policy.\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .completeBucketWorm(name, wormId[, options])\r\n\r\nused to lock a retention policy.\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- wormId {String} worm id\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .extendBucketWorm(name, wormId, days[, options])\r\n\r\nused to extend the retention period of objects in a bucket whose retention policy is locked.\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- wormId {String} worm id\r\n- days {String | Number} retention days\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .getBucketWorm(name[, options])\r\n\r\nused to query the retention policy information of the specified bucket.\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- wormId {String} worm id\r\n- state {String} `Locked` or `InProgress`\r\n- days {String} retention days\r\n- creationDate {String}\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .initiateBucketWorm(name, days[, options])\r\n\r\ncreate a retention policy.\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- days {String | Number}} set retention days\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- wormId {String} worm id\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n---\r\n\r\n### .getBucketInventory(name, inventoryId[, options])\r\n\r\nget bucket inventory by inventory-id\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- inventoryId {String} inventory-id\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- inventory {Inventory}\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n```js\r\nasync function getBucketInventoryById() {\r\n  try {\r\n    const result = await client.getBucketInventory('bucket', 'inventoryid');\r\n    console.log(result.inventory);\r\n  } catch (err) {\r\n    console.log(err);\r\n  }\r\n}\r\n\r\ngetBucketInventoryById();\r\n```\r\n\r\n### putBucketInventory(name, inventory[, options])\r\n\r\nset bucket inventory\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- inventory {Inventory} inventory config\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n```ts\r\ntype Field = 'Size' | 'LastModifiedDate' | 'ETag' | 'StorageClass' | 'IsMultipartUploaded' | 'EncryptionStatus';\r\ninterface Inventory {\r\n  id: string;\r\n  isEnabled: true | false;\r\n  prefix?: string;\r\n  OSSBucketDestination: {\r\n    format: 'CSV';\r\n    accountId: string;\r\n    rolename: string;\r\n    bucket: string;\r\n    prefix?: string;\r\n    encryption?:\r\n      | { 'SSE-OSS': '' }\r\n      | {\r\n          'SSE-KMS': {\r\n            keyId: string;\r\n          };\r\n        };\r\n  };\r\n  frequency: 'Daily' | 'Weekly';\r\n  includedObjectVersions: 'Current' | 'All';\r\n  optionalFields?: {\r\n    field?: Field[];\r\n  };\r\n}\r\n```\r\n\r\n```js\r\nconst inventory = {\r\n  id: 'default',\r\n  isEnabled: false, // `true` | `false`\r\n  prefix: 'ttt', // filter prefix\r\n  OSSBucketDestination: {\r\n    format: 'CSV',\r\n    accountId: '1817184078010220',\r\n    rolename: 'AliyunOSSRole',\r\n    bucket: 'your bucket',\r\n    prefix: 'test'\r\n    //encryption: {'SSE-OSS': ''},\r\n    /*\r\n      encryption: {\r\n      'SSE-KMS': {\r\n        keyId: 'test-kms-id';\r\n      };, \r\n    */\r\n  },\r\n  frequency: 'Daily', // `WEEKLY` | `Daily`\r\n  includedObjectVersions: 'All', // `All` | `Current`\r\n  optionalFields: {\r\n    field: ['Size', 'LastModifiedDate', 'ETag', 'StorageClass', 'IsMultipartUploaded', 'EncryptionStatus']\r\n  }\r\n};\r\n\r\nasync function putInventory() {\r\n  const bucket = 'Your Bucket Name';\r\n  try {\r\n    await client.putBucketInventory(bucket, inventory);\r\n  } catch (err) {\r\n    console.log(err);\r\n  }\r\n}\r\n\r\nputInventory();\r\n```\r\n\r\n### deleteBucketInventory(name, inventoryId[, options])\r\n\r\ndelete bucket inventory by inventory-id\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- inventoryId {String} inventory-id\r\n- [options] {Object} optional args\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\n### listBucketInventory(name[, options])\r\n\r\nlist bucket inventory\r\n\r\nparameters:\r\n\r\n- name {String} the bucket name\r\n- [options] {Object} optional args\r\n  - continuationToken used by search next page\r\n\r\nSuccess will return:\r\n\r\n- status {Number} response status\r\n- res {Object} response info\r\n\r\nexample:\r\n\r\n```js\r\nasync function listBucketInventory() {\r\n  const bucket = 'Your Bucket Name';\r\n  let nextContinuationToken;\r\n  // list all inventory of the bucket\r\n  do {\r\n    const result = await client.listBucketInventory(bucket, nextContinuationToken);\r\n    console.log(result.inventoryList);\r\n    nextContinuationToken = result.nextContinuationToken;\r\n  } while (nextContinuationToken);\r\n}\r\n\r\nlistBucketInventory();\r\n```\r\n\r\n## Object Operations\r\n\r\nAll operations function return Promise, except `signatureUrl`.\r\n\r\n### .put(name, file[, options])\r\n\r\nAdd an object to the bucket.\r\n\r\nparameters:\r\n\r\n- name {String} object name store on OSS\r\n- file {String|Buffer|ReadStream|File(only support Browser)|Blob(only support Browser)} object local path, content buffer or ReadStream content instance use in Node, Blob and html5 File\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n  - [mime] {String} custom mime, will send with `Content-Type` entity header\r\n  - [meta] {Object} user meta, will send with `x-oss-meta-` prefix string\r\n    e.g.: `{ uid: 123, pid: 110 }`\r\n  - [callback] {Object} The callback parameter is composed of a JSON string encoded in Base64,detail [see](https://www.alibabacloud.com/help/doc-detail/31989.htm)<br>\r\n    - url {String} After a file is uploaded successfully, the OSS sends a callback request to this URL.\r\n    - [host] {String} The host header value for initiating callback requests.\r\n    - body {String} The value of the request body when a callback is initiated, for example, key=$(key)&etag=$(etag)&my_var=$(x:my_var).\r\n    - [contentType] {String} The Content-Type of the callback requests initiatiated, It supports application/x-www-form-urlencoded and application/json, and the former is the default value.\r\n    - [customValue] {Object} Custom parameters are a map of key-values<br>\r\n      e.g.:\r\n      ```js\r\n      var customValue = { var1: 'value1', var2: 'value2' };\r\n      ```\r\n  - [headers] {Object} extra headers\r\n    - 'Cache-Control' cache control for download, e.g.: `Cache-Control: public, no-cache`\r\n    - 'Content-Disposition' object name for download, e.g.: `Content-Disposition: somename`\r\n    - 'Content-Encoding' object content encoding for download, e.g.: `Content-Encoding: gzip`\r\n    - 'Expires' expires time for download, an absolute date and time. e.g.: `Tue, 08 Dec 2020 13:49:43 GMT`\r\n    - See more: [PutObject](https://help.aliyun.com/document_detail/31978.html#title-yxe-96d-x61)\r\n  - [disabledMD5] {Boolean} default true, it just work in Browser. if false,it means that MD5 is automatically calculated for uploaded files. **_NOTE:_** Synchronous computing tasks will block the main process\r\n\r\nSuccess will return the object information.\r\n\r\nobject:\r\n\r\n- name {String} object name\r\n- data {Object} callback server response data, sdk use JSON.parse() return\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Add an object through local file path\r\n\r\n```js\r\nconst filepath = '/home/ossdemo/demo.txt';\r\nstore.put('ossdemo/demo.txt', filepath).then((result) => {\r\n  console.log(result);\r\n});\r\n\r\n{\r\n  name: 'ossdemo/demo.txt',\r\n  res: {\r\n    status: 200,\r\n    headers: {\r\n      date: 'Tue, 17 Feb 2015 13:28:17 GMT',\r\n      'content-length': '0',\r\n      connection: 'close',\r\n      etag: '\"BF7A03DA01440845BC5D487B369BC168\"',\r\n      server: 'AliyunOSS',\r\n      'x-oss-request-id': '54E341F1707AA0275E829244'\r\n    },\r\n    size: 0,\r\n    rt: 92\r\n  }\r\n}\r\n```\r\n\r\n- Add an object through content buffer\r\n\r\n```js\r\nstore.put('ossdemo/buffer', Buffer.from('foo content')).then((result) => {\r\n  console.log(result);\r\n});\r\n\r\n{\r\n  name: 'ossdemo/buffer',\r\n  url: 'http://demo.oss-cn-hangzhou.aliyuncs.com/ossdemo/buffer',\r\n  res: {\r\n    status: 200,\r\n    headers: {\r\n      date: 'Tue, 17 Feb 2015 13:28:17 GMT',\r\n      'content-length': '0',\r\n      connection: 'close',\r\n      etag: '\"xxx\"',\r\n      server: 'AliyunOSS',\r\n      'x-oss-request-id': '54E341F1707AA0275E829243'\r\n    },\r\n    size: 0,\r\n    rt: 92\r\n  }\r\n}\r\n```\r\n\r\n- Add an object through readstream\r\n\r\n```js\r\nconst filepath = '/home/ossdemo/demo.txt';\r\nstore.put('ossdemo/readstream.txt', fs.createReadStream(filepath)).then((result) => {\r\n  console.log(result);\r\n});\r\n\r\n{\r\n  name: 'ossdemo/readstream.txt',\r\n  url: 'http://demo.oss-cn-hangzhou.aliyuncs.com/ossdemo/readstream.txt',\r\n  res: {\r\n    status: 200,\r\n    headers: {\r\n      date: 'Tue, 17 Feb 2015 13:28:17 GMT',\r\n      'content-length': '0',\r\n      connection: 'close',\r\n      etag: '\"BF7A03DA01440845BC5D487B369BC168\"',\r\n      server: 'AliyunOSS',\r\n      'x-oss-request-id': '54E341F1707AA0275E829242'\r\n    },\r\n    size: 0,\r\n    rt: 92\r\n  }\r\n}\r\n```\r\n\r\n### .putStream(name, stream[, options])\r\n\r\nAdd a stream object to the bucket.\r\n\r\nparameters:\r\n\r\n- name {String} object name store on OSS\r\n- stream {ReadStream} object ReadStream content instance\r\n- [options] {Object} optional parameters\r\n  - [contentLength] {Number} the stream length, `chunked encoding` will be used if absent\r\n  - [timeout] {Number} the operation timeout\r\n  - [mime] {String} custom mime, will send with `Content-Type` entity header\r\n  - [meta] {Object} user meta, will send with `x-oss-meta-` prefix string\r\n    e.g.: `{ uid: 123, pid: 110 }`\r\n  - [callback] {Object} The callback parameter is composed of a JSON string encoded in Base64,detail [see](https://www.alibabacloud.com/help/doc-detail/31989.htm)<br>\r\n    - url {String} After a file is uploaded successfully, the OSS sends a callback request to this URL.\r\n    - [host] {String} The host header value for initiating callback requests.\r\n    - body {String} The value of the request body when a callback is initiated, for example, key=$(key)&etag=$(etag)&my_var=$(x:my_var).\r\n    - [contentType] {String} The Content-Type of the callback requests initiatiated, It supports application/x-www-form-urlencoded and application/json, and the former is the default value.\r\n    - [customValue] {Object} Custom parameters are a map of key-values<br>\r\n      e.g.:\r\n      ```js\r\n      var customValue = { var1: 'value1', var2: 'value2' };\r\n      ```\r\n  - [headers] {Object} extra headers, detail see [RFC 2616](http://www.w3.org/Protocols/rfc2616/rfc2616.html)\r\n    - 'Cache-Control' cache control for download, e.g.: `Cache-Control: public, no-cache`\r\n    - 'Content-Disposition' object name for download, e.g.: `Content-Disposition: somename`\r\n    - 'Content-Encoding' object content encoding for download, e.g.: `Content-Encoding: gzip`\r\n    - 'Expires' expires time for download, an absolute date and time. e.g.: `Tue, 08 Dec 2020 13:49:43 GMT`\r\n\r\nSuccess will return the object information.\r\n\r\nobject:\r\n\r\n- name {String} object name\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Add an object through readstream\r\n\r\n```js\r\nconst filepath = '/home/ossdemo/demo.txt';\r\nstore.putStream('ossdemo/readstream.txt', fs.createReadStream(filepath)).then((result) => {\r\n  console.log(result);\r\n});\r\n\r\n{\r\n  name: 'ossdemo/readstream.txt',\r\n  url: 'http://demo.oss-cn-hangzhou.aliyuncs.com/ossdemo/readstream.txt',\r\n  res: {\r\n    status: 200,\r\n    headers: {\r\n      date: 'Tue, 17 Feb 2015 13:28:17 GMT',\r\n      'content-length': '0',\r\n      connection: 'close',\r\n      etag: '\"BF7A03DA01440845BC5D487B369BC168\"',\r\n      server: 'AliyunOSS',\r\n      'x-oss-request-id': '54E341F1707AA0275E829242'\r\n    },\r\n    size: 0,\r\n    rt: 92\r\n  }\r\n}\r\n```\r\n\r\n### .append(name, file[, options])\r\n\r\nAppend an object to the bucket, it's almost same as put, but it can add content to existing object rather than override it.\r\n\r\nAll parameters are same as put except for options.position\r\n\r\n- name {String} object name store on OSS\r\n- file {String|Buffer|ReadStream} object local path, content buffer or ReadStream content instance\r\n- [options] {Object} optional parameters\r\n  - [position] {String} specify the position which is the content length of the latest object\r\n  - [timeout] {Number} the operation timeout\r\n  - [mime] {String} custom mime, will send with `Content-Type` entity header\r\n  - [meta] {Object} user meta, will send with `x-oss-meta-` prefix string\r\n    e.g.: `{ uid: 123, pid: 110 }`\r\n  - [headers] {Object} extra headers, detail see [RFC 2616](http://www.w3.org/Protocols/rfc2616/rfc2616.html)\r\n    - 'Cache-Control' cache control for download, e.g.: `Cache-Control: public, no-cache`\r\n    - 'Content-Disposition' object name for download, e.g.: `Content-Disposition: somename`\r\n    - 'Content-Encoding' object content encoding for download, e.g.: `Content-Encoding: gzip`\r\n    - 'Expires' expires time for download, an absolute date and time. e.g.: `Tue, 08 Dec 2020 13:49:43 GMT`\r\n\r\nobject:\r\n\r\n- name {String} object name\r\n- url {String} the url of oss\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n- nextAppendPosition {String} the next position\r\n\r\nexample:\r\n\r\n```js\r\nlet object = await store.append('ossdemo/buffer', Buffer.from('foo'));\r\n\r\n// append content to the existing object\r\nobject = await store.append('ossdemo/buffer', Buffer.from('bar'), {\r\n  position: object.nextAppendPosition\r\n});\r\n```\r\n\r\n### .getObjectUrl(name[, baseUrl])\r\n\r\nGet the Object url.\r\nIf provide `baseUrl`, will use `baseUrl` instead the default `endpoint`.\r\n\r\ne.g.:\r\n\r\n```js\r\nconst cdnUrl = client.getObjectUrl('foo/bar.jpg', 'https://mycdn.domian.com');\r\n// cdnUrl should be `https://mycdn.domian.com/foo/bar.jpg`\r\n```\r\n\r\n### .generateObjectUrl(name[, baseUrl])\r\n\r\nGet the Object url.\r\nIf provide `baseUrl`, will use `baseUrl` instead the default `bucket and endpoint `.\r\nSuggest use generateObjectUrl instead of getObjectUrl.\r\n\r\ne.g.:\r\n\r\n```js\r\nconst url = client.generateObjectUrl('foo/bar.jpg');\r\n// cdnUrl should be `https://${bucketname}.${endpotint}foo/bar.jpg`\r\n\r\nconst cdnUrl = client.generateObjectUrl('foo/bar.jpg', 'https://mycdn.domian.com');\r\n// cdnUrl should be `https://mycdn.domian.com/foo/bar.jpg`\r\n```\r\n\r\n### .head(name[, options])\r\n\r\nHead an object and get the meta info.\r\n\r\nparameters:\r\n\r\n- name {String} object name store on OSS\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n  - [versionId] {String} the version id of history object\r\n  - [headers] {Object} extra headers, detail see [RFC 2616](http://www.w3.org/Protocols/rfc2616/rfc2616.html)\r\n    - 'If-Modified-Since' object modified after this time will return 200 and object meta,\r\n      otherwise return 304 not modified\r\n    - 'If-Unmodified-Since' object modified before this time will return 200 and object meta,\r\n      otherwise throw PreconditionFailedError\r\n    - 'If-Match' object etag equal this will return 200 and object meta,\r\n      otherwise throw PreconditionFailedError\r\n    - 'If-None-Match' object etag not equal this will return 200 and object meta,\r\n      otherwise return 304 not modified\r\n\r\nSuccess will return the object's meta information.\r\n\r\nobject:\r\n\r\n- status {Number} response status, maybe 200 or 304\r\n- meta {Object} object user meta, if not set on `put()`, will return null.\r\n  If return status 304, meta will be null too\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n    - [x-oss-version-id] return in multiversion\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nexample:\r\n\r\n- Head an exists object and get user meta\r\n\r\n```js\r\nawait this.store.put('ossdemo/head-meta', Buffer.from('foo'), {\r\n  meta: {\r\n    uid: 1,\r\n    path: 'foo/demo.txt'\r\n  }\r\n});\r\nconst object = await this.store.head('ossdemo/head-meta');\r\nconsole.log(object);\r\n\r\n{\r\n  status: 200,\r\n  meta: {\r\n    uid: '1',\r\n    path: 'foo/demo.txt'\r\n  },\r\n  res: { ... }\r\n}\r\n```\r\n\r\n- Head a not exists object\r\n\r\n```js\r\nconst object = await this.store.head('ossdemo/head-meta');\r\n// will throw NoSuchKeyError\r\n```\r\n\r\n### .getObjectMeta(name[, options])\r\n\r\nGet an object meta info include ETag、Size、LastModified and so on, not return object content.\r\n\r\nparameters:\r\n\r\n- name {String} object name store on OSS\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n  - [versionId] {String} the version id of history object\r\n\r\nSuccess will return the object's meta information.\r\n\r\nobject:\r\n\r\n- status {Number} response status\r\n- res {Object} response info, including\r\n  - headers {Object} response headers\r\n\r\nexample:\r\n\r\n- Head an exists object and get object meta info\r\n\r\n```js\r\nawait this.store.put('ossdemo/object-meta', Buffer.from('foo'));\r\nconst object = await this.store.getObjectMeta('ossdemo/object-meta');\r\nconsole.log(object);\r\n\r\n{\r\n  status: 200,\r\n  res: { ... }\r\n}\r\n```\r\n\r\n### .get(name[, file, options])\r\n\r\nGet an object from the bucket.\r\n\r\nparameters:\r\n\r\n- name {String} object name store on OSS\r\n- [file] {String|WriteStream} file path or WriteStream instance to store the content\r\n  If `file` is null or ignore this parameter, function will return info contains `content` property.\r\n- [options] {Object} optional parameters\r\n  - [versionId] {String} the version id of history object\r\n  - [timeout] {Number} the operation timeout\r\n  - [process] {String} image process params, will send with `x-oss-process`\r\n    e.g.: `{process: 'image/resize,w_200'}`\r\n  - [responseCacheControl] {String} default `no-cache`, (only support Browser). response-cache-control, will response with HTTP Header `Cache-Control`\r\n  - [headers] {Object} extra headers, detail see [RFC 2616](http://www.w3.org/Protocols/rfc2616/rfc2616.html)\r\n    - 'Range' get specifying range bytes content, e.g.: `Range: bytes=0-9`\r\n    - 'If-Modified-Since' object modified after this time will return 200 and object meta,\r\n      otherwise return 304 not modified\r\n    - 'If-Unmodified-Since' object modified before this time will return 200 and object meta,\r\n      otherwise throw PreconditionFailedError\r\n    - 'If-Match' object etag equal this will return 200 and object meta,\r\n      otherwise throw PreconditionFailedError\r\n    - 'If-None-Match' object etag not equal this will return 200 and object meta,\r\n      otherwise return 304 not modified\r\n\r\nSuccess will return the info contains response.\r\n\r\nobject:\r\n\r\n- [content] {Buffer} file content buffer if `file` parameter is null or ignore\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nIf object not exists, will throw NoSuchKeyError.\r\n\r\nexample:\r\n\r\n- Get an exists object and store it to the local file\r\n\r\n```js\r\nconst filepath = '/home/ossdemo/demo.txt';\r\nawait store.get('ossdemo/demo.txt', filepath);\r\n```\r\n\r\n\\_ Store object to a writestream\r\n\r\n```js\r\nawait store.get('ossdemo/demo.txt', somestream);\r\n```\r\n\r\n- Get an object content buffer\r\n\r\n```js\r\nconst result = await store.get('ossdemo/demo.txt');\r\nconsole.log(Buffer.isBuffer(result.content));\r\n```\r\n\r\n- Get a processed image and store it to the local file\r\n\r\n```js\r\nconst filepath = '/home/ossdemo/demo.png';\r\nawait store.get('ossdemo/demo.png', filepath, { process: 'image/resize,w_200' });\r\n```\r\n\r\n- Get a not exists object\r\n\r\n```js\r\nconst filepath = '/home/ossdemo/demo.txt';\r\nawait store.get('ossdemo/not-exists-demo.txt', filepath);\r\n// will throw NoSuchKeyError\r\n```\r\n\r\n- Get a historic version object\r\n\r\n```js\r\nconst filepath = '/home/ossdemo/demo.txt';\r\nconst versionId = 'versionId string';\r\nawait store.get('ossdemo/not-exists-demo.txt', filepath, {\r\n  versionId\r\n});\r\n```\r\n\r\n### .getStream(name[, options])\r\n\r\nGet an object read stream.\r\n\r\nparameters:\r\n\r\n- name {String} object name store on OSS\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n  - [process] {String} image process params, will send with `x-oss-process`\r\n  - [headers] {Object} extra headers\r\n    - 'If-Modified-Since' object modified after this time will return 200 and object meta,\r\n      otherwise return 304 not modified\r\n    - 'If-Unmodified-Since' object modified before this time will return 200 and object meta,\r\n      otherwise throw PreconditionFailedError\r\n    - 'If-Match' object etag equal this will return 200 and object meta,\r\n      otherwise throw PreconditionFailedError\r\n    - 'If-None-Match' object etag not equal this will return 200 and object meta,\r\n      otherwise return 304 not modified\r\n\r\nSuccess will return the stream instance and response info.\r\n\r\nobject:\r\n\r\n- stream {ReadStream} readable stream instance\r\n  if response status is not 200, stream will be `null`.\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nIf object not exists, will throw NoSuchKeyError.\r\n\r\nexample:\r\n\r\n- Get an exists object stream\r\n\r\n```js\r\nconst result = await store.getStream('ossdemo/demo.txt');\r\nresult.stream.pipe(fs.createWriteStream('some file.txt'));\r\n```\r\n\r\n### .delete(name[, options])\r\n\r\nDelete an object from the bucket.\r\n\r\nparameters:\r\n\r\n- name {String} object name store on OSS\r\n- [options] {Object} optional parameters\r\n  - [timeout] {Number} the operation timeout\r\n  - [versionId] {String} the version id of history object\r\n\r\nSuccess will return the info contains response.\r\n\r\nobject:\r\n\r\n- res {Object} response info, including\r\n  - status {Number} response status\r\n  - headers {Object} response headers\r\n  - size {Number} response size\r\n  - rt {Number} request total use time (ms)\r\n\r\nIf delete object not exists, will also delete success.\r\n\r\nexample:\r\n\r\n- Delete an exists object\r\n\r\n```js\r\nawait store.delete('ossdemo/someobject');\r\n```\r\n\r\n- Delete a not exists object\r\n\r\n```js\r\nawait store.delete('ossdemo/some-not-exists-object');\r\n```\r\n\r\n- Delete a history object or deleteMarker\r\n\r\n```js\r\nconst versionId = 'versionId';\r\nawait store.delete('ossdemo/some-not-exists-object', { versionId });\r\n```\r\n\r\n### .copy(name, sourceName[, sourceBucket, options])\r\n\r\nCopy an object from `sourceName` to `name`.\r\n\r\nparameters:\r\n\r\n- name {String} object name store on OSS\r\n- sourceName {String} source object name\r\n- [sourceBucket] {String} source Bucket. if doesn't exist，`sourceBucket` is same bucket.\r\n- [options] {Object} optional parameters\r\n  - [versionId] {String} the version id of history object\r\n  - [timeout] {Number} the operation timeout\r\n  - [meta] {Object} user meta, will send with `x-oss-meta-` prefix string\r\n    e.g.: `{ uid: 123, pid: 110 }`\r\n    If the `meta` set, will override the source object meta.\r\n  - [headers] {Object} extra headers\r\n    - 'If-Match' do copy if source object etag equal this,\r\n      otherwise throw Prec","readmeFilename":"README.md"}