The Community forums are being phased out in favor of a new Slack group.
Add your email address below to get an invitation to join the community slack group

Slack Signup
Newsletter Optin
Help Desk

Automated Form Submission

Labels

This Discussion is public

Notifications

Hello,

Have an atypical requirement for Formidable Forms Pro.

I have a custom, client-side application with a COMMENT button that when clicked pops open a window for the user to enter comments.

These comments along with about 6 fields worth of client metadata are captured on my client which may or may not be online when the comments are captured.

When an online connection IS available, I want to send this data via an HTTP POST directly to a form at   ACME.com/webform which has a traditional Formidable Form for all the fields being sent.

Since this POST has no way to push the SUBMIT button on the webform, I'm looking for suggestions on the best way to get Formidable to accept the data sent programatically from my client via HTTP to the Formidable Webform.

I'm reasonably fluent with human-submitted Formidable Forms but unsure how best to get my client application submit form data and how best to have Formidable accept it.

Many thanks in advance for any suggestions, examples or links that might help!

Hi Tom,
Please have a look at "Formidable form API plugin" - a separate add-on. https://formidableforms.com/knowledgebase/formidable-api/

This will expose REST API which can be used to programmatically manage your forms. Call this API from your client application using whatever the programming language used in your client application.

Sujee,

Thanks for the tip!

It turns out I have an unused license for the API add-on as well.

I've perused the docs (and will do so again later this evening), but haven't found any examples of how we'd used Javascript to populated an existing Formidable form from a client program.

Most of the calls and features of the API add-on seem to be about accessing, copying or modifying data that's already been submitted previously via a form, or making a form on site 1 visible on site 2.

Let me know if I'm missing something.

Tom

 

Yah there is no coding example for creating a new entry. The Zapier example will give you the idea how to create it.

https://formidableforms.com/knowledgebase/formidable-api/#kb-create-an-entry-from-zapier

I wrote a python script before. But don't have any Javascript example with me. Essentially you will need to learn how to call an API from Javascript with the following details

Type: HTTP POST
URL: http://yoursite.com/wp-json/frm/v2/entries
Body/Data: This is the payload in JSON format.

e.g.  Here 6 is the ID of the form. 67 and 68 are IDs of the fields.

payload = {
'form_id': 6,
'67': "John",
'68': "Doe"
}

Then configure API key as basic auth. This depends on the Javascript library.

If you are familiar with jQuery, have a look at - https://api.jquery.com/jquery.post/

Discussion closed.