nimserversdk

package
v0.0.0-...-47c7083 Latest Latest
Warning

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

Go to latest
Published: Jul 1, 2018 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BASE_URL                             = "https://api.netease.im/nimserver/"
	ACTION_USER_CREATE                   = BASE_URL + "user/create.action"               // 创建云通信ID
	ACTION_USER_UPDATE                   = BASE_URL + "user/update.action"               // 更新云通信ID
	ACTION_USER_REFRESH_TOKEN            = BASE_URL + "user/refreshToken.action"         // 更新并获取token
	ACTION_USER_BLOCK                    = BASE_URL + "user/block.action"                // 封禁网易云通信ID
	ACTION_USER_UNBLOCK                  = BASE_URL + "user/unblock.action"              // 解禁网易云通信ID
	ACTION_USER_DONNOP_OPEN              = BASE_URL + "user/setDonnop.action"            // 设置桌面端在线时,移动端是否需要推送
	ACTION_USER_UPDATE_UINFO             = BASE_URL + "user/updateUinfo.action"          // 更新用户名片
	ACTION_USER_GET_UINFO                = BASE_URL + "user/getUinfos.action"            // 获取用户名片
	ACTION_USER_SET_SPECIAL_RELATION     = BASE_URL + "user/setSpecialRelation.action"   // 设置黑名单/静音
	ACTION_USER_LIST_BLACK_AND_MUTE_LIST = BASE_URL + "user/listBlackAndMuteList.action" // 查看指定用户的黑名单和静音列表

	ACTION_FRIEND_ADD    = BASE_URL + "friend/add.action"    // 加好友
	ACTION_FRIEND_UPDATE = BASE_URL + "friend/update.action" // 更新好友相关信息
	ACTION_FRIEND_DELETE = BASE_URL + "friend/delete.action" // 删除好友
	ACTION_FRIEND_GET    = BASE_URL + "friend/get.action"    // 获取好友关系

	ACTION_MSG_SNED_MSG              = BASE_URL + "msg/sendMsg.action"            // 发送普通消息
	ACTION_MSG_SNED_BATCH_MSG        = BASE_URL + "msg/sendBatchMsg.action"       // 批量发送点对点普通消息
	ACTION_MSG_SEND_ATTACH_MSG       = BASE_URL + "msg/sendAttachMsg.action"      // 发送自定义系统通知
	ACTION_MSG_SEND_BATCH_ATTACH_MSG = BASE_URL + "msg/sendBatchAttachMsg.action" // 批量发送点对点自定义系统通知
	ACTION_MSG_UPLOAD                = BASE_URL + "msg/upload.action"             // 文件上传
	ACTION_MSG_UPLOAD_MULTIPART      = BASE_URL + "msg/fileUpload.action"         // 文件上传 multipart 方式
	ACTION_MSG_RECALL                = BASE_URL + "msg/recall.action"             // 消息撤回
	ACTION_MSG_BROADCAST             = BASE_URL + "broadcastMsg.action"

	ACTION_TEAM_CREATE             = BASE_URL + "team/create.action"          // 创建群
	ACTION_TEAM_ADD                = BASE_URL + "team/add.action"             // 拉人入群
	ACTION_TEAM_KICK               = BASE_URL + "team/kick.action"            // 踢人出群
	ACTION_TEAM_REMOVE             = BASE_URL + "team/remove.action"          // 解散群
	ACTION_TEAM_UPDATE             = BASE_URL + "team/update.action"          // 编辑群资料
	ACTION_TEAM_QUERY              = BASE_URL + "team/query.action"           // 群信息与成员列表查询
	ACTION_TEAM_QUERY_DETAIL       = BASE_URL + "team/queryDetail.action"     // 获取群组详细信息
	ACTION_TEAM_GET_MARK_READ_INFO = BASE_URL + "team/getMarkReadInfo.action" // 获取群组已读消息的已读详情信息
	ACTION_TEAM_CHANGE_OWNER       = BASE_URL + "team/changeOwner.action"     // 移交群主
	ACTION_TEAM_ADD_MANAGER        = BASE_URL + "team/addManager.action"      // 任命管理员
	ACTION_TEAM_REMOVE_MANAGER     = BASE_URL + "team/removeManager.action"   // 移除管理员
	ACTION_TEAM_JOIN_TEAM          = BASE_URL + "team/joinTeams.action"       // 获取某用户所加入的群信息
	ACTION_TEAM_UPDATE_TEAM_NICK   = BASE_URL + "team/updateTeamNick.action"  // 修改群昵称
	ACTION_TEAM_MUTE               = BASE_URL + "team/muteTeam.action"        // 修改消息提醒开关
	ACTION_TEAM_MUTE_LIST          = BASE_URL + "team/muteTlist.action"       // 禁言群成员
	ACTION_TEAM_LEAVE              = BASE_URL + "team/leave.action"           // 主动退群
	ACTION_TEAM_MUTE_ALL           = BASE_URL + "team/muteTlistAll.action"    // 将群组整体禁言
	ACTION_TEAM_LIST_TEAM_MUTE     = BASE_URL + "team/listTeamMute.action"    // 获取群组禁言列表

	ACTION_CHATROOM_CREATE              = BASE_URL + "chatroom/create.action"           // 创建聊天室
	ACTION_CHATROOM_GET                 = BASE_URL + "chatroom/get.action"              // 查询聊天室信息
	ACTION_CHATROOM_GET_BATCH           = BASE_URL + "chatroom/getBatch.action"         // 批量查询聊天室信息
	ACTION_CHATROOM_UPDATE              = BASE_URL + "chatroom/update.action"           // 更新聊天室信息
	ACTION_CHATROOM_TOGGLE_CLOSE_STAT   = BASE_URL + "chatroom/toggleCloseStat.action"  // 修改聊天室开/关闭状态
	ACTION_CHATROOM_SET_MEMBER_ROLE     = BASE_URL + "chatroom/setMemberRole.action"    // 设置聊天室内用户角色
	ACTION_CHATROOM_REQUEST_ADDR        = BASE_URL + "chatroom/requestAddr.action"      // 请求聊天室地址
	ACTION_CHATROOM_SEND_MSG            = BASE_URL + "chatroom/sendMsg.action"          // 发送聊天室消息
	ACTION_CHATROOM_ADD_ROBOT           = BASE_URL + "chatroom/addRobot.action"         // 往聊天室内添加机器人
	ACTION_CHATROOM_REMOVE_ROBOT        = BASE_URL + "chatroom/removeRobot.action"      // 从聊天室内删除机器人
	ACTION_CHATROOM_TEMPORARY_MUTE      = BASE_URL + "chatroom/temporaryMute.action"    // 设置临时禁言状态
	ACTION_CHATROOM_QUEUE_OFFER         = BASE_URL + "chatroom/queueOffer.action"       // 往聊天室有序队列中新加或更新元素
	ACTION_CHATROOM_QUEUE_POLL          = BASE_URL + "chatroom/queuePoll.action"        // 从队列中取出元素
	ACTION_CHATROOM_QUEUE_LIST          = BASE_URL + "chatroom/queueList.action"        // 排序列出队列中所有元素
	ACTION_CHATROOM_QUEUE_DROP          = BASE_URL + "chatroom/queueDrop.action"        // 删除清理整个队列
	ACTION_CAHTROOM_QUEUE_INIT          = BASE_URL + "chatroom/queueInit.action"        // 初始化队列
	ACTION_CHATROOM_MUTE_ROOM           = BASE_URL + "chatroom/muteRoom.action"         // 将聊天室整体禁言
	ACTION_CHATROOM_TOPN                = BASE_URL + "chatroom/topn.action"             // 查询聊天室统计指标TopN
	ACTION_CHATROOM_MEMBERS_BY_PAGE     = BASE_URL + "chatroom/membersByPage.action"    // 分页获取成员列表
	ACTION_CHATROOM_QUERY_MEMBERS       = BASE_URL + "chatroom/queryMembers.action"     // 批量获取在线成员信息
	ACTION_CHATROOM_UPDATE_MY_ROOM_ROLE = BASE_URL + "chatroom/updateMyRoomRole.action" // 变更聊天室内的角色信息

)

