feat: 完善后端脚手架基础能力
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
package auth
|
||||
|
||||
type Credentials struct {
|
||||
Username string `json:"username" binding:"required,min=3,max=64" example:"demo"`
|
||||
Password string `json:"password" binding:"required,min=8,max=72" example:"change-me-123"`
|
||||
}
|
||||
|
||||
type RefreshRequest struct {
|
||||
RefreshToken string `json:"refresh_token" binding:"required"`
|
||||
}
|
||||
|
||||
type LogoutRequest struct {
|
||||
RefreshToken string `json:"refresh_token"`
|
||||
}
|
||||
|
||||
type UserResponse struct {
|
||||
ID uint `json:"id"`
|
||||
Username string `json:"username"`
|
||||
}
|
||||
Reference in New Issue
Block a user