From 20e6c4f0eb910dff9747c023c54961177c63f6ad Mon Sep 17 00:00:00 2001 From: Killer Boss Original <73131550+killerbossoriginal@users.noreply.github.com> Date: Wed, 6 Jul 2022 12:55:00 +0200 Subject: [PATCH] d --- index.js | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index 183cabc..771b717 100644 --- a/index.js +++ b/index.js @@ -60,6 +60,19 @@ async function authenticate(token, response, what) { } } +/* +app.post('/', (req, res) => { + res.send('Got a POST request') +}) +*/ + +app.post('/api/:auth/database', (req, res) => { + var token = request.params.auth; + authenticate(token, response, 'alldata') + res.send('elements') +}) + +/* // All dates in the database app.get('/api/:auth/database', alldata); @@ -145,4 +158,5 @@ async function remove(request, response) { } response.send(reply); -} \ No newline at end of file +} +*/ \ No newline at end of file