user

package
v0.4.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 13, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package user for User Management

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type QueryUserInfoRequest

type QueryUserInfoRequest struct {
	UID string `url:"-" validate:"required" json:"-"` // user id
}

QueryUserInfoRequest for get user information

func (*QueryUserInfoRequest) Body

func (s *QueryUserInfoRequest) Body() interface{}

func (*QueryUserInfoRequest) Method

func (s *QueryUserInfoRequest) Method() string

Method for Request.Method()

func (*QueryUserInfoRequest) URL

func (s *QueryUserInfoRequest) URL() string

URL for Request.URL()

type QueryUserInfoResponse

type QueryUserInfoResponse struct {
	CountryCode string `json:"country_code"` // country code
	Avatar      string `json:"avatar"`       // avatar
	Mobile      string `json:"mobile"`       // mobile
	NickName    string `json:"nick_name"`    // nick name
	UID         string `json:"uid"`          // user id
	Username    string `json:"username"`     // username
	CreateTime  int64  `json:"create_time"`  // create_time
	UpdateTime  int64  `json:"update_time"`  // update_time
}

type QueryUserListRequest

type QueryUserListRequest struct {
	Schema   string `url:"-" validate:"required" json:"-"`         // App schema
	PageNo   int    `url:"page_no" validate:"required" json:"-"`   // Page no
	PageSize int    `url:"page_size" validate:"required" json:"-"` // Page size, value range (0, 100]
}

QueryUserListRequest query user list

func (*QueryUserListRequest) Body

func (s *QueryUserListRequest) Body() interface{}

func (*QueryUserListRequest) Method

func (s *QueryUserListRequest) Method() string

Method for Request.Method()

func (*QueryUserListRequest) URL

func (s *QueryUserListRequest) URL() string

URL for Request.URL()

type QueryUserListResponse

type QueryUserListResponse struct {
	HasMore bool       `json:"has_more"`
	List    []UserInfo `json:"list"`
}

type SyncUserInfoRequest

type SyncUserInfoRequest struct {
	Schema       string `url:"-" validate:"required" json:"-"`             // application unique identifier
	CountryCode  string `url:"-" validate:"required" json:"country_code"`  // Country code
	Username     string `url:"-" validate:"required" json:"username"`      // Username
	Password     string `url:"-" validate:"required" json:"password"`      // Password.It is recommended to use the MD5 hash original password.
	UsernameType int    `url:"-" validate:"required" json:"username_type"` // User name type,1:mobile,2:email,3:open id, default:3
	NickName     string `url:"-" json:"nick_name,omitempty"`               // nickname
}

SyncUserInfoRequest sync user info

func (*SyncUserInfoRequest) Body

func (s *SyncUserInfoRequest) Body() interface{}

func (*SyncUserInfoRequest) Method

func (s *SyncUserInfoRequest) Method() string

Method for Request.Method()

func (*SyncUserInfoRequest) URL

func (s *SyncUserInfoRequest) URL() string

URL for Request.URL()

type SyncUserInfoResponse

type SyncUserInfoResponse struct {
	UID string `json:"uid"` // tuya user id
}

type UserInfo

type UserInfo struct {
	CountryCode string `json:"country_code"`
	UID         string `json:"uid"`
	Username    string `json:"username"`
	Mobile      string `json:"mobile"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL