Wrapper for a rest API