Created
September 27, 2024 12:35
-
-
Save the-pesar/cafee664d6bafc5915760e762ace528e to your computer and use it in GitHub Desktop.
Withdraw hamster airdrop
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const token = "$token" // replace your token to $token | |
const headers = { | |
Authorization: token, | |
} | |
async function delay(ms) { | |
return new Promise((reslove) => setTimeout(() => reslove(true), ms)) | |
} | |
let pend = true | |
async function claim() { | |
const res = await fetch( | |
"https://api.hamsterkombatgame.io/interlude/onchain/queue", | |
{ headers, method: "POST" } | |
) | |
const data = await res.json() | |
if (data.createTransaction) { | |
pend = false | |
alert("درخواست برداشت ارسال شد.") | |
} else { | |
console.log("درحال انجام..."); | |
} | |
} | |
async function start() { | |
do { | |
claim() | |
await delay(500) | |
} while (pend) | |
} | |
start() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment