moved sample usage code into server file