A simple IP Tracker API built with Elysia.js and BUN that provides geolocation information for a given IP address using a custom SQLite dataset.
- BUN
- Elysia.js
-
Clone the repository:
git clone https://github.com/rakibmia72/IPGeoTracker.git && cd IPGeoTracker
-
Install dependencies:
bun install
-
Start the server:
bun run index.js
-
Access the API:
- The server runs on
http://localhost:3000
. - Use the
/
endpoint to get geolocation data.
- The server runs on
curl http://localhost:3000/1.1.1.1
or
curl http://localhost:3000/me
{
"ip": "1.1.1.1",
"info": {
"registry": "apnic",
"assigned": "1313020800",
"country_code": "AU",
"country": "Australia",
"region": "AUS"
}
}
This project is licensed under the MIT License.