Alter machiavelli-generated metrics URL

use a generator utility function for metric url generation

change the default metric url to have the metric name in the query string, not
the main path (query string has less reserved characters than path, making this much
easier to manage)