several rest improvements