Quick Start
Make your first geolocation request in under 2 minutes.
1. Create an Account
Sign up for a free account at boxesnlines.com/register. The Starter plan includes 10,000 free requests per month.
2. Generate an API Key
After signing in, go to your API Keys dashboard and create a new API key. Your key will look like:
bnl_abc123_yourSecretKeyHere
warning
Save your API key immediately after creation. The full API key is only shown once.
3. Make Your First Request
Using cURL
curl "https://api.boxesnlines.com/geo/country/fromGps/40.7128,-74.0060" \
-H "X-API-Key: YOUR_API_KEY"
Using JavaScript
const response = await fetch(
"https://api.boxesnlines.com/geo/country/fromGps/40.7128,-74.0060",
{
headers: {
"X-API-Key": "YOUR_API_KEY"
}
}
);
const countryCode = await response.text();
console.log(countryCode); // "USA"
Using Python
import requests
response = requests.get(
"https://api.boxesnlines.com/geo/country/fromGps/40.7128,-74.0060",
headers={"X-API-Key": "YOUR_API_KEY"}
)
print(response.text) # "USA"
4. Understand the Response
The country lookup endpoint returns an ISO 3166-1 alpha-3 country code:
| Coordinates | Response | Location |
|---|---|---|
| 40.7128, -74.0060 | USA | New York, USA |
| 51.5074, -0.1278 | GBR | London, UK |
| 35.6762, 139.6503 | JPN | Tokyo, Japan |
| -22.9068, -43.1729 | BRA | Rio de Janeiro, Brazil |
Next Steps
- Authentication - Learn about API key security
- Country Lookup - Detailed guide for country lookups
- API Reference - Try all endpoints interactively