Overview:
eLead creation process has been enhanced to support the creation of eLeads via HTTP GET requests by accepting query parameters. This enhancement allows for greater flexibility when integrating with external systems that are unable not submit eLeads via JSON to our endpoint.
Key Features:
A new HTTP GET endpoint (/services/apexrest/i360core/elead/create) has been created to accept query parameters.
- Query parameters are case-insensitive
Example:
- URL : https://momentum-business-6272-dev-ed.scratch.my.salesforce-sites.com
- Endpoint: /services/apexrest/i360core/elead/create
-
Query Parameters:
?i360core__First_Name__c=Kent&i360core__Last_Name__c=Clark&i360core__Phone__c=3213213213&Phone1Type=Mobile&i360core__City__c=Pleasant Grove&i360core__State_Province__c=UT&i360core__Zip_Postal_Code__c=84062&i360core__Street_Address__c=859 N 100 E&i360core__Email__c=test@amigo.com&i360core__Source__c=Lead Provider&i360core__Interested_In__c=Windows&i360core__Lead_Source_Name__c=Newspaper&i360core__Taken_By__c=Heather Turner&i360core__Appointment_Date_Time__c=2024-07-04T3:23:32&i360core__Appointment_End_Date_Time__c=2024-07-05T4:20:30
Setup:
- Go to Setup > search for Sites in Quick Find > click New
- Fill in the following fields and Save:
- Site Label
- Site Name
- Active = True
- Active Site Home Page = InMaintenance
- Click on Public Access Settings
- Give the following Permissions:
- Object Settings - Add Read, Create, Edit, View All, Modify All Permissions for the following Objects
- Account
- Address
- Contact
- eLead
- Inquiry
- Lead Source
- Sales Opportunity
- Sales Appointment
- Sales Appointment Opportunities
- Staff
- Territory
- System Permissions
- View All Custom Settings
- Modify All Data
- View All Data
- Access Activities
- API Enabled
- Edit Tasks
- Password Never Expires
- View All Custom Settings
- Apex Class Access
- Add all eLead Apex Classes
- Custom Metadata Types
- Add all eLead Custom Metadata Types
- Object Settings - Add Read, Create, Edit, View All, Modify All Permissions for the following Objects
- Create your URL
- Site URL
- Go to the Site you created
- Endpoint
- /services/apexrest/i360core/elead/create
- Query Parameters (the payload you are sending in)
-
ex:
?i360core__First_Name__c=Kent&i360core__Last_Name__c=Clark&i360core__Phone__c=3213213213&Phone1Type=Mobile&i360core__City__c=Pleasant Grove&i360core__State_Province__c=UT&i360core__Zip_Postal_Code__c=84062&i360core__Street_Address__c=859 N 100 E&i360core__Email__c=test@amigo.com&i360core__Source__c=Lead Provider&i360core__Interested_In__c=Windows&i360core__Lead_Source_Name__c=Newspaper&i360core__Taken_By__c=Heather Turner&i360core__Appointment_Date_Time__c=2024-07-04T3:23:32&i360core__Appointment_End_Date_Time__c=2024-07-05T4:20:30
-
- Site URL
- URL should be Site URL + Endpoint + ? + Query Parameters
- Ex: https://lightning-august2023-maddie.my.salesforce-sites.com/test/services/apexrest/i360core/elead/create?i360core__First_Name__c=Kent&i360core__Last_Name__c=Clark&i360core__Phone__c=3213213213&Phone1Type=Mobile&i360core__City__c=Pleasant Grove&i360core__State_Province__c=UT&i360core__Zip_Postal_Code__c=84062&i360core__Street_Address__c=859 N 100 E&i360core__Email__c=test@amigo.com&i360core__Source__c=Lead Provider&i360core__Interested_In__c=Windows&i360core__Lead_Source_Name__c=Newspaper&i360core__Taken_By__c=Heather Turner&i360core__Appointment_Date_Time__c=2024-07-04T3:23:32&i360core__Appointment_End_Date_Time__c=2024-07-05T4:20:30
- To test, create a GET request in Postman
- eLead record should be created successfully
Comments
0 comments
Please sign in to leave a comment.