I have created a c# application(Windows Service) using Splunk SDK C# to monitor splunk licence.
if the indexed data exceeds the value you enter it will disable all UDP inputs and enable them after midnight
The link to the application is down below fell free to change it to your needs.
http://www.codeproject.com/Tips/1112026/Automate-Splunk-Licence-Monitoring
... View more