Better form api

Most requests now return a json encoding of the forms ids, values, and
any error each one might have.