Fix serialization issue with JSON-RPC + add tests