mirror of
https://dev.azure.com/tstanciu94/PhantomMind/_git/Bitip
synced 2025-10-13 01:52:19 +03:00
- Changed main entry point from `index.js` to `server.js` in package.json. - Created a new `app.ts` file to encapsulate Express app configuration. - Removed old `index.ts` file and moved server logic to `server.ts`. - Updated nodemon configurations to point to the new `server.ts`. - Added new middleware for API key authentication with public endpoint support. - Modified validators to accept any string for IPs, allowing handlers to determine validity. - Added integration tests for batch lookup and health endpoints. - Implemented unit tests for error handling and validation middleware. - Updated `tsup` and `vitest` configurations to reflect new entry points and testing setup.
55 lines
1.5 KiB
JSON
55 lines
1.5 KiB
JSON
{
|
|
"name": "bitip-backend",
|
|
"version": "1.2.0",
|
|
"description": "Bitip Backend - GeoIP REST API Service",
|
|
"type": "module",
|
|
"main": "dist/server.js",
|
|
"scripts": {
|
|
"dev": "nodemon",
|
|
"dev:debug": "nodemon --config nodemon-debug.json",
|
|
"build": "tsup",
|
|
"start": "node ../../dist/backend/server.js",
|
|
"test": "vitest run",
|
|
"test:watch": "vitest",
|
|
"test:ui": "vitest --ui",
|
|
"test:coverage": "vitest --coverage",
|
|
"lint": "eslint .",
|
|
"lint:fix": "eslint . --fix",
|
|
"clean": "rimraf ../../dist/backend"
|
|
},
|
|
"dependencies": {
|
|
"@maxmind/geoip2-node": "^6.1.0",
|
|
"compression": "^1.7.4",
|
|
"cors": "^2.8.5",
|
|
"dotenv": "^17.2.3",
|
|
"express": "^5.1.0",
|
|
"express-rate-limit": "^8.1.0",
|
|
"helmet": "^8.1.0",
|
|
"joi": "^18.0.1",
|
|
"node-cache": "^5.1.2",
|
|
"seq-logging": "^3.0.0"
|
|
},
|
|
"devDependencies": {
|
|
"@types/compression": "^1.7.5",
|
|
"@types/cors": "^2.8.17",
|
|
"@types/express": "^5.0.3",
|
|
"@types/node": "^22.14.1",
|
|
"@types/supertest": "^6.0.3",
|
|
"@typescript-eslint/eslint-plugin": "^8.45.0",
|
|
"@typescript-eslint/parser": "^8.45.0",
|
|
"@vitest/coverage-v8": "^3.2.4",
|
|
"@vitest/ui": "^3.2.4",
|
|
"eslint": "^9.36.0",
|
|
"eslint-config-prettier": "^10.1.8",
|
|
"eslint-plugin-prettier": "^5.5.4",
|
|
"nodemon": "^3.1.10",
|
|
"prettier": "^3.4.2",
|
|
"rimraf": "^6.0.1",
|
|
"supertest": "^7.1.4",
|
|
"ts-node": "^10.9.2",
|
|
"tsup": "^8.5.0",
|
|
"typescript": "^5.9.2",
|
|
"vitest": "^3.2.4"
|
|
}
|
|
}
|