Adding rest services + minor fixes.