added random_post method
refactored loading of mailer.json file
moved json file to homedirectory