使用ripple lib函数获取时发现错误getTransactions(address,Options)

时间:2018-06-12 10:11:25

标签: ripple

[MissingLedgerHistoryError(服务器缺少指定范围内的分类帐历史记录)]发现错误


options.minLedgerVersion = + req.query.minLedgerVersion;           
options.maxLedgerVersion = + req.query.maxLedgerVersion;           
options.types = ['payment'];         
        
api.connect()。then(()=> {          
/ *开始自定义代码------------------------------------ * /          
返回api.getTransactions(req.query.address,options)         
})。then(transaction => {          
console.log(“交易信息:::”,交易);               
res.status(200)上传.json(formatter.simpleFormat(事务,真, “成功”
));            
})。catch(err => {           
console.log(错误);            
res.status(500).json(formatter.simpleFormat(null,false,“error”));                });

1 个答案:

答案 0 :(得分:0)

您可以在server_info方法返回的回复中找到答案 查找:result/info/complete_ledgers并查看是否包含您的请求分类帐