Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrZeroAmount = errors.New("amount can't be zero") ErrEmptyAction = errors.New("you should pass an action") )
View Source
var ErrEmptyUpdateUserRequest = errors.New("you must pass at least one field")
View Source
var ErrInvalidEmail = errors.New("invalid email")
Functions ¶
This section is empty.
Types ¶
type ChangeBTCBalanceRequest ¶
type ChangeUSDBalanceRequest ¶
type CreateUserRequest ¶
type UpdateUserRequest ¶
type UserHTTPHandlers ¶
type UserHTTPHandlers struct {
// contains filtered or unexported fields
}
func NewUserHTTPHandlers ¶
func NewUserHTTPHandlers(userService *service.UserService) *UserHTTPHandlers
func (*UserHTTPHandlers) SetRoutes ¶
func (h *UserHTTPHandlers) SetRoutes(r chi.Router)
type UserResponse ¶
type UserResponse struct { ID uint64 `json:"id"` Name string `json:"name"` Username string `json:"username"` Email string `json:"email"` BTCBalance *big.Float `json:"btc_balance"` USDBalance *big.Float `json:"usd_balance"` CreatedAt string `json:"created_at"` UpdatedAt string `json:"updated_at"` }
func UserToResponse ¶
func UserToResponse(user *userEntity.User) *UserResponse
Click to show internal directories.
Click to hide internal directories.