Add TimeoutError and raise it on 504

Raise TimeoutError on 504 instead of JSON::ParserError

Fixes #16