some api stuff
DRYer