NodeJS Adaptation of ProWeb Sample Code