request

package
v0.0.0-...-b89eba7 Latest Latest
Warning

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

Go to latest
Published: Sep 26, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AcceptApplication

type AcceptApplication struct {
	AccountID int64 `json:"account_id" binding:"required,gte=1"` // 目标账号ID
}

type CreateAccount

type CreateAccount struct {
	Name      string `json:"name" binding:"required,gte=1,lte=20"`       // 名称
	Gender    string `json:"gender" binding:"required,oneof=男 女 未知"`     // 性别
	Signature string `json:"signature" binding:"required,gte=0,lte=100"` // 签名
}

type CreateApplication

type CreateApplication struct {
	AccountID int64  `json:"account_id" binding:"required,gte=1"`  // 目标账号ID
	ApplyMsg  string `json:"apply_msg" binding:"required,lte=200"` // 申请信息
}

type CreateFileMsg

type CreateFileMsg struct {
	RelationID int64                 `form:"relation_id" binding:"required,gte=1"` // 关系ID
	File       *multipart.FileHeader `form:"file" binding:"required"`              // 文件
	RlyMsgID   int64                 `form:"rly_msg_id"`                           // 回复消息ID
}

type CreateGroup

type CreateGroup struct {
	Name        string `json:"name" form:"name" binding:"required"`
	Description string `json:"description" form:"description" binding:"required"`
}

type CreateNotify

type CreateNotify struct {
	RelationID int64            `json:"relation_id" form:"relation_id" binding:"required"`
	MsgContent string           `json:"msg_content" form:"msg_content" binding:"required"`
	MsgExtend  *model.MsgExtend `json:"msg_expand"  form:"msg_expand"`
}

type DeleteAccount

type DeleteAccount struct {
	AccountID int64 `json:"account_id" binding:"required,gte=1"` // 账号ID
}

type DeleteApplication

type DeleteApplication struct {
	AccountID int64 `json:"account_id" binding:"required,gte=1"` // 目标账号ID
}

type DeleteFile

type DeleteFile struct {
	FileID int64 `json:"file_id" form:"file_id" binding:"required"`
}

type DeleteFriend

type DeleteFriend struct {
	RelationID int64 `json:"relation_id" binding:"required,gte=1"` // 关系ID
}

type DeleteNotify

type DeleteNotify struct {
	ID         int64 `json:"id" form:"id" binding:"required"`
	RelationID int64 `json:"relation_id" form:"relation_id" binding:"required"`
}

type DissolveGroup

type DissolveGroup struct {
	RelationID int64 `json:"relation_id" form:"relation_id" binding:"required"`
}

type ExistEmail

type ExistEmail struct {
	Email string `form:"email" binding:"required,email,lte=50" maximum:"50"` // 邮箱
}

type FeedMsgsByAccountIDAndTime

type FeedMsgsByAccountIDAndTime struct {
	LastTime int32 `form:"last_time" binding:"required,gte=1"` // 拉取消息的最晚时间戳(精确到秒)
	common.Pager
}

type GetAccountByID

type GetAccountByID struct {
	AccountID int64 `json:"account_id" form:"account_id" binding:"required,gte=1"` // 账号ID
}

type GetAccountToken

type GetAccountToken struct {
	AccountID int64 `json:"account_id" form:"account_id" binding:"required,gte=1"` // 账号ID
}

type GetAccountsByName

type GetAccountsByName struct {
	Name string `json:"name" form:"name" binding:"required,gte=1,lte=20"` // 搜索名称
	common.Pager
}

type GetFile

type GetFile struct {
	FileID int64 `json:"file_id" form:"file_id" binding:"required"`
}

type GetFriendsByName

type GetFriendsByName struct {
	Name string `form:"name" binding:"required,gte=1,lte=20"` // 查询名称
	common.Pager
}

type GetGroupByName

type GetGroupByName struct {
	Name string `json:"name" form:"name" binding:"required"`
	common.Pager
}

type GetGroupMembers

type GetGroupMembers struct {
	RelationID int64 `json:"relation_id" form:"relation_id" binding:"required"`
}

type GetMsgsByContent

type GetMsgsByContent struct {
	Content    string `form:"content" binding:"required"` // 需要查询的内容
	RelationID int64  `form:"relation_id"`                // 关系ID
	common.Pager
}

type GetMsgsByRelationIDAndTime

type GetMsgsByRelationIDAndTime struct {
	RelationID int64 `form:"relation_id" binding:"required,gte=1"` // 关系ID
	LastTime   int32 `form:"last_time" binding:"required,gte=1"`   // 拉取消息的最晚时间戳(精确到秒)
	common.Pager
}

type GetNotifyByID

type GetNotifyByID struct {
	RelationID int64 `json:"relation_id" form:"relation_id" binding:"required"`
}

type GetPinMsgsByRelationID

type GetPinMsgsByRelationID struct {
	RelationID int64 `form:"relation_id" binding:"required,gte=1"` // 关系ID
	common.Pager
}

type GetRelationFile

type GetRelationFile struct {
	RelationID int64 `json:"relation_id"  form:"relation_id" binding:"required"`
}

type GetRlyMsgsInfoByMsgID

type GetRlyMsgsInfoByMsgID struct {
	RelationID int64 `form:"relation_id" binding:"required,gte=1"` // 关系ID
	RlyMsgID   int64 `from:"rly_msg_id" binding:"required,gte=1"`  // 回复消息ID
	common.Pager
}

type GetTopMsgByRelationID

type GetTopMsgByRelationID struct {
	RelationID int64 `form:"relation_id" binding:"required,gte=1"` // 关系ID
}

type InviteAccount

type InviteAccount struct {
	AccountID  []int64 `json:"account_id,omitempty" form:"account_id" binding:"required"`
	RelationID int64   `json:"relation_id,omitempty" form:"relation_id" binding:"required"`
}

