Updated resource collections to be returned as generic collection objects.
Added support for response codes.