Skip to content
This repository has been archived by the owner on Nov 20, 2019. It is now read-only.

Commit

Permalink
feat: 增加syncMsg接口,用于手动触发同步消息
Browse files Browse the repository at this point in the history
  • Loading branch information
binsee committed Jun 4, 2018
1 parent 3e91768 commit 2c0d488
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,19 @@ class Padchat extends EventEmitter {
return await this.sendCmd('getMyInfo')
}

/**
* 同步消息
*
* 使用此接口手动触发同步消息,一般用于刚登陆后调用,可立即开始同步消息。
* 否则会在有新消息时才开始同步消息。
*
* @returns {Promise<object>} 返回Promise<object>,注意捕捉catch
* @memberof Padchat
*/
async syncMsg() {
return await this.sendCmd('syncMsg')
}

/**
* 同步通讯录
*
Expand Down

0 comments on commit 2c0d488

Please sign in to comment.