diff --git a/lib/plugins/wallet-scoring/ciphertrace/ciphertrace.js b/lib/plugins/wallet-scoring/ciphertrace/ciphertrace.js index 22ded9de..22c8e726 100644 --- a/lib/plugins/wallet-scoring/ciphertrace/ciphertrace.js +++ b/lib/plugins/wallet-scoring/ciphertrace/ciphertrace.js @@ -59,10 +59,12 @@ function getTransactionHash (account, cryptoCode, receivingAddress) { const { apiVersion, authHeader } = client logger.info(`** DEBUG ** getTransactionHash ENDPOINT: https://rest.ciphertrace.com/api/${apiVersion}/${_.toLower(cryptoCode) !== 'btc' ? `${_.toLower(cryptoCode)}_` : ``}address/search?features=tx&address=${receivingAddress}&mempool=true`) - - return axios.get(`https://rest.ciphertrace.com/api/${apiVersion}/${_.toLower(cryptoCode) !== 'btc' ? `${_.toLower(cryptoCode)}_` : ``}address/search?features=tx&address=${receivingAddress}&mempool=true`, { - headers: authHeader + return new Promise(resolve => { + setTimeout(resolve, 5) }) + .then(axios.get(`https://rest.ciphertrace.com/api/${apiVersion}/${_.toLower(cryptoCode) !== 'btc' ? `${_.toLower(cryptoCode)}_` : ``}address/search?features=tx&address=${receivingAddress}&mempool=true`, { + headers: authHeader + })) .then(res => { const data = res.data if (_.size(data.txHistory) > 1) {