From e6a0ae10fa904b6777cb8f8fdcdf638ca6f4f886 Mon Sep 17 00:00:00 2001 From: Marshall Polaris Date: Sun, 17 Jul 2022 20:50:13 -0700 Subject: [PATCH] Nicer logging of API requests --- functions/src/api.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions/src/api.ts b/functions/src/api.ts index b967d2d1..fdda0ad5 100644 --- a/functions/src/api.ts +++ b/functions/src/api.ts @@ -123,7 +123,7 @@ export const newEndpoint = (endpointOpts: EndpointOptions, fn: Handler) => { return { opts, handler: async (req: Request, res: Response) => { - log('Request processing started.') + log(`${req.method} ${req.url} ${JSON.stringify(req.body)}`) try { if (opts.method !== req.method) { throw new APIError(405, `This endpoint supports only ${opts.method}.`)