I actively use "metrics" request to the RESTBase API in the Wikimedia project.
But there is no description of this functionality on the documentation page:
https://www.mediawiki.org/api/rest_v1/?doc
If this is a standard feature, it should be described. If not, please let us know about its prospects.