Moved routines to separated files. Now JSON POSTs.