updated docs and changed tweaked api