The command exited with code 0. Output: // Edit the welcome menu to remove the keyboard and show the selection if (ctx.callbackQuery) { ctx.answerCbQuery().catch(() => { }); ctx.editMessageText(`✨ **Selected Service:** \`${serviceName}\``, { parse_mode: 'Markdown' }); } // Send a temporary loader message that will get deleted automatically const loaderMsg = await ctx.reply('⏳ Loading... Please wait.', { parse_mode: 'HTML' }); sessions[userId].startLoaderId = loaderMsg.message_id; try { // Just verify API connectivity through backend const pingRes = await callApi('/captcha', { method: 'GET' }); // Delete the start loader immediately once done if (sessions[userId].startLoaderId) { ctx.telegram.deleteMessage(userId, sessions[userId].startLoaderId).catch(() => { }); } if (directMobile) { await handleMobileSubmit(ctx, sessions[userId], directMobile); } else { if (serviceType === 'EID_TO_PDF') { ctx.reply('📑 *Please enter the 14-digit Enrolment ID (EID):*', { parse_mode: 'Markdown' }); sessions[userId].step = 'WAITING_FOR_EID'; } else { ctx.reply('📱 *Please enter your 10-digit registered Mobile Number:*', { parse_mode: 'Markdown' }); sessions[userId].step = 'WAITING_FOR_MOBILE'; } } } catch (error) { console.error(error); if (sessions[userId].startLoaderId) { ctx.telegram.deleteMessage(userId, sessions[userId].startLoaderId).catch(() => { }); } ctx.reply('❌ *A temporary connection error occurred. Please try again.*', { parse_mode: 'Markdown' }); } } bot.action('START_RETRIEVE_AADHAAR', (ctx) => startService(ctx, 'RETRIEVE_SMS')); bot.action('START_DOWNLOAD_AADHAAR', (ctx) => startService(ctx, 'DOWNLOAD_PDF')); bot.action('START_EID_TO_PDF', (ctx) => startService(ctx, 'EID_TO_PDF')); bot.action(/^DIRECT_RETRIEVE_(\d{10})$/, async (ctx) => { const mobile = ctx.match[1]; await startService(ctx, 'RETRIEVE_SMS', mobile); }); bot.action(/^DIRECT_DOWNLOAD_(\d{10})$/, async (ctx) => { const mobile = ctx.match[1]; await startService(ctx, 'DOWNLOAD_PDF', mobile); });