Skip to content

My IP

GET https://api.echovalue.dev/myip

Returns the IP address seen by echoValue for the current request, plus geo metadata derived from the request headers.

This endpoint is useful when you need to:

  • verify the public IP used by your server or client
  • detect whether the current request arrived over IPv4 or IPv6
  • inspect geo metadata such as city, country, timezone, and region

Headers:

HeaderDescription
x-tokenYour API token

Examples:

Terminal window
curl 'https://api.echovalue.dev/myip' \
-H 'x-token: mytoken'

Response: 200 — JSON object.

{
"ip": "203.0.113.42",
"ipv6": "",
"isCurrentIpv6": false,
"userAgent": "curl/8.7.1",
"acceptLanguage": "en-US,en;q=0.9",
"city": "Rome",
"country": "IT",
"continent": "EU",
"latitude": "41.9028",
"longitude": "12.4964",
"region": "Lazio",
"regionCode": "62",
"timezone": "Europe/Rome",
"postalCode": "00100"
}
FieldTypeDescription
ipstringIPv4 address when available. Empty for native IPv6 callers.
ipv6stringRaw IPv6 address when the current caller IP is IPv6.
isCurrentIpv6booleantrue when the incoming request IP is IPv6.
userAgentstringCaller user agent string.
acceptLanguagestringCaller Accept-Language header when present.
citystringDetected city.
countrystringDetected country code.
continentstringDetected continent code.
latitudestringLatitude associated with the caller IP.
longitudestringLongitude associated with the caller IP.
regionstringDetected region or state name.
regionCodestringRegion code.
timezonestringDetected IANA timezone.
postalCodestringDetected postal code.

Response headers:

HeaderDescription
x-balanceWallet balance after this call
x-costCredits consumed

See Response Headers for details.

StatusMeaning
200IP data returned
401Invalid token
402Insufficient credits
405Method not allowed