Created
August 9, 2021 18:32
-
-
Save riccardogiorato/1f7bbcaf8b75e8c80c6c2a9c169d39c7 to your computer and use it in GitHub Desktop.
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
console.log("Let's run also this Node.js script!"); | |
console.log("You can run any kind of Node.js code inside here!"); | |
const queryGetAllUsers = "query allUsers"; | |
const listOfUsers = graphqlRequest.query("queryGetAllUsers"); // <- call hasura endpoint | |
const otherFunctionLocal = require("./otherFunction"); | |
listOfUsers.map((user) => { | |
fetch("alarm.vercel.app/api/check-reward?id=" + user.id); // <- run on vercel, with no "limits" | |
// otherFunctionLocal(user.id); // <- run on local machine | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment