Using librest instead of liboauth