Authorising AJAX / CORS Requests
By default (and for security reasons), we block such requests. IF you wish to use AJAX to submit your form data to your LeadByte account you will need to submit to another end-point that authorises CORS.
Step 1 - Generate a REST API key in your account with the permission to CREATE leads
Step 2 - Authorise the domain you are making the request from
Step 3 - Submit to WebFormSubmit (contact support if you are unsure)
Generate REST API with permission to CREATE lead(s) (STEP 1)
Further reading here: CREATE Lead via REST API
Authorise Domain / IP (STEP 2)
Firstly, you need to ensure that you have the permission. This is only something Admin users can do. To authorise your domain(s) go to Admin > Tech Hub > Domain Authorisation. Follow the instructions on the screen and save changes. Please note, it can take up to 5 minutes for the domain to be authorised.
If this request comes from a server (server-to-server request), please ensure you add the IP address here. Server=to-Server is authorised by IP or API Key (if you whitelist your key). NOTE: If you are running off a subdomain, please include that as the entry i.e. hello.mydomain.com
Submitting leads to WebFormSubmit (STEP 3)
WebFormSubmit is a domain owned and operated by LeadByte. It permits you (the client) with a public form to submit leads to LeadByte using any available script. Authentication is done using the domain name (HTTP referrer). Please generate the correct URL within your portal using Campaigns > Integration Guide.