feat(apihits): so i can see if what end points are being used and when and how often
This commit is contained in:
@@ -3,6 +3,7 @@ import { responses } from "../../../../globalUtils/routeDefs/responses.js";
|
||||
import { ordersIn } from "../../controller/dm/ordersIn/ordersIn.js";
|
||||
import { verify } from "hono/jwt";
|
||||
import { tryCatch } from "../../../../globalUtils/tryCatch.js";
|
||||
import { apiHit } from "../../../../globalUtils/apiHits.js";
|
||||
|
||||
const app = new OpenAPIHono();
|
||||
|
||||
@@ -31,7 +32,7 @@ app.openapi(
|
||||
responses: responses(),
|
||||
}),
|
||||
async (c) => {
|
||||
//apiHit(c, { endpoint: "api/sqlProd/close" });
|
||||
apiHit(c, { endpoint: "/postbulkorders" });
|
||||
const body = await c.req.parseBody();
|
||||
const authHeader = c.req.header("Authorization");
|
||||
const token = authHeader?.split("Bearer ")[1] || "";
|
||||
|
||||
Reference in New Issue
Block a user