added additional command line options and api endpoints