Updated the form api functions