By using open source SDK βοΈ οΈit allows you to connect & explore paid storage manager DriveQu via other apps (cross app). You can visit https://drivequ.herokuapp.com for trial use & get experience as a file explorer π€ in a restricted environment.
Install using npm
$ npm i -S drivequ
... Or using yarn
$ yarn add drivequ
// commonjs
const drivequ = require('drivequ');
// es modules
import drivequ from 'drivequ';
By purchasing our product, you can use your own host
address.
drivequ.init({
host: 'https://drivequ.herokuapp.com',
accessKeyId: '{access-key-id}',
});
By default, the files upload location
will be directed to the root folder.
You can upload files into the folder by filling in the location
based on the url of the folder you want to go to (Also applies to folders).
// single upload
await drivequ.file.upload({
file: req.file,
location: '/',
});
// multiples upload
await drivequ.file.upload({
files: req.file,
location: '/74487546-8574-40d5-8986...',
}, {
multiples : true,
});
Junk files are placed separately from other files (Also applies to folders).
await drivequ.file.find({
location: '/',
trashed: false,
});
The delete
method requires an array parameter containing the id
of the files you want to delete.
await drivequ.file.delete(['6267f14cc458...']);
Folder name is unique if the location is the same.
await drivequ.folder.create({
name: 'Folder Name',
description: 'A description of your folder',
location: '/',
});
await drivequ.folder.find({
location: '/5a462358-8881-42e1-83eb...',
});
The delete
method requires an array parameter containing the id
of the folder you want to delete.
await drivequ.folder.delete(['6265c71a08f8...']);
Contributions make the open source community a great place to learn, inspire and create. I really appreciate every contribution you make.
If you have any suggestions that would make this even better, please fork this repo and pull request. You can also open an issue on this project and don't forget to give this project a star. Thank you.
- Fork this project
- Create a new branch -
git checkout -b branchName
- Commit your changes -
git commit -m "Add new features"
- Push to your branch -
git push origin branchName
- Submit a pull request
Distributed under the GPL-3.0 License. See LICENSE.txt for more information.