Variables

This section is empty.

Functions

func ResponseResult

func ResponseResult(appkey string, appSecret string, action string, params url.Values) ([]byte, error)

ResponseResult ...

Types

type AddResult

type AddResult struct {
	BaseResp
	Faccid Exceed `json:"faccid"`
}

type AddrResult

type AddrResult struct {
	Addr []string `json:"addr"`
	BaseResp
}

type BaseResp

type BaseResp struct {
	Code int    `json:"code"`
	Desc string `json:"desc"`
}

type BatchChatroomResult

type BatchChatroomResult struct {
	BaseResp
	NoExistRooms []int64              `json:"noExistRooms"`
	FailRooms    []int64              `json:"failRooms"`
	SuccRooms    []ChatroomDetailInfo `json:"succRooms"`
}

type BlackAndMuteList

type BlackAndMuteList struct {
	BaseResp
	MuteList  []string `json:"mutelist"`
	BlackList []string `json:"blacklist"`
}

type Broadcast

type Broadcast struct {
	BaseResp
	BroadcastMsg `json:"msg"`
}

type BroadcastMsg

type BroadcastMsg struct {
	ExpireTime  int64    `json:"expireTime"`
	Body        string   `json:"body"`
	CreateTime  int64    `json:"createTime"`
	IsOffline   bool     `json:"isOffline"`
	BroadcastId int64    `json:"broadcastId"`
	TargetOs    []string `json:"targetOs"`
}

