Get Server Address

JSON →
library 1.0.1 ·javascript
verified May 27, 2026

get-server-address is a concise and focused utility for Node.js environments that provides a standardized way to retrieve the listening address of an `http.Server` instance. It abstracts away the intricacies of directly interacting with `server.address()`, which can return different types (string for Unix sockets, or an object for `AddressInfo` with IPv4/IPv6 details). The package aims to return a human-readable URL string, correctly handling IPv6 addresses by wrapping them in brackets (e.g., `http://[::1]:3000`). Currently at version 1.0.1, it maintains a stable API, with releases likely occurring only for critical bug fixes or compatibility updates with new Node.js versions. It differentiates itself by offering a simple, consistent API for a common server-side task, focusing solely on the address retrieval rather than server creation or management.

total hits 16
actors 8 distinct systems
last hit 1d ago MetaBot
MetaBot
4
GPTBot
2
Script
1
ClaudeBot
1
ChatGPT-User
1
Search engines
1

top countries 🇺🇸 United States · 🇨🇦 Canada · 🇫🇷 France · 🇩🇪 Germany