mirror of
https://github.com/versia-pub/versia-go.git
synced 2025-12-06 06:28:18 +01:00
18 lines
387 B
Go
18 lines
387 B
Go
package api_schema
|
|
|
|
import (
|
|
"github.com/google/uuid"
|
|
)
|
|
|
|
type User struct {
|
|
ID uuid.UUID `json:"id,string"`
|
|
Username string `json:"username"`
|
|
}
|
|
|
|
type FetchUserResponse = APIResponse[User]
|
|
|
|
type CreateUserRequest struct {
|
|
Username string `json:"username" validate:"required,username_regex,min=3,max=32"`
|
|
Password string `json:"password" validate:"required,min=8,max=256"`
|
|
}
|