type Chatroom

type Chatroom struct {
	APPKEY    string
	APPSECRET string
}

func (*Chatroom) AddRobot

func (chatroom *Chatroom) AddRobot(roomid int64, accids string, roleExt string, notifyExt string) (*RobotResult, error)

AddRobot ...

func (*Chatroom) Create

func (chatroom *Chatroom) Create(creator string, name string, announcement string, broadcasturl string, ext string, queuelevel int) (*ChatroomResult, error)

Create ...

func (*Chatroom) Get

func (chatroom *Chatroom) Get(romid int64, needOnlineUserCount bool) (*ChatroomDetailInfoResult, error)

Get ...

func (*Chatroom) GetBatch

func (chatroom *Chatroom) GetBatch(roomids string, needOnlineUserCount bool) (*BatchChatroomResult, error)

GetBatch ...

func (*Chatroom) RemoveRobot

func (chatroom *Chatroom) RemoveRobot(roomid int64, accids string) (*RobotResult, error)

RemoveRobot ...

func (*Chatroom) RequestAddr

func (chatroom *Chatroom) RequestAddr(roomid int64, accid string, clienttype int) (*AddrResult, error)

name ...

func (*Chatroom) SendMsg

func (chatroom *Chatroom) SendMsg(roomid int64, msgId string, fromAccid string, msgType int, resendFlag int, attach string, ext string, antispam string, antispamCustom string, skipHistory int, bid string, highPriority bool, useYidun int, needHighPriorityMsgResend bool) (*ChatroomSendMsgResult, error)

SendMsg ...

func (*Chatroom) SetMemberRole

func (chatroom *Chatroom) SetMemberRole(roomid int64, operator string, target string, opt int, optvalue bool, notifyExt string) (*SetMemberResult, error)

SetMemberRole ...

func (*Chatroom) ToggleCloseStat

func (chatroom *Chatroom) ToggleCloseStat(roomid int64, operator string, valid bool) (*ToggleCloseStatResutl, error)

name ...

func (*Chatroom) Update

func (chatroom *Chatroom) Update(roomid int64, name string, announcement string, broadcasturl string, ext string, needNotify bool, notifyExt string, queuelevel int) (*ChatroomResult, error)

Update ...

type ChatroomDetailInfo

type ChatroomDetailInfo struct {
	Roomid          int    `json:"roomid"`
	Valid           bool   `json:"valid"`
	Muted           bool   `json:"muted"`
	Announcement    string `json:"announcement"`
	Name            string `json:"name"`
	Broadcasturl    string `json:"broadcasturl"`
	Onlineusercount int    `json:"onlineusercount"`
	Ext             string `json:"ext"`
	Creator         string `json:"creator"`
	Queuelevel      int    `json:"queuelevel"`
}

type ChatroomDetailInfoResult

type ChatroomDetailInfoResult struct {
	BaseResp
	ChatroomDetailInfo ChatroomDetailInfo `json:"chatroom"`
}

type ChatroomInfo

type ChatroomInfo struct {
	Roomid       int    `json:"roomid"`
	Valid        bool   `json:"valid"`
	Announcement string `json:"announcement"`
	Name         string `json:"name"`
	Broadcasturl string `json:"broadcasturl"`
	Ext          string `json:"ext"`
	Creator      string `json:"creator"`
}

type ChatroomResult

type ChatroomResult struct {
	BaseResp
	ChatroomInfo ChatroomInfo `json:"chatroom"`
}

type ChatroomSendMsgResult

type ChatroomSendMsgResult struct {
	BaseResp
	Desc SendMsgResult `json:"desc"`
}

type CreateResult

type CreateResult struct {
	BaseResp
	Tid    string `json:"tid"`
	Faccid Exceed `json:"faccid"`
}

type Data

