You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

nyord-vpn

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nyord-vpn

NordVPN client with API fallback support

0.1.0
Source
pipPyPI
Maintainers
1

nyord-vpn

A simple and reliable NordVPN client for macOS with support for both legacy OpenVPN and njord APIs.

Features

  • Simple and reliable VPN connection management
  • Support for both legacy OpenVPN and njord APIs
  • Country selection
  • Basic status monitoring
  • Clear error messages
  • Minimal dependencies

Installation

# Install system requirements
brew install openvpn

# Install package
pip install nyord-vpn

# Optional: Install njord support
pip install nyord-vpn[njord]

Usage

Environment Variables

Set your NordVPN credentials:

export NORD_USER="your-username"
export NORD_PASSWORD="your-password"

CLI Commands

# Connect to VPN (defaults to US)
nyord-vpn connect

# Connect to specific country
nyord-vpn connect --country netherlands

# Use njord API
nyord-vpn --api njord connect

# Enable debug logging
nyord-vpn --verbose connect

# Check status
nyord-vpn status

# List available countries
nyord-vpn list-countries

# Disconnect
nyord-vpn disconnect

Python API

from nyord_vpn.core.factory import create_client

# Create client (legacy or njord)
client = create_client("legacy")

# Connect to VPN
client.connect("netherlands")

# Check status
status = client.status()
print(f"Connected to {status['server']} ({status['ip']})")

# Disconnect
client.disconnect()

Development

# Install dependencies
pip install -r requirements.txt

# Install optional njord support
pip install njord

# Run with debug logging
NORD_USER="username" NORD_PASSWORD="password" nyord-vpn --verbose connect

Error Handling

The client uses simple retry logic for API calls and provides clear error messages. Common errors:

  • VPNCredentialsError: Missing or invalid credentials
  • VPNConnectionError: Failed to connect/disconnect
  • VPNConfigError: Configuration issues (e.g., missing OpenVPN)
  • VPNServerError: Failed to get server information

Contributing

  • Fork the repository
  • Create a feature branch
  • Make your changes
  • Submit a pull request

License

MIT

Keywords

vpn

FAQs

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.