In my saas application, instead of a having a common sub-domain for all the clients I have different sub-domains for different clients such as http://www.abc.myapp.com, http://www.def.myapp.com and http://www.ghi.myapp.com. Thousands of sub-domains are already there and more will be added in future.
we have Oauth based authentication, API key based and basic authentication with username/password. Basic authentication will be used most of the time. An example curl command to get all the users will look like this
curl -v -u sample@myapp.com:xxxxx -X GET 'https://abc.myapp.com/api/users'
curl -v -u username:password -X GET 'https://abc.myapp.com/api/#endpoint#'
I want to get the API analytics for each of these clients separately and also as a whole, and manage the same. Is it possible?