A detailed guide to setting up the Top.gg webhook on Square Cloud.
.zip
file, including the configuration file.
If your application is a Node.js project, take a look at our article on Node.js.
If your application is a Python project, take a look at our article on Python.
https://mysite.squareweb.app/
. After you access and only “Cannot GET /” or “Method Not Allowed” appears, everything is okay.
Now, you need to go back to the previous page where the authorization was defined. In the Webhook URL field, you should put the URL of your site with the route that will receive the votes.
app.post("/topgg", webhook.listener((vote) => {...})
, the route that will receive the votes is “/topgg”. So, if your website is “https://mysite.squareweb.app”, you should put “https://mysite.squareweb.app/topgg” as the Webhook URL.
@app.route("/topgg", methods=["POST"])
, the route that will receive the votes is also “/topgg”. So, the Webhook URL would be the same “https://mysite.squareweb.app/topgg”.
console.log
or print
should appear in the terminal.
mysite.com
) instead of the default URL https://mysite.squareweb.app/
, you need the Standard plan or higher. The subdomain is defined by the SUBDOMAIN field in the configuration file. See: How to set up your custom domain..env
file.