type Data struct {
	MsgId    string `json:"msgid"`
	Antispam bool   `json:"antispam"`
}

type Exceed

type Exceed struct {
	Accid []string `json:"accid"`
	Msg   string   `json:"msg"`
}

type Friend

type Friend struct {
	APPKEY    string
	APPSECRET string
}

func (*Friend) AddFriend

func (this *Friend) AddFriend(accid string, faccid string, friendType int, msg string) (*BaseResp, error)

AddFriend ...

func (*Friend) DeleeteFriend

func (this *Friend) DeleeteFriend(accid, faccid string) (*BaseResp, error)

DeleeteFriend ...

func (*Friend) GetFriendList

func (this *Friend) GetFriendList(accid string, updateTime int64) (*FriendInfoResponse, error)

GetFriendList ...

func (*Friend) ListBlackAndMuteList

func (this *Friend) ListBlackAndMuteList(accid string) (*BlackAndMuteList, error)

ListBlackAndMuteList ...

func (*Friend) SetSpecialRelation

func (this *Friend) SetSpecialRelation(accid string, targetAcc string, relationType int, value int) (*BaseResp, error)

SetSpecialRelation ...

func (*Friend) UpdateFriend

func (this *Friend) UpdateFriend(accid, faccid, alias, ex string) (*BaseResp, error)

UpdateFriend ...

type FriendInfo

type FriendInfo struct {
	CreateTime  int64  `json:"createtime"`
	Bidirection bool   `json:"bidirection"`
	Faccid      string `json:"faccid"`
	Alias       string `json:"alias"`
}

type FriendInfoResponse

type FriendInfoResponse struct {
	BaseResp
	Size    int          `json:"size"`
	Friends []FriendInfo `json:"friends"`
}

type Info

type Info struct {
	Accid  string `json:"accid"`
	Name   string `json:"name"`
	Email  string `json:"email"`
	Gender int    `json:"gender"`
	Mobile string `json:"mobile"`
}

type JoinTeamResult

type JoinTeamResult struct {
	BaseResp
	Count int        `json:"count"`
	Infos []TeamInfo `json:"infos"`
}

type Msg

type Msg struct {
	APPKEY    string
	APPSECRET string
}

func (*Msg) Broadcast

func (msg *Msg) Broadcast(body string, from string, isOffline bool, ttl int, targetOs string) (*Broadcast, error)

Broadcast ...

func (*Msg) Recall

func (msg *Msg) Recall(deleteMsgid string, timetag string, msgType int, from, to, msgDesc, ignoreTime string) (*BaseResp, error)

MsgRecall ...

func (*Msg) SendAttachMsg

func (msg *Msg) SendAttachMsg(from string, msgType int, to string, attach string, pushcontent string, payload string, sound string, save int, option string) (*BaseResp, error)

SendAttachMsg ...

func (*Msg) SendBatchAttachMsg

func (msg *Msg) SendBatchAttachMsg(fromAccid string, toAccids string, attach string, pushcontent string, payload string, sound string, save int, option string) (*SendResult, error)

SendBatchAttachMsg ...

func (*Msg) SendBatchMsg

func (msg *Msg) SendBatchMsg(fromAccid string, toAccids string, msgType int, body string, option string, pushcontent string, payload string, ext string, bid string, useYidun int) (*SendResult, error)

SendBatchMsg ...

func (*Msg) SendMsg

func (msg *Msg) SendMsg(from string, ope int, to string, msgType int, body string, antispam bool, antispamCustom string, option string, pushcontent string, payload string, ext string, forcepushlist string, forcepushcontent string, forcepushall string, bid string, useYidun int, markRead int) (*SendResult, error)

SendMsg ...

func (*Msg) Upload

func (msg *Msg) Upload(content []byte, fileType string, isHttps bool) (*UploadResult, error)

MsgUpload ...

func (*Msg) UploadByMultiPart

func (msg *Msg) UploadByMultiPart(content []byte, fileType string, isHttps bool) (*UploadResult, error)

MsgUpload ...

type Mute

type Mute struct {
	Nick  string `json:"nick"`
	Accid string `json:"accid"`
	Tid   string `json:"tid"`
	Type  int    `json:"type"`
}

type MuteResult

type MuteResult struct {
	BaseResp
	Mutes []Mute `json:"mutes"`
}

type Nim

type Nim struct {
	APPKEY    string
	APPSECRET string
	User      User
	Friend    Friend
	Msg       Msg
	Team      Team
}

func NewNim

func NewNim(appkey, appsecret string) *Nim

New ...

type QueryDetailResult

type QueryDetailResult struct {
	BaseResp
	TDetailInfo `json:"tinfo"`
}

type QueryResult

type QueryResult struct {
	BaseResp
	Tinfos []Tinfo `json:"tinfos"`
}

type ReadInfo

type ReadInfo struct {
	ReadSize     int      `json:"readSize"`
	UnreadSize   int      `json:"unreadSize"`
	Readaccids   []string `json:"readAccids"`
	UnreadAccids []string `json:"unreadAccids"`
}

type ReadInfoResult

type ReadInfoResult struct {
	BaseResp
	Data ReadInfo `json:"data"`
}

type RobotDesc

type RobotDesc struct {
	FailAccids    string `json:"failAccids"`
	SuccessAccids string `json:"successAccids"`
	OldAccids     string `json:"oldAccids"`
}

type RobotResult

type RobotResult struct {
	BaseResp
	RobotDesc `json:"desc"`
}

type SendBatchResutl

type SendBatchResutl struct {
	BaseResp
	UnRegister []string `json:"unregister"`
}

type SendMsgResult

type SendMsgResult struct {
	Time             string `json:"time"`
	FromAvator       string `json:"fromAvator"`
	Msgid_client     string `json:"msgid_client"`
	FromClientType   string `json:"fromClientType"`
	Attach           string `json:"attach"`
	RoomId           string `json:"roomId"`
	FromAccount      string `json:"fromAccount"`
	FromNick         string `json:"fromNick"`
	Type             string `json:"type"`
	Ext              string `json:"ext"`
	HighPriorityFlag int    `json:"highPriorityFlag"`
}

type SendResult

type SendResult struct {
	BaseResp
	Data Data `json:"data"`
}

type SetMember

type SetMember struct {
	Roomid int64  `json:"roomid"`
	Level  int    `json:"level"`
	Accid  string `json:"accid"`
	Type   string `json:"type"`
}

type SetMemberResult

type SetMemberResult struct {
	SetMember SetMember `json:"desc"`
	BaseResp
}

type TDetailInfo

type TDetailInfo struct {
	Icon         string       `json:"icon"`
	Announcement string       `json:"announcement"`
	Uptinfomode  int          `json:"uptinfomode"`
	Maxusers     int          `json:"maxusers"`
	Intro        string       `json:"intro"`
	Upcustommode int          `json:"upcustommode"`
	Tname        string       `json:"tname"`
	Beinvitemode int          `json:"beinvitemode"`
	Joinmode     int          `json:"joinmode"`
	Tid          int          `json:"tid"`
	Invitemode   int          `json:"invitemode"`
	Mute         bool         `json:"mute"`
	Custom       string       `json:"custom"`
	ClientCustom string       `json:"clientCustom"`
	Createtime   int64        `json:"createtime"`
	Updatetime   int64        `json:"updatetime"`
	Owner        TeamMember   `json:"owner"`
	Admins       []TeamMember `json:"admins"`
	Members      []TeamMember `json:"members"`
}

type Team

type Team struct {
	APPKEY    string
	APPSECRET string
}

func (*Team) Add

func (team *Team) Add(tid string, owner string, members string, magree int, msg string, attach string) (*AddResult, error)

Add ...

func (*Team) AddManager

func (team *Team) AddManager(tid, owner, members string) (*BaseResp, error)

AddManager ...

func (*Team) ChangetOwner

func (team *Team) ChangetOwner(tid string, owner string, newowner string, leave int) (*BaseResp, error)

ChangetOwner ...

func (*Team) Create

func (team *Team) Create(tname string, owner string, members string, announcement string, intro string, msg string, magree int, joinmode int, custom string, icon string, beinvitemode int, invitemode int, uptinfomode int, upcustommode int) (*CreateResult, error)

Create ...

func (*Team) GetMarkReadInfo

func (team *Team) GetMarkReadInfo(tid int64, msgId int64, fromAccid string, snapshot bool) (*ReadInfoResult, error)

GetMarkReadInfo ...

func (*Team) JoinTeams

func (team *Team) JoinTeams(accid string) (*TeamInfo, error)

JoinTeams ...

func (*Team) Kick

func (team *Team) Kick(tid, owner, member, members, attach string) (*BaseResp, error)

Kick ...

func (*Team) Leave

func (team *Team) Leave(tid, accid string) (*BaseResp, error)

Leave ...

func (*Team) ListTeamMute

func (team *Team) ListTeamMute(tid, owner string) (*MuteResult, error)

