Package Exports
- node-ovh-storage
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 (node-ovh-storage) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
node-ovh-storage
A simple Node.js library to connect to the Object Storage OVH service
Install via npm
npm install node-ovh-storage --save
API Usage
var OVHStorage = require('node-ovh-storage');
var config = {
username: 'username',
password: 'password',
authURL: 'https://auth.cloud.ovh.net/v2.0',
tenantId: 'tenantId',
region: 'GRA1'
};
var storage = new OVHStorage(config);
// init token
storage.getToken(function(err) {
// create new container
storage.createContainer('Storage-1', function() {
// put file
storage.putFile('./tmp/doc.pdf', '/Storage-1/doc.pdf', function(err, res) {
// list files in container
storage.getFiles('/Storage-1', function(err, files) {
// done
});
});
});
});