added rest of the api functions