backend/app/routing/routers/api/v1/auth.routes.js

29 lines
652 B
JavaScript
Raw Normal View History

module.exports = exports = {
prefix: '/api/v1/auth',
middleware: [],
get: {
'/user-info': [
'middleware::auth:GuestOnly',
'controller::api:v1:Auth.get_user_info',
],
},
post: {
'/attempt': [
'middleware::auth:GuestOnly',
'controller::api:v1:Auth.attempt_authentication',
],
'/end-session': [
'middleware::auth:UserOnly',
'controller::api:v1:Auth.end_session',
],
'/register': [
'middleware::auth:GuestOnly',
'controller::api:v1:Auth.attempt_registration',
],
},
}