https://github.com/freddie-nelson/node-protonvpn
https://github.com/freddie-nelson/node-protonvpn
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/freddie-nelson/node-protonvpn
- Owner: freddie-nelson
- Created: 2023-08-12T22:05:28.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-08-13T16:40:02.000Z (almost 2 years ago)
- Last Synced: 2025-05-08T19:12:43.211Z (about 1 month ago)
- Language: TypeScript
- Size: 37.1 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
🔥 node-protonvpn 🔥
Become a Stargazer**Connect to protonvpn servers through a simple nodejs api**
## Installation
```bash
# with npm
npm install node-protonvpn
``````bash
# with yarn
yarn add node-protonvpn
```## Usage
```javascript
// configs can be found at https://account.protonvpn.com/downloads
// - under country configs
// - download all
const configDir = "dir/to/configs";// optional - fix config compression error
fixConfigCompressionErrorDir(configDir);// can be found at https://account.protonvpn.com/account
const auth: OpenVpnAuth = {
user: "opevpn username",
pass: "openvpn password",
};const protonVpn = new ProtonVpnController(configDir, auth, {
enableLogging: true,
});protonVpn.connect("US");
```**IMPORTANT: You must have openvpn installed on your machine and run node as administrator on windows (linux not tested)**
## Contributing
### Prerequisites
- node (lts version)
- yarn (1.^22.10)### Setup
```bash
# clone repo
git clone https://github.com/freddie-nelson/node-protonvpn
cd node-protonvpn# install dependencies
yarn# start dev server
yarn dev# run build
node dist/index.esm.js
```## License
[MIT](https://opensource.org/licenses/MIT)
Copyright © 2020 - Present, Freddie Nelson
## Contact
- [Send me an email 📧](mailto:[email protected])
- [Contact me through my website](https://freddienelson.co.uk)