Skip to content

Commit 4b3506d

Browse files
author
Nino van Galen
committed
feat: Added user route
1 parent c0a5f75 commit 4b3506d

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

backend/lib/routes/users.js

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
const { User } = require('../controllers');
2+
module.exports = {
3+
method: 'get',
4+
path: '/users',
5+
controller: User.index,
6+
args: { public: true },
7+
children: [
8+
{
9+
method: 'get',
10+
path: '/:id',
11+
controller: User.read,
12+
},
13+
{
14+
method: 'get',
15+
path: '/:id/tokens',
16+
controller: User.getTokens,
17+
},
18+
{
19+
method: 'post',
20+
path: '/:id/tokens',
21+
controller: User.postTokens,
22+
},
23+
{
24+
method: 'get',
25+
path: '/:id/logs',
26+
controller: User.getLogs,
27+
},
28+
],
29+
};

0 commit comments

Comments
 (0)