@rck,
In the sample shared above PhantomJS is required for rendering the chart on server and exporting the same as an image. page.render() helps in rendering the web page(containing the chart) to an image buffer and then saves it as an image with the specified filename.
___________
Indranil Singh Deo
Team CanvasJS