rewrote OerJsonClient in scala