- Author: Ganesh Rathinavel
- License: MIT
- System Requirements: macOS v10.10 or higher, libmtp
- Repo URL: https://github.com/ganeshrvel/mtp-nodejs-port-native-addon
- Contacts: ganeshrvel@outlook.com
Access Android phones and other MTP devices using Node.js. This project uses N-API wrapper around the libmtp library. It uses version 3 of N-API which is only available on Node.js v10 and higher.
- Upload file to MTP
- Download file from MTP
- Get MTP file tree
- Create MTP folder
- Rename MTP file
- Delete MTP file
Requirements: Node.js v10, Git, Yarn package manager, libmtp and Homebrew for mac
# Ubuntu
sudo apt-get install libmtp-dev
# macOS
brew install libmtp
$ git clone --depth 1 --single-branch --branch master https://github.com/ganeshrvel/mtp-nodejs-port-native-addon.git
$ cd mtp-nodejs-port-native-addon
$ yarn
$ yarn run build-node-gyp
Find usage examples in test.js
$ node test.js
// to refresh the MTP
$ node test.js resetmtp
- OpenMTP - Advanced Android File Transfer Application for macOS
- npm: electron-root-path
- Electron React Redux Advanced Boilerplate
- Tutorial Series by Ganesh Rathinavel
- This is a heavily modified fork of mceSystems/node-mtp which has now been discontinued.
- Fork the repo and create your branch from master.
- Ensure that the changes pass linting.
- Update the documentation if needed.
- Make sure your code lints.
- Issue a pull request!
When you submit code changes, your submissions are understood to be under the same MIT License that covers the project. Feel free to contact the maintainers if that's a concern.
Help me keep the app FREE and open for all. Paypal me: paypal.me/ganeshrvel
Please feel free to contact me at ganeshrvel@outlook.com
MTP Port for node.js - Native addon is released under MIT License.
Copyright © 2018-Present Ganesh Rathinavel