Came across an excellent blog post from @TroyHunt on using Azure Functions to track abusive IP addresses to a website and log them to an Azure storage account and then have another Azure Function on a timer to validate those IP addresses and block them if necessary.
https://www.troyhunt.com/azure-functions-in-practice/
Enjoy!