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