Replace facebook API with custom request function; add option parser