call api that is stored in db