Every time you win a bet the script sends your desired % to the Vaulet
当前为
// ==UserScript==
// @name Balance-Wingman Send shares on win to Vaulet
// @description Every time you win a bet the script sends your desired % to the Vaulet
// @description Create your acc here to support my work https://stake.com/?c=263733c1bc
// @version 1.3
// @author Dauersendung
// @namespace https://greasyfork.org/de/users/444902-dauersendung
// @match https://stake.com/*
// @run-at document-start
// ==/UserScript==
var oldBal = 0;
var accessToken = localStorage.getItem('session').replace(/"/g, '');
function depositBal(depositAmount) {
var data = [
{
operationName: "CreateVaultDeposit",
query: "mutation CreateVaultDeposit($amount: Float!, $currency: CurrencyEnum!) { createVaultDeposit(amount: $amount, currency: $currency) { id amount currency user { id balances { available { amount currency __typename } vault { amount currency __typename } __typename } __typename } __typename } } ",
variables: {
amount: depositAmount,
currency: "xrp", // you need to replace your playing currency here like: "xrp" "trx" "btc" "doge" "eos" "eth" "ltc" "bch"
}
}
]
return fetch("https://api.stake.com/graphql", {
"credentials": "omit",
"headers": {
"content-type": "application/json",
'x-access-token': accessToken,
'x-lockdown-token': undefined
},
"referrer": "https://stake.com/?currency=xrp&modal=vault&operation=deposit", // you need to replace your playing currency here like: "xrp" "trx" "btc" "doge" "eos" "eth" "ltc" "bch"
"body": JSON.stringify(data),
"method": "POST",
"mode": "cors"
});
}
function checkBalance() {
var curBalEle = document.querySelector(".styles__Cashier-puey40-2.dMSTdD .styles__Content-rlm06o-1.ixoRjG");
if (!curBalEle) return false;
var curBal = curBalEle.innerText;
if (!curBal) return false;
if (curBal > oldBal) {
var depositAmount = ((curBal - oldBal)*0.20); // set the % to send here 0.2 = 20 %
depositBal(depositAmount).then(() => oldBal = curBalEle.innerText);
}
}
window.setInterval(checkBalance, 3300);