mirror of
https://github.com/hansjone/dsh-im-ops.git
synced 2026-10-11 13:10:49 +08:00
feat: add conversationTitle to context enhancement
Pass inbound group titles into <dsh_im_source> without extra platform API lookups. DingTalk uses conversationTitle; Telegram groups use chat.title.
This commit is contained in:
parent
13fc85cdce
commit
7a68e94f54
11 changed files with 82 additions and 30 deletions
|
|
@ -166,6 +166,7 @@ export function normalizeTelegramUpdate(update, {
|
|||
senderName: [message.from?.first_name, message.from?.last_name]
|
||||
.filter((value) => typeof value === 'string' && value.trim())
|
||||
.map((value) => value.trim()).join(' ') || message.from?.username,
|
||||
conversationTitle: direct ? undefined : message.chat?.title,
|
||||
}),
|
||||
senderIsBot: message.from?.is_bot === true,
|
||||
kind: direct ? 'direct' : 'group',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue