var http = require('http'),
  async = require('async'),
  express = require('express');

var services = require('./services'),
    servicesParser = require('./services/parser');

var app = express(),
  argv = require('minimist')(process.argv.slice(2));

var servicesIndex = servicesParser.parseServices(argv.services);

app.get('/*', function (req, res) {

  var service = services.findService(req.url, servicesIndex);

  res.send( service );

});

var server = app.listen(argv.port, argv.address, function() {

  var address = server.address().address,
    port = server.address().port;

  console.log(argv.service + ' server listening at http://%s:%d', address, port);

});

@@ -419,28 +419,96 @@
 %0A%0A  
-res.send( service );
+if (service) %7B%0A    res.send( service.label );%0A  %7D else %7B%0A    res.status(404).send();%0A  %7D
 %0A%0A%7D)

send 404 on service not in index