3.0.3 • Published 10 months ago

dropboxify v3.0.3

Weekly downloads
343
License
MIT
Repository
github
Last release
10 months ago

Dropboxify License NPM version Build Status Coverage Status

Read directory content from dropbox compatible way with readify.

Install

npm i dropboxify

API

dropboxify(token, dir, options)

  • token - string generated access token
  • options - object can contain:
    • sort - sort by: name, size, date
    • order - "asc" or "desc" for ascending and descending order (default: "asc")
    • type - when "raw" returns not formatted result

Examples

const sort = 'size';
const order = 'desc';
const token = 'token';
const dir = '/';
const type = 'raw';

const files = await dropboxify(token, dir, {
    type,
    sort,
    order,
});

console.log(files);
// outputs
({
    path: '/',
    files: [{
        name: 'dropboxify.js',
        size: 4735,
        date: 1_377_248_899_000,
        owner: 0,
        mode: 0,
    }, {
        name: 'readify.js',
        size: 3735,
        date: 1_377_248_899_000,
        owner: 0,
        mode: 0,
    }],
});

Related

  • Sortify - sort directory content by name, size, date
  • Readify - read directory content with file attributes: size, date, owner, mode

License

MIT

3.0.3

10 months ago

3.0.2

1 year ago

3.0.1

1 year ago

3.0.0

1 year ago

2.0.6

5 years ago

2.0.5

5 years ago

2.0.4

6 years ago

2.0.3

6 years ago

2.0.2

7 years ago

2.0.1

7 years ago

2.0.0

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago