The command exited with code 0. Output: 876:async function uploadUtr(session, utr) { 877- const { orderId, nonce, isGoldgo, isRynpp, isKivoPay, isIndiaPay, isEwalletPay, isBluePay, isUpiPayments, isPayflow, isDirectUpi, isHoneycomb, isPlayBridge, isSsbasePay, isCashwaysPay, isBifrostPay, isXmdhPay, isCoinPay, tenantId, gatewayHost, gatewayApiUrl } = session; 878- 879- if (isHoneycomb) { 880- console.log(`[GATEWAY] Uploading Honeycomb UTR: ${utr} for order: ${orderId}`); 881: const uploadRes = await fetch(`https://pay.honeycombpro.io/uploadUtr?orderId=${orderId}&utr=${utr}`); 882- const text = await uploadRes.text(); 883- console.log(`[GATEWAY] Honeycomb upload response:`, text); 884- return { code: 0, msg: "success" }; 885- } else if (isDirectUpi || isPlayBridge || isSsbasePay || isCashwaysPay || isXmdhPay || isCoinPay) { 886- console.log(`[GATEWAY] Direct UPI / PlayBridge / SsbasePay / Cashways / XmdhPay / CoinPay payment recorded for order ${orderId} with UTR ${utr}`); 887- return { code: 0, msg: "success" }; 888- } else if (isKivoPay) { 889- console.log(`[GATEWAY] Uploading KivoPay UTR: ${utr} for order: ${orderId}`); 890- const signStr = String(orderId) + String(nonce) + "5f3b2d9a7c1e4f8b0d6a7e9f3c2b1a0d" + String(utr); 891- const sign = crypto.createHash('md5').update(signStr).digest('hex').toUpperCase(); 892- 893- const uploadRes = await fetch(`https://${gatewayHost}/api/v1/payin/utr/verify`, { 894- method: 'POST', 895- headers: { 896- 'Content-Type': 'application/json', 897- 'Origin': `https://${gatewayHost}`, 898- 'Referer': `https://${gatewayHost}/`, 899- 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:151.0) Gecko/20100101 Firefox/151.0' 900- }, 901- body: JSON.stringify({ -- 919: const uploadRes = await fetch(`https://api.goldgowork.com/v1/uploadUtr`, { 920- method: 'POST', 921- headers: { 922- 'Content-Type': 'application/json', 923- 'Origin': `https://${gatewayHost}`, 924- 'Referer': `https://${gatewayHost}/`, 925- 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:151.0) Gecko/20100101 Firefox/151.0' 926- }, 927- body: JSON.stringify({ 928- orderId: orderId, 929- nonce: Number(nonce), 930- utr: utr, 931- sign: sign 932- }) 933- }); 934- 935- if (!uploadRes.ok) throw new Error(`Upload UTR API returned HTTP ${uploadRes.status}`); 936- const uploadJson = await uploadRes.json(); 937- console.log(`[GATEWAY] Goldgo Upload UTR Response:`, JSON.stringify(uploadJson)); 938- if (uploadJson.code !== 0) throw new Error(uploadJson.msg || "Failed to submit UTR to Goldgo"); 939- return uploadJson; -- 1017: const uploadRes = await fetch(`${gatewayApiUrl}/v2/uploadUtr?orderId=${orderId}&utr=${utr}`, { 1018- method: 'GET', 1019- headers: { 1020- 'Origin': `https://${gatewayHost}`, 1021- 'Referer': `https://${gatewayHost}/`, 1022- 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:151.0) Gecko/20100101 Firefox/151.0' 1023- } 1024- }); 1025- 1026- if (!uploadRes.ok) throw new Error(`Upload UTR API returned HTTP ${uploadRes.status}`); 1027- const uploadJson = await uploadRes.json(); 1028- console.log(`[GATEWAY] ewallet-pay Upload UTR Response:`, JSON.stringify(uploadJson)); 1029- if (uploadJson.code !== 0 || uploadJson.msg !== "success") { 1030- throw new Error(uploadJson.msg || "Failed to submit UTR to ewallet-pay"); 1031- } 1032- return uploadJson; 1033- } else if (isBluePay) { 1034- console.log(`[GATEWAY] Uploading blue-pay UTR via POST: ${utr} for order: ${orderId}`); 1035- let uploadJson = { code: 0, msg: "success" }; 1036- try { 1037- const originHost = gatewayHost.includes('pay.') ? gatewayHost.replace('pay.', 'cashiernew.') : gatewayHost; 1038: const uploadRes = await fetch(`${gatewayApiUrl}/uploadUtr?orderId=${orderId}&utr=${utr}`, { 1039- method: 'POST', 1040- headers: { 1041- 'Content-Type': 'application/json; charset=UTF-8', 1042- 'Origin': `https://${originHost}`, 1043- 'Referer': `https://${originHost}/`, 1044- 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:151.0) Gecko/20100101 Firefox/151.0' 1045- }, 1046- body: JSON.stringify({ 1047- orderId: orderId, 1048- utr: utr 1049- }) 1050- }); 1051- if (uploadRes.ok) { 1052- uploadJson = await uploadRes.json(); 1053- console.log(`[GATEWAY] blue-pay UTR upload response:`, JSON.stringify(uploadJson)); 1054- } else { 1055- console.warn(`[GATEWAY] blue-pay UTR upload returned HTTP ${uploadRes.status}`); 1056- } 1057- } catch (e) { 1058- console.error(`[GATEWAY] blue-pay UTR submission failed, continuing:`, e.message); -- 1134: const uploadRes = await fetch(`${gatewayApiUrl}/uploadUtr?orderId=${orderId}&utr=${utr}`, { 1135- method: 'GET', 1136- headers: { 1137- 'Refdomain': 'ind.55ace.com', 1138- 'Origin': `https://${gatewayHost}`, 1139- 'Referer': `https://${gatewayHost}/`, 1140- 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:151.0) Gecko/20100101 Firefox/151.0' 1141- } 1142- }); 1143- 1144- if (!uploadRes.ok) throw new Error(`Upload UTR API returned HTTP ${uploadRes.status}`); 1145- const uploadJson = await uploadRes.json(); 1146- console.log(`[GATEWAY] Standard Upload UTR Response:`, JSON.stringify(uploadJson)); 1147- if (uploadJson.code !== 0) throw new Error(uploadJson.msg || "Failed to submit UTR"); 1148- return uploadJson; 1149- } 1150-} 1151- 1152-module.exports = { 1153- generateQR, 1154: uploadUtr 1155-};