feat: initialized auth controller
This commit is contained in:
@@ -15,6 +15,96 @@ const docTemplate = `{
|
||||
"host": "{{.Host}}",
|
||||
"basePath": "{{.BasePath}}",
|
||||
"paths": {
|
||||
"/auth/login": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Acquire tokens via login credentials or by providing 2FA code",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/passwordResetBegin": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Request password reset email",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/passwordResetComplete": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Complete password reset with email code and provide 2FA code or backup code if needed",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/refresh": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Receive new tokens via refresh token",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/registrationBegin": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Register an account",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/registrationComplete": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Confirm with code, finish creating the account",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/service/health": {
|
||||
"get": {
|
||||
"description": "Used internally for checking service health",
|
||||
|
||||
@@ -4,6 +4,96 @@
|
||||
"contact": {}
|
||||
},
|
||||
"paths": {
|
||||
"/auth/login": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Acquire tokens via login credentials or by providing 2FA code",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/passwordResetBegin": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Request password reset email",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/passwordResetComplete": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Complete password reset with email code and provide 2FA code or backup code if needed",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/refresh": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Receive new tokens via refresh token",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/registrationBegin": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Register an account",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/auth/registrationComplete": {
|
||||
"post": {
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"Auth"
|
||||
],
|
||||
"summary": "Confirm with code, finish creating the account",
|
||||
"responses": {}
|
||||
}
|
||||
},
|
||||
"/service/health": {
|
||||
"get": {
|
||||
"description": "Used internally for checking service health",
|
||||
|
||||
@@ -7,6 +7,67 @@ definitions:
|
||||
info:
|
||||
contact: {}
|
||||
paths:
|
||||
/auth/login:
|
||||
post:
|
||||
consumes:
|
||||
- application/json
|
||||
produces:
|
||||
- application/json
|
||||
responses: {}
|
||||
summary: Acquire tokens via login credentials or by providing 2FA code
|
||||
tags:
|
||||
- Auth
|
||||
/auth/passwordResetBegin:
|
||||
post:
|
||||
consumes:
|
||||
- application/json
|
||||
produces:
|
||||
- application/json
|
||||
responses: {}
|
||||
summary: Request password reset email
|
||||
tags:
|
||||
- Auth
|
||||
/auth/passwordResetComplete:
|
||||
post:
|
||||
consumes:
|
||||
- application/json
|
||||
produces:
|
||||
- application/json
|
||||
responses: {}
|
||||
summary: Complete password reset with email code and provide 2FA code or backup
|
||||
code if needed
|
||||
tags:
|
||||
- Auth
|
||||
/auth/refresh:
|
||||
post:
|
||||
consumes:
|
||||
- application/json
|
||||
produces:
|
||||
- application/json
|
||||
responses: {}
|
||||
summary: Receive new tokens via refresh token
|
||||
tags:
|
||||
- Auth
|
||||
/auth/registrationBegin:
|
||||
post:
|
||||
consumes:
|
||||
- application/json
|
||||
produces:
|
||||
- application/json
|
||||
responses: {}
|
||||
summary: Register an account
|
||||
tags:
|
||||
- Auth
|
||||
/auth/registrationComplete:
|
||||
post:
|
||||
consumes:
|
||||
- application/json
|
||||
produces:
|
||||
- application/json
|
||||
responses: {}
|
||||
summary: Confirm with code, finish creating the account
|
||||
tags:
|
||||
- Auth
|
||||
/service/health:
|
||||
get:
|
||||
consumes:
|
||||
|
||||
Reference in New Issue
Block a user