attempt to copy node-js-sample