moved api stuff to sub