Easiest way to run javascript on server side
There are several solutions for running server side javascript (Node.JS, or something based on Rhino), but that code is probably dependent on functionality that only exists in a browser.
EDIT
I answered the question, but I didn't really address the problem. Even if the code will execute run on the server, it won't work as intended. You really need to come up with a better solution for tracking usage of a non web based application.
The question you should have asked is: How can I track usage of an android application?
If you are already running a server, they you could write a simple web service that logs usage, you just need to open a HTTP connection from within your app.
I would be surprised if there aren't existing solutions, but I'm not an Android guy, so I wouldn't know.
I would suggest deleting this question and replacing it with one targeting what you are actually trying to accomplish.