So you are looking for a number, and while you can get the list in a directly supported REST call:
…but for the count there are some public conversations and solutions you might want to consider.
See this gist:
…and this other thread right here in our Community:
This should be the info you’re looking for, but let us know if you have any questions about putting it all togehter!