Title: Rest API submit form
Last modified: August 4, 2017

---

# Rest API submit form

 *  [wtframework](https://wordpress.org/support/users/wtframework/)
 * (@wtframework)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/rest-api-submit-form/)
 * Hello!
    I am having trouble getting a form to submit using the wp rest API Just
   wish to check if my setup and submission is good! I think some fields might be
   wrong on but still wish to gain any help if anyone can do so.
 * So its a VueJs SPA so the form is hooked up via a component I have built.
 * I have create the form in wordpress and used the ID, I send to the URL:
 * `/wp-json/contact-form-7/v1/contact-forms/${formId}/feedback`
 * So the Data I sent is like so:
 * const data = new FormData();
    data.append(‘_wpcf7’, this.$store.state.form_id);
   data.append(‘_wpcf7_version’, ‘4.8’); data.append(‘_wpcf7_locale’, ‘en_GB’); 
   data.append(‘_wpcf7_container_post’, 2); data.append(‘_wpcf7_unit_tag’,’wpcf7-
   f422-p390-o1′); data.append(‘_wpcf7_nonce’,this.nonce); data.append(‘youremail’,
   this.email); data.append(‘yourname’, this.name);
 * then data gets passed as part of the ajax call (using axios).
 * Now I keep getting told the attempt is spam and rejected. I think it is the nonce,
   but pretty sure it is fine as if I deploy it normally it works.
 * Am I using all the fields above correctly?
    Or Do I need to put the data together
   differently?

Viewing 1 replies (of 1 total)

 *  Thread Starter [wtframework](https://wordpress.org/support/users/wtframework/)
 * (@wtframework)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/rest-api-submit-form/#post-9393925)
 * If there was an example to go from to double check would be sweeeellllll

Viewing 1 replies (of 1 total)

The topic ‘Rest API submit form’ is closed to new replies.

 * ![](https://ps.w.org/contact-form-7/assets/icon.svg?rev=2339255)
 * [Contact Form 7](https://wordpress.org/plugins/contact-form-7/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/contact-form-7/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/contact-form-7/)
 * [Active Topics](https://wordpress.org/support/plugin/contact-form-7/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/contact-form-7/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/contact-form-7/reviews/)

 * 1 reply
 * 1 participant
 * Last reply from: [wtframework](https://wordpress.org/support/users/wtframework/)
 * Last activity: [8 years, 8 months ago](https://wordpress.org/support/topic/rest-api-submit-form/#post-9393925)
 * Status: not resolved