D
Afternoon Demo
Usage for last 30 days
Requests3133
Errors64
API Key
loc_demo_vhNqAiKyqx2TOrPqhunhhNKozf8U1RH6
Example
export async function lookupIp(ip = "8.8.8.8") {
  const gatewayBaseUrl = https://locations.humade.studio
  const response = await fetch(`${gatewayBaseUrl}/v1/location?ip=${ip}`, {
    method: "GET",
    headers: {
      Accept: "application/json",
      Authorization: `Bearer loc_demo_UoCHBpiucRXIesN7xOta06yk0bsjk9yQ`,
    },
  })

  if (!response.ok) {
    throw new Error(`Request failed: ${response.status}`)
  }

  const result = await response.json()
  return result
}