Skip to content

Run makeMoney Script #6

Run makeMoney Script

Run makeMoney Script #6

Workflow file for this run

name: Run makeMoney Script
on:
schedule:
- cron: "*/1 * * * *" # Run every minute
jobs:
run-script:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Install Node.js
uses: actions/setup-node@v2
with:
node-version: '14'
- name: Install node-fetch
run: npm install node-fetch
- name: Create JavaScript file
run: |
echo "const fetch = require('node-fetch');
const url = 'https://api.adsgram.ai/event?type=reward&trackingtypeid=14&record=IiRmNzEyMTYxMi1iY2Q4LTQ4NTEtYTE0ZC1iMGZjMjRlNDg5ZDEqBDgzMjkyBTEwNTQ1OgU4NzcxOUDLlY-4BkoJOTQ0NDE4MjMyUgQzODUyWhpodHRwczovL2JvdC50b25jaXJjbGUub3JnL2IBMmoDd2VicgJlbooBBDMyMTKSAQQ3MjY0mgEMNDM4NTkuNTAwMDAwqgEIMC40NTc3MDGyAQEyugEMNTQuMTcwLjY5LjI5wgECaWU';
function makeMoney() {
fetch(url).then((res) => {
console.log(res.status === 200 ? 'Success' : 'Failed');
}).catch(console.error);
}
setInterval(makeMoney, 60 * 1000);
console.log('Started..');
makeMoney();" > script.js
- name: Run JavaScript code
run: node script.js