@drakezhou/network-check
v0.1.0
Published
Account-free network reachability and public IP location checks
Downloads
198
Readme
Network Check
Check reachability to Claude, Codex/OpenAI, YouTube, and GitHub, plus your public IP location. Runs on your own computer. No service account, API key, Python, or curl needed.
Requires Node.js 22 or later and npm. Works as a terminal command in zsh, bash, and PowerShell.
Run
npx @drakezhou/network-checkOpen the results in your browser:
npx @drakezhou/network-check --openOr install once for repeat use:
npm install -g @drakezhou/network-check
network-check
network-check --replnpx downloads the package automatically. npm registry access is needed for the
first run; an installed copy can still run when the registry is unreachable.
No npm login is required to use the public package.
Results
- Reachable: the endpoint answered the probe.
- Not confirmed: the check could not complete.
- Location reported by public IP databases: your exit IP and country, checked
with IPinfo, IPwho, and Cloudflare. Agreement on one IP and
USgives United States (US). Mixed routes, conflicting countries, or missing data are reported separately.
Security checks and login prompts still count as reachable. Terminal and browser reports show reachability and elapsed time; raw HTTP codes are only in JSON exports. Location is independent of the reachability result. A public location lookup does not establish how a service classifies your IP internally.
Options
network-check --html report.html --json report.json
network-check --direct
network-check --ipv4
network-check --ipv6
network-check --timeout 10
network-check --help--open writes network-report.html unless --html PATH is supplied. Reports are
static and need no running web server. An existing output file is replaced.
Browser reports display the terminal checks; they do not test the browser's own
network settings. Browser opening requires a desktop session.
REPL commands:
run
html report.html
json report.json
help
quitA path after html or json is taken literally and may include spaces; do not add
shell quotes inside the REPL. run repeats the starting options.
Network route and privacy
The checker honors HTTPS_PROXY, HTTP_PROXY, ALL_PROXY, NO_PROXY, and their
lowercase forms (lowercase takes precedence). Proxies must use HTTP or HTTPS;
SOCKS URLs are rejected rather than silently bypassed. --direct bypasses these
proxy settings, but VPN/TUN and operating-system routing still apply. Browser PAC
and app-specific proxy settings are not read. IP-family flags apply to local
connections; a proxy independently chooses its upstream address family.
Requests use TLS certificate verification. No service credentials, cookies, account files, or app configurations are read. Proxy credentials already present in the environment may be used for that proxy. Proxy URLs, error messages, and remote response bodies are not exported. Raw JSON includes sanitized error codes. There is no telemetry or result-upload service. The contacted sites receive your public IP, and exported reports include that IP.
Checks cover common service endpoints, not every CDN or integration. They do not
run a model or play a video. Website probes use HEAD; model-list APIs and location
lookups use GET. Redirects are not followed. Domain-based routing may use different
exit addresses for different services, so a geolocation endpoint's result is not
proof of every service's exit address. Cloudflare's loc country field is used,
not its datacenter location.
Exit codes: 0 all service endpoints reachable; 1 at least one not confirmed;
2 invalid arguments/setup/output error; 130 interrupted. Location checks do not
determine the exit code. Quitting the REPL returns the most recent run's result.
Develop
npm ci
npm test
node bin/network-check.js
npm pack --dry-runThe npm artifact includes only bin/, src/, this README, the license, and package
metadata. Tests and local reports are excluded.
Endpoint references: Claude Code network requirements, Codex authentication, IPwho documentation, IPinfo documentation.
MIT licensed.
