mirror of
https://github.com/hansjone/dsh-im-ops.git
synced 2026-10-10 22:03:18 +08:00
Add Telegram and Discord IM channels
This commit is contained in:
parent
7123fce47a
commit
cb74e1c4c7
66 changed files with 8579 additions and 1910 deletions
16
src/channels/telegram/telegram-controller.mjs
Normal file
16
src/channels/telegram/telegram-controller.mjs
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
import { TokenBotController } from '../shared/token-bot-controller.mjs';
|
||||
import { deriveTelegramBotIdentity, maskTelegramBotId } from './config-store.mjs';
|
||||
import { inspectTelegramToken } from './telegram-api.mjs';
|
||||
import { TELEGRAM_DESCRIPTOR } from './telegram-bridge.mjs';
|
||||
|
||||
export class TelegramController extends TokenBotController {
|
||||
constructor(options) {
|
||||
super({
|
||||
...options,
|
||||
descriptor: TELEGRAM_DESCRIPTOR,
|
||||
inspectToken: options.inspectToken ?? inspectTelegramToken,
|
||||
deriveIdentity: deriveTelegramBotIdentity,
|
||||
maskPlatformId: maskTelegramBotId,
|
||||
});
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue