You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am getting this issue i.e. ALL_CONNECTIONS_FAILED: All endpoints are offline (or don't provide full history) while using xrpl-txdata version 1.2.1 in nodejs version 18.16.0 from few days while verifying xrpl NFT exchange transaction and this is public platform.
Hi Team,
I am getting this issue i.e. ALL_CONNECTIONS_FAILED: All endpoints are offline (or don't provide full history) while using xrpl-txdata version 1.2.1 in nodejs version 18.16.0 from few days while verifying xrpl NFT exchange transaction and this is public platform.
My code to verify transaction is :-
'use strict';
require("dotenv").config();
const { XummSdk } = require("xumm-sdk");
const { TxData } = require('xrpl-txdata');
const XUMM_API_KEY = process.env.XUMM_API_KEY;
const XUMM_API_SECRET = process.env.XUMM_API_SECRET;
const Sdk = new XummSdk(XUMM_API_KEY, XUMM_API_SECRET);
const VerifyTx = new TxData([
'wss://xrplcluster.com',
'wss://s2.ripple.com',
'wss://xrpl.link'
], {
EndpointTimeoutMs: 750,
OverallTimeoutMs: 5000,
AllowNoFullHistory: false
})
/* Verify Transaction with Tx Id*/
async function verifyTransaction(resolveData) {
try {
const result = await Sdk.payload.get(resolveData.payload_uuidv4)
const VerifiedResult = await VerifyTx.get(result.response.txid, 20)
const { meta: { TransactionResult }} = VerifiedResult.result;
const balanceCheck = isEmpty(VerifiedResult.balanceChanges);
return { balanceCheck, TransactionResult };
} catch (error) {
console.log("error verifytransaction",error)
return {error};
}
}
function isEmpty(obj) {
return Object.keys(obj).length === 0;
}
module.exports = { verifyTransaction };
Please suggest me what to do, Should I update npm package or what is the solution?
Thanking for any help.
The text was updated successfully, but these errors were encountered: