d
This commit is contained in:
parent
78cd255661
commit
20e6c4f0eb
1 changed files with 15 additions and 1 deletions
14
index.js
14
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
|
// All dates in the database
|
||||||
|
|
||||||
app.get('/api/:auth/database', alldata);
|
app.get('/api/:auth/database', alldata);
|
||||||
|
@ -146,3 +159,4 @@ async function remove(request, response) {
|
||||||
|
|
||||||
response.send(reply);
|
response.send(reply);
|
||||||
}
|
}
|
||||||
|
*/
|
Loading…
Reference in a new issue