Use constants for codes instead of a map with string keys
json: Turn on omitEmpty for everything
Turning off broken connection test
Merge pull request #28 from tpjg/cherrypick

Cherrypick some commits from titanous