fix(bot): hand off reminder dashboard opens through dm

This commit is contained in:
2026-03-11 22:36:43 +04:00
parent 6b8c2fa397
commit a78eb88fa4
11 changed files with 200 additions and 21 deletions

View File

@@ -0,0 +1,13 @@
export function buildBotStartDeepLink(
botUsername: string | undefined,
payload: string
): string | null {
const normalizedBotUsername = botUsername?.trim()
const normalizedPayload = payload.trim()
if (!normalizedBotUsername || !normalizedPayload) {
return null
}
return `https://t.me/${normalizedBotUsername}?start=${encodeURIComponent(normalizedPayload)}`
}