added POST support, better JSON parsing error handling and updated project for latest swift changes