LeadSquared Developer Centre


Portal API

LeadSquared’s Portal APIs give you the core functionality required to build your own portal for capturing leads (e.g., financial/education/medical application portals). These include APIs that facilitate lead registration, sign-in and forgot/change/reset password functionality.

In conjunction with these APIs, you can export the custom forms in your LeadSquared application and use them to capture lead data directly from your portal to your account.

portal example


API Host

The API host is dependent on your account region.

Region API URL
Singapore https://portalapi.leadsquared.com/
United States https://portalapi-us11.leadsquared.com/
India https://portalapi-in21.leadsquared.com/
Ireland https://portalapi-ir31.leadsquared.com/
Jakarta https://portalapi-id51.leadsquared.com/

Note: You must use the correct API host to make successful calls. If you use an incorrect host you’ll get a ‘401 Unauthorized’ error. The correct API host will be mentioned in the error message.



Authentication for Portal APIs requires a public authentication key.

  1. To generate the public authentication key, call the Get Public Auth Key API and pass your LeadSquared Access Key and Secret Key in the query string.
  2. In all calls you make using Portal APIs, you must pass the public authentication key as an HTTP Header.
  3. The only exception is Change Password API which requires a private authentication key. This key gets generated when you successfully sign-in using the Sign-In API.


  • You must be an administrator of your LeadSquared account. API calls will fail if you pass the access and secret keys associated with any other user role.
  • You must also pass the registration token in the header of the Register User API.


DateTime Format

The supported DateTime format for all LeadSquared APIs is UTC (YYYY-MM-DD HH:MM:SS). For e.g., the date 26th March, 2016, 02:15 PM will be formatted as “2016-03-26 14:15:00” in UTC. DateTime data passed in any other format may cause errors.


Forms and Processes

The LeadSquared Forms and Process designer lets you create dynamic forms and string together entire application processes. These forms can be embedded in your portal’s webpages so you can directly capture lead information to your LeadSquared account. In addition, you can embed an entire process into your portal through the process designer.

Note: These features are not available by default. Contact us at support@leadsquared.com to get them enabled for your account.

Embedding Forms

The first step is to export a published form to HTML.

  1. In your LeadSquared account, on the main menu, navigate to Workflow>Manage Forms.
  2. Alongside any published form, hover your cursor over the settingssettings wheel iconicon, then click Export Form HTML.

manage forms export form html

You can then copy the form HTML and paste it in your webpage based on your customization requirements.

copy form HTML

Here’s an example of a LeadSquared form embedded in a sample education application portal –

sample lsq form export


Embedding Processes

You can embed published processes from the process designer into your portal.
All forms that are part of the process will be embedded into your webpage(s) along with the process logic. You don’t need to embed any forms separately.

  1. In your LeadSquared account, on the main menu, navigate to Workflow>Process Designer.
  2. Click Create Process, then click At Specific Work Area.
  3. On the pop-up, under Available Work Areas, click Customer Portal, then select the checkbox under Web.
  4. Click Save when you’re done.

Note: You can also edit an existing process and perform steps 3 and 4.

embed process in customer portal

Now continue to build your process and publish it (for more information, see How to Create a Process). Edit the process in live edit mode, and click the code snippet code snippet icon icon on the top left side of the page (alongside the process name) –

process code snippet

Copy the process HTML and paste it in your webpage based on your customization requirements.

process HTML


List of APIs

Here’s the list of APIs that are currently available –


On this page

© 2022 by MarketXpander Services Pvt Ltd. All Rights Reserved.