ListTeamMute ...

func (*Team) MuteTeam

func (team *Team) MuteTeam(tid string, accid string, ope int) (*BaseResp, error)

MuteTeam ...

func (*Team) MuteTeamList

func (team *Team) MuteTeamList(tid string, owner string, accid string, mute int) (*BaseResp, error)

MuteTeamList ...

func (*Team) MuteTeamListAll

func (team *Team) MuteTeamListAll(tid string, owner string, mute bool, muteType int) (*BaseResp, error)

MuteTeamListAll ...

func (*Team) Query

func (team *Team) Query(tids string, ope int) (*QueryResult, error)

Query ...

func (*Team) QueryDetail

func (team *Team) QueryDetail(tid int64) (*TDetailInfo, error)

QueryDetail ...

func (*Team) Remove

func (team *Team) Remove(tid, owner string) (*BaseResp, error)

Remove ...

func (*Team) RemoveManager

func (team *Team) RemoveManager(tid, owner, members string) (*BaseResp, error)

RemoveManager ...

func (*Team) Update

func (team *Team) Update(tid string, tname string, owner string, announcement string, intro string, joinmode int, custom string, icon string, beinvitemode, invitemode, uptinfomode, upcustommode int) (*BaseResp, error)

Update ...

func (*Team) UpdateTeamNick

func (team *Team) UpdateTeamNick(tid, owner, accid, nick, custom string) (*BaseResp, error)

UpdateTeamNick ...

type TeamInfo

type TeamInfo struct {
	Owner    string `json:"owner"`
	Tname    string `json:"tname"`
	MaxUsers int    `json:"maxusers"`
	Tid      int    `json:"tid"`
	Size     int    `json:"size"`
	Custom   string `json:"custom"`
}

type TeamMember

type TeamMember struct {
	Createtime int64  `json:"createtime"`
	Updatetime int64  `json:"updatetime"`
	Nick       string `json:"nick"`
	Accid      string `json:"accid"`
	Mute       bool   `json:"mute"`
	Custom     string `json:"custom"`
}

type Tinfo

type Tinfo struct {
	Tname        string   `json:"tname"`
	Announcement string   `json:"announcement"`
	Owner        string   `json:"owner"`
	Maxusers     int      `json:"maxusers"`
	Joinmode     int      `json:"joinmode"`
	Tid          int      `json:"tid"`
	Intro        string   `json:"intro"`
	Size         int      `json:"size"`
	Custom       string   `json:"custom"`
	ClientCustom string   `json:"clientCustom"`
	Mute         bool     `json:"mute"`
	Createtime   int64    `json:"createtime"`
	Updatetime   int64    `json:"updatetime"`
	Admins       []string `json:"admins"`
	Members      []string `json:"members"`
}

type ToggleCloseStatResutl

type ToggleCloseStatResutl struct {
	BaseResp
	ChatroomInfo ChatroomInfo `json:"desc"`
}

type TokenInfo

type TokenInfo struct {
	Token string `json:"token"`
	Accid string `json:"accid"`
}

type TokenRespose

type TokenRespose struct {
	BaseResp
	TokenInfo TokenInfo `json:"info"`
}

type Uinfos

type Uinfos struct {
	BaseResp
	Uinfos []Info `json:"uinfos"`
}

type UploadResult

type UploadResult struct {
	BaseResp
	Url string `json:"url"`
}

type User

type User struct {
	APPKEY    string
	APPSECRET string
}

func (*User) Block

func (this *User) Block(accid string) (*BaseResp, error)

Block ...

func (*User) Create

func (this *User) Create(accid string) (*TokenRespose, error)

Create ...

func (*User) GetUinfo

func (this *User) GetUinfo(accids []string) (*Uinfos, error)

GetUinfo ...

func (*User) RefreshToken

func (this *User) RefreshToken(accid string) (*TokenRespose, error)

RefreshToken ...

func (*User) SetDonnop

func (this *User) SetDonnop(accid string, donnopOpen bool) (*BaseResp, error)

SetDonnop ...

func (*User) UnBlock

func (this *User) UnBlock(accid string) (*BaseResp, error)

UnBlock ...

func (*User) Update

func (this *User) Update(accid, props, token string) (*BaseResp, error)

Update ...

func (*User) UpdateUinfo

func (this *User) UpdateUinfo(gender int, accid, name, icon, sign, email, birth, mobile, ex string) (*BaseResp, error)

UpdateUinfo ...

Jump to

Keyboard shortcuts

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