25 lines
510 B
Go
25 lines
510 B
Go
package models
|
|
|
|
import "time"
|
|
|
|
type LoginRequest struct {
|
|
Username string `json:"username"`
|
|
Password string `json:"password"`
|
|
}
|
|
|
|
type RegistrationRequest struct {
|
|
Username string `json:"username"`
|
|
Password string `json:"password"`
|
|
Email string `json:"email"`
|
|
}
|
|
|
|
type RegistrationReply struct {
|
|
ID uint `json:"id"`
|
|
Username string `json:"username"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
}
|
|
|
|
type ErrorReply struct {
|
|
Status string `json:"status"`
|
|
Message string `json:"message"`
|
|
}
|