Contact Form API

In this article, we’ll show you how to integrate your form with SendSquared.

SendSquared can facilitate working with any form, third party or manual api connection to its services.

We offer a standard RESTful API endpoint which is public and omitted of any authentication. This endpoint can facilitate post signup forms, footer email forms and pop ups alike to input directing into your contact database in SendSquared.

Some common integrations are:

  • Elementor Form Entry
  • Custom Email Newsletter Form
  • Custom Website Form

Once completely connected, you can design custom triggers and automations to work in conjunction with any form.

Contact Forms Entry for our public RESTful API

The API endpoint is listed below, and uses a standard query format for input entry. We use a standard named schema for standard field entries, and further supplemented with custom variables.

REST Endpoint:

https://app-api.sendsquared.com/v1/pub/popup?token={GroupTokenId}

Whereas the GroupTokenId is the designated group you’d like the contact to be entered into. The token is a required field.

Standard Post Schema:

The standard schema will be translated directly to the contact in your database. The input on the post should be in standard query string format.

{
"email": "string",  
"display_name": "string",
"first_name": "string",
"last_name": "string",
"address_1": "string",
"address_2": "string",
"locality": "string",
"region": "string",
"postal": "string",
"country": "string",
"locale": "string",
"timezone": "string",
"home_phone": "string",
"mobile_phone": "string",
}

Custom Field Post Schema design:

We allow custom fields with a unique naming convention on the input names. We do this by adding a `-` (hyphen) to any field name. Should a hyphen exist, it will break apart the field name by the hyphen and use the prefix as a custom attribute associated with that contact. Please find the example below:

"birthday-custom": "07/05/1982"

In the example above “birthday” would be added to the contacts custom field with the value of: “birthday-custom”: “07/05/1982”

07/05/1982

Elementor

Elementor is a common framework builder for WordPress that allows you to build complete and complex websites in a drag and drop format. Integrated into their builder is a form builder tool which has gained popularity. Below are the best practices for connecting SendSquared to Elementor.

Using the Custom Form Action in Elemontor we allow you to wire up any elementor form into SendSquared.

The SendSquared Form Action Class

The Form Action class can be found on SendSquared public github repository listed below.

https://github.com/phronesis-ai/elementor-form

Leave a Reply

Your email address will not be published. Required fields are marked *