type ListApplications

type ListApplications struct {
	common.Pager
}

type Login

type Login struct {
	Email    string `json:"email" binding:"required,email,lte=50" maximum:"50"`                // 邮箱
	Password string `json:"password" binding:"required,gte=6,lte=50" minimum:"6" maximum:"50"` // 密码
}

type PublishFile

type PublishFile struct {
	File       *multipart.FileHeader `form:"file"  binding:"required" swaggerignore:"true"`
	RelationID int64                 `form:"relation_id"  binding:"required"`
	AccountID  int64                 `form:"account_id"  binding:"required"`
}

type QuitGroup

type QuitGroup struct {
	AccountID  int64 `json:"account_id,omitempty" form:"account_id" binding:"required"`
	RelationID int64 `json:"relation_id,omitempty" form:"relation_id" binding:"required"`
}

type RefuseApplication

type RefuseApplication struct {
	AccountID int64  `json:"account_id" binding:"required,gte=1"`   // 目标账号ID
	RefuseMsg string `json:"refuse_msg" binding:"required,lte=200"` // 拒绝信息
}

type Register

type Register struct {
	Email    string `json:"email" binding:"required,email,lte=50" maximum:"50"`                // 邮箱
	Password string `json:"password" binding:"required,gte=6,lte=50" minimum:"6" maximum:"50"` // 密码
	Code     string `json:"code" binding:"required,gte=6,lte=6" minimum:"6" maximum:"6"`       // 验证码
}

type RevokeMsg

type RevokeMsg struct {
	ID int64 `json:"id" binding:"required"` // 消息ID
}

type SendEmail

type SendEmail struct {
	Email string `json:"email" binding:"required,email,lte=50" maximum:"50"` // 邮箱
}

type TransferGroup

type TransferGroup struct {
	RelationID  int64 `json:"relation_id" form:"relation_id" binding:"required"`
	ToAccountID int64 `json:"to_account_id" form:"to_account_id" binding:"required"`
}

type UpdateAccount

type UpdateAccount struct {
	Name      string `json:"name" binding:"required,gte=1,lte=20"`       // 名称
	Gender    string `json:"gender" binding:"required,oneof=男 女 未知"`     // 性别
	Signature string `json:"signature" binding:"required,gte=1,lte=200"` // 个性签名
}

type UpdateGroup

type UpdateGroup struct {
	RelationID  int64  `json:"relation_id" form:"relation_id" binding:"required"`
	Name        string `json:"name" form:"name" binding:"required"`
	Description string `json:"description" form:"description" binding:"required"`
}

type UpdateMsgPin

type UpdateMsgPin struct {
	ID         int64 `json:"id" binding:"required,gte=1"`          // 消息ID
	RelationID int64 `json:"relation_id" binding:"required,gte=1"` // 关系ID
	IsPin      *bool `json:"is_pin" binding:"required"`            // 是否pin
}

type UpdateMsgRevoke

type UpdateMsgRevoke struct {
	ID       int64 `json:"id" binding:"required,gte=1"`  // 消息ID
	IsRevoke *bool `json:"is_revoke" binding:"required"` // 是否撤回
}

type UpdateMsgTop

type UpdateMsgTop struct {
	ID         int64 `json:"id" binding:"required,gte=1"`          // 消息ID
	RelationID int64 `json:"relation_id" binding:"required,gte=1"` // 关系ID
	IsTop      *bool `json:"is_top" binding:"required"`            // 是否置顶
}

type UpdateNickName

type UpdateNickName struct {
	RelationID int64  `json:"relation_id" binding:"required,gte=1"`      // 关系ID
	NickName   string `json:"nick_name" binding:"required,gte=1,lte=20"` // 昵称
}

type UpdateNotify

type UpdateNotify struct {
	ID         int64            `json:"id" form:"id" binding:"required"`
	RelationID int64            `json:"relation_id" form:"relation_id" binding:"required"`
	MsgContent string           `json:"msg_content" form:"msg_content" binding:"required"`
	MsgExtend  *model.MsgExtend ` json:"msg_expand"  form:"msg_expand"`
}

type UpdateSettingDisturb

type UpdateSettingDisturb struct {
	RelationID   int64 `json:"relation_id" binding:"required,gte=1"` // 关系ID
	IsNotDisturb *bool `json:"is_not_disturb" binding:"required"`    // 是否免打扰
}

type UpdateSettingPin

type UpdateSettingPin struct {
	RelationID int64 `json:"relation_id" binding:"required,gte=1"` // 关系ID
	IsPin      *bool `json:"is_pin" binding:"required"`            // 是否pin
}

type UpdateSettingShow

type UpdateSettingShow struct {
	RelationID int64 `json:"relation_id" binding:"required,gte=1"` // 关系ID
	IsShow     *bool `json:"is_show" binding:"required"`           // 是否展示
}

type UpdateUserEmail

type UpdateUserEmail struct {
	Email string `json:"email" binding:"required,email,lte=50" maximum:"50"`          // 邮箱
	Code  string `json:"code" binding:"required,gte=6,lte=6" minimum:"6" maximum:"6"` // 验证码
}

type UpdateUserPassword

type UpdateUserPassword struct {
	Code        string `json:"code" binding:"required,gte=6,lte=6" minimum:"6" maximum:"6"`           // 验证码
	NewPassword string `json:"new_password" binding:"required,gte=6,lte=50" minimum:"6" maximum:"50"` // 新密码
}

type UploadAvatar

type UploadAvatar struct {
	File       *multipart.FileHeader `form:"file"  binding:"required" swaggerignore:"true"`
	RelationID int64                 `form:"relation_id"`
}

Jump to

Keyboard shortcuts

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