Skip to content

often/whoami

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

whoami

quick API that returns your IP address and headers.

get IP address and headers

JS

let whoami = 'https://whoami.deno.dev'
let response = await fetch(whoami)
let data = await response.json()

console.log(data)

CLI

curl https://whoami.deno.dev?pretty

get IP address only

JS

let whoami = 'https://whoami.deno.dev?ip'
let response = await fetch(whoami)
let ip = await response.text()

console.log(ip)

CLI

curl https://whoami.deno.dev?ip

license

0BSD