Added implementation of rest client to handle JSON objects.

Json tests added and passing.

Xml tests added but failing. Will be fixed as priority.