Follow below steps for setting up process builder to send automated SMS on Lead creation:

1.Go to Setup and search for Process Builder in the quick find box and click on it, it will redirect you to the Process management page.

2. Click on the New button. Then, enter Process Name, API Name and select A record changes in The process starts when and click on the Save button

3. Click on Add Object, select Lead object and for the entry criteria, Select only when a record is created or edited, as shown in the below screenshot and click on the Save button 


image


4. The next task is to add Process Criteria. To do this, click on Add Criteria, give Criteria Name, select Action for Executing the Criteria and set filter conditions as per your requirement and click on the Save button as shown in the following screenshot (Here there are no criteria)

image


5. The next step is to add an Immediate action to Process. Click on Add Action (Under Immediate actions), Select the type of action to create (In our case Create a Record) and select Record type as SMS History, and then set the parameters shown in the below image.



Below are the parameters used to create an SMS History record directly:
1.OwnerID(Field Reference):Select OwnerID

2.Lead(Field Reference):Select RecordID
3.Mobile Number(Field Reference): Select the lead mobile number/reference field from the Lead object containing the mobile number

4.SMS Template(ID): Open the template you want to use [go to SMS template tab for the same] and copy the ID from the URL. Please go through below image for reference. 


image


5.SenderID(String): SenderID to be used

6.Source(String): set it as 1495


Once you are done, click on the Save button, it will redirect you to Process canvas. Finally, the Process will look like the following screenshot.


image


 Don’t forget to active the Process Builder by clicking on the Activate button.