The command exited with code 0. Output: 155: let candidatePaymentIds = [820, 822]; 156- try { 157- const depIndexRes = await fetch('https://cashier.oeur39rmwe.com/session/deposit/index/', { 158- headers: { 159- 'Authorization': 'IND', 160- 'Token': token, 161- 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:151.0) Gecko/20100101 Firefox/151.0' 162- } 163- }); 164- if (depIndexRes.ok) { 165- const depIndexJson = await depIndexRes.json(); 166- if (depIndexJson.code === 0 && depIndexJson.data && Array.isArray(depIndexJson.data.payments)) { 167- const onlineIds = depIndexJson.data.payments.map(p => p.paymentId).filter(Boolean); 168- if (onlineIds.length > 0) { 169: candidatePaymentIds = [...new Set([...onlineIds, 820, 822])]; 170- } 171- } 172- } 173- } catch (depErr) { 174- console.warn(`[PAYMENT WARNING] Failed to query deposit index:`, depErr.message); 175- } 176- 177- let submitJson = null; 178- let lastSubmitError = null; 179- 180: for (let i = 0; i < candidatePaymentIds.length; i++) { 181: const pid = candidatePaymentIds[i]; 182- try { 183: console.log(`[PAYMENT] Attempting paymentId ${pid} for ₹${amount} (${i + 1}/${candidatePaymentIds.length})...`); 184- const submitRes = await fetch('https://cashier.oeur39rmwe.com/session/payment/submit', { 185- method: 'POST', 186- headers: { 187- 'Content-Type': 'application/x-www-form-urlencoded', 188- 'Authorization': 'IND', 189- 'Token': token, 190- 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:151.0) Gecko/20100101 Firefox/151.0' 191- }, 192- body: `bankCardId=0&localAmount=${amount}&paymentId=${pid}` 193- }); 194- 195- if (!submitRes.ok) throw new Error(`Payment Submit API returned HTTP ${submitRes.status}`); 196- const resJson = await submitRes.json(); 197- console.log(`[PAYMENT] Submit API response (paymentId=${pid}):`, JSON.stringify(resJson)); 198- 199- if (resJson.code === 0 && resJson.data && resJson.data.result && resJson.data.result.requestUrl) { 200- submitJson = resJson; 201- break; 202- } 203- 204- const mappedErr = CASHIER_ERROR_MAP[resJson.code] || resJson.message || resJson.msg || `Payment gateway returned code ${resJson.code}`; 205- lastSubmitError = new Error(mappedErr); 206- 207: if (i < candidatePaymentIds.length - 1) { 208- await new Promise(r => setTimeout(r, 1500)); 209- } 210- } catch (err) { 211- lastSubmitError = err; 212- console.warn(`[PAYMENT WARNING] paymentId ${pid} failed:`, err.message); 213: if (i < candidatePaymentIds.length - 1) { 214- await new Promise(r => setTimeout(r, 1500)); 215- } 216- } 217- } 218- 219- if (!submitJson || !submitJson.data || !submitJson.data.result || !submitJson.data.result.requestUrl) { 220- throw lastSubmitError || new Error("Failed to generate payment order from server"); 221- } 222- 223- requestUrl = submitJson.data.result.requestUrl; 224- console.log(`[PAYMENT] Processing checkout URL: ${requestUrl}`); 225- 226- const qrResult = await gateways.generateQR(requestUrl, amount); 227- gatewayHost = qrResult.gatewayHost; 228- const { 229- qrBuffer, 230- orderId, 231- nonce, 232- expectedDate, 233- isGoldgo, 234- isRynpp, 235- isKivoPay, 236- isIndiaPay, 237- isEwalletPay, 238- isBluePay, 239- isUpiPayments, 240- isPayflow, 241- isDirectUpi, 242- isPlayBridge, 243- isBifrostPay, 244- isXmdhPay, 245- isCoinPay, 246- tenantId, 247- gatewayApiUrl 248- } = qrResult; 249- 250- // Fetch serial number and exact time from deposit history with retries 251- let serialNumber = 'N/A'; 252- let depositTime = expectedDate || 'N/A'; 253-