Developer Friendly APIs
We make it easy for you to get your lead data into other software or crm
Enable API Access
In order to use the API, you must first Enable API access for your account.You can do that by following the steps below:
- Login and go to your Account Settings page
- Under the API access tab, click the Enable API access button
- Copy your API access key and API password
Generate Authorization Token
Calls to the API will require an Authorization token to make sure the request is valid and authorized to access your account.A unique token value (a GUID) will be generated and will last for up to 30 minutes before a new token will need to be generated.
Here is how you generate a Auth Token:
- API Endpoint: https://api.leadformx.com/api/token
-
Make a HTTP POST request with the accessKey and accessPwd to the endpoint to receive a token
POST /api/token HTTP/1.1 Host: api.leadformx.com Content-Type: application/x-www-form-urlencoded Content-Length: 33 accessKey=value1&accessPwd=value2
-
Receive a JSON Response:
{ "success": true/false (boolean), "error": "a descriptive message only if there was an error", "token": "a GUID value (36 characters) if a token was generated successfully", "expireUtc": "the token expiration datetime in UTC (usually 30 minutes from the time it was generated)" }
Get User Data By Lead ID
This API allows you to receive a form user data by the Submit ID. You may have received the Lead ID by a API push or as a get parameter in a redirect to your website after your form is submitted. You can also get a list of all the Lead IDs by calling the next API - Get Lead ID List.- API Endpoint: https://api.leadformx.com/api/xleadid/LEADID (Lead ID is a string value, up to 64 characters)
-
Make a HTTP GET request to the endpoint passing the Authorization Token as AUTHTOKEN in the HTTP header
POST /api/xleadid/1496XAG38EI4IRQNOXZP8KLVJ7 HTTP/1.1 Host: api.leadformx.com AUTHTOKEN: b4e10db8-7058-4de1-8bd6-2aa418e2c780
-
Receive a JSON Response:
{ "success": true, "error": "", "date": "2019-12-23T20:53:57", "data": [ { "InputType": "checkboxes", "DataId": "car", "Placeholder": null, "Question": "Which car do you like?", "Answer": "Mercedes,Audi" }, { "InputType": "checkboxes", "DataId": military, "Placeholder": null, "Question": "Military Affiliation?", "Answer": "Spouse" } ] }
Get Lead ID List
This API allows you to get a list of all the Lead IDs since the last Lead ID received. It will return up to 1000 Lead IDs if they exist. It will also tell you the number of Lead IDs remaining if any. You can then use the Lead IDs to get the Lead Data by calling the previous API.- API Endpoint: https://api.leadformx.com/api/leads/list/LAST-LEAD-ID (last Lead ID is optional if you haven't received one)
-
Make a HTTP GET request to the endpoint passing the Authorization Token as AUTHTOKEN in the HTTP header
POST /api/leads/list/1492XYKOJLEPRNULHDBD7ZDLPHE HTTP/1.1 Host: api.leadformx.com AUTHTOKEN: b4e10db8-7058-4de1-8bd6-2aa418e2c780
-
Receive a JSON Response:
{ "success": true, "error": "", "data": [ "1496XAG38EI4IRQNOXZP8KLVJ7", "1500X4O3V4WGN3LI5BL5HTQ76Q5", "1504XTVGG7GJ6ISMU3W4KC9DXOH" ], "remaining": 0 }