Completed API sample for creating form

Completed API sample for creating form