First version.

@todo:
1. make $httpClient a separate object.
2. add UnitTests
First working version with JSON-RPC.