getting rest layer working