28 lines
796 B
Go
28 lines
796 B
Go
package custom_response
|
|
|
|
// Errors response
|
|
const (
|
|
AccountAlreadyExists = "Account already exists"
|
|
InternalError = "Internal Error"
|
|
InvalidCredentials = "Invalid login or password"
|
|
ReadTokenError = "Error reading token."
|
|
InvalidToken = "Invalid token."
|
|
RefreshNotFound = "AccountByRefreshToken not found"
|
|
Conflict2FA = "2FA already exists"
|
|
AccountNotFound = "Account not found"
|
|
NotVerified2FA = "2FA not verified"
|
|
NotExists2FA = "2FA does not exist"
|
|
Unauthorized = "Unauthorized"
|
|
)
|
|
|
|
// Success response
|
|
const (
|
|
SuccessRefresh = "Refresh Token Successfully."
|
|
SuccessSet2FA = "2FA set successfully."
|
|
SuccessDel2FA = "2FA deleted successfully."
|
|
)
|
|
|
|
type MessageErrorResponse struct {
|
|
Message string `json:"message"`
|
|
}
|