Files
warehouse-management-BE/internal/models/responses/auth_response.go

28 lines
736 B
Go

package responses
type BodyRegisterResponse struct {
ID string `json:"id"`
}
type BodyLoginResponse struct {
Token string `json:"token"`
}
// RoleItem represents a role assigned to the user in the profile response.
type RoleItem struct {
ID string `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
}
// BodyProfileResponse is the response body for GET /profile.
type BodyProfileResponse struct {
ID string `json:"id"`
Username string `json:"username"`
Email string `json:"email"`
FullName string `json:"fullName"`
IsActive bool `json:"isActive"`
Roles []RoleItem `json:"roles"`
Permissions []string `json:"permissions"`
}