feat: add privacy-aware security manager onboarding
All checks were successful
Codex Template Compliance / template-compliance (pull_request) Successful in 7s
Build / test-and-image (pull_request) Successful in 52s

This commit is contained in:
2026-07-05 21:39:55 +02:00
parent d13652a70b
commit 0c7ddc53b4
14 changed files with 767 additions and 8 deletions

View File

@@ -27,6 +27,10 @@ const COMMANDS = {
'/reset': 'Clear the AI conversation history',
'/tools': 'List allowlisted Intelligence Terminal tools',
'/trace': 'Show the last tool audit trace',
'/profile': 'Show the encrypted Security Manager profile',
'/onboarding':'Start or restart Security Manager setup',
'/language': 'Change the Security Manager language',
'/profile_delete': 'Delete the Security Manager profile',
'/confirm': 'Confirm a pending agent action',
'/cancel': 'Cancel a pending agent action',
'/portfolio': 'Show current positions and P&L (if Alpaca connected)',
@@ -578,7 +582,13 @@ export class TelegramAlerter {
if (!response) return;
const text = typeof response === 'string' ? response : response.text;
const parseMode = typeof response === 'object' && Object.hasOwn(response, 'parseMode') ? response.parseMode : null;
await this.sendMessage(text, { chatId, replyToMessageId: query.message?.message_id, parseMode });
const replyMarkup = typeof response === 'object' ? response.replyMarkup : null;
await this.sendMessage(text, {
chatId,
replyToMessageId: query.message?.message_id,
parseMode,
...(replyMarkup ? { replyMarkup } : {}),
});
} catch (error) {
console.error('[Telegram] Callback error:', error.message);
await this.sendMessage('The requested action failed.', { chatId, replyToMessageId: query.message?.message_id, parseMode: null });