wrote more client functions, centralize types