Add option to skip ssl cert validation
Raise exception on error return
Improve logging