feat: msg emoji like

This commit is contained in:
linyuchen
2024-04-25 23:25:38 +08:00
parent 3ae2d2a1e6
commit b7855e91f6
2 changed files with 32 additions and 0 deletions

View File

@@ -16,6 +16,17 @@ export interface Peer {
}
export class NTQQMsgApi {
static async setEmojiLike(peer: Peer, msgSeq: string, emojiId: string, set: boolean=true){
// nt_qq//global//nt_data//Emoji//emoji-resource//sysface_res/apng/ 下可以看到所有QQ表情预览
// nt_qq\global\nt_data\Emoji\emoji-resource\face_config.json 里面有所有表情的id, 自带表情id是QSid, 标准emoji表情id是QCid
// 其实以官方文档为准是最好的https://bot.q.qq.com/wiki/develop/api-v2/openapi/emoji/model.html#EmojiType
return await callNTQQApi<GeneralCallResult>({
methodName: NTQQApiMethod.EMOJI_LIKE,
args: [{
peer, msgSeq, emojiId, emojiType: emojiId.length > 3 ? "2" : "1", setEmoji: set
}, null]
})
}
static async getMultiMsg(peer: Peer, rootMsgId: string, parentMsgId: string) {
return await callNTQQApi<GeneralCallResult & {msgList: RawMessage[]}>({
methodName: NTQQApiMethod.GET_MULTI_MSG,