In Salesforce, Assets are the products or items an organization sells or uses to service customers. The Assets are associated with accounts, opportunities, or cases, providing information about the products owned or used by customers.
In Salesforce automation, we can automate the process of creating assets with the help of Salesforce flows, which results in saving time, reducing errors, and ensuring consistency.
Create a Flow Automate Assets Creation in Salesforce
To Automate Assets Creation using Flows in Salesforce, we will create a Record-triggered flow, and for that, navigate to the Setup page of Salesforce and follow the below steps.
1. On Salesforce’s Setup page, go to the Quick Find box and search, then select Flows under Process Automation.
2. On the Flows setup tab, click on the button New Flow.
3. Select the option Record-Triggered flow and click Create.

4. Now, we will configure the conditions to trigger the flow to run.
I have defined requirements such as when an opportunity is updated to closed won, the record will trigger, and I have configured the trigger accordingly.
- Select the Object as Opportunity.
- Under the heading Configure Trigger, select the option, A Record is Updated.
- In the Conditions Requirements, enter the Field as Stage Name, Operator as Equals to, and Value as Closed Won.

5. Add a Get Record element to the flow and enter the following fields.
- Enter the Label and the API name for the get record element.
- Select the Object as an Opportunity Product.
- In the Conditions Requirements, enter the Field as OpportunityId, Operator as Equals to, and Value as Record > Opportunity ID.
- Under the heading How many records to store, select the option All records.

6. Now add a loop to the flow and add the below details to the loop element.
- Enter the Label and the API Name.
- In the field Collection Variable, select the created get the record element.
- In the Direction field, select the option First item to the Last item.

7. Add an Assignment element in the loop and enter the Label and API Name for the assignment element. To create a variable, go to the Variable field and click on New Resource.

8. Enter the below details for the new resource.
- Select the Resource Type as a Variable.
- API Name can be anything relevant to Asset; here, I have entered API Name as An_Asset.
- Select the Data Type as Record and Object as Asset.
- At last, click on the Done button.

9. We will set variable values using the created variable resource. In the section Set Variable Values, we will add the following variables to their respective fields.
| Variable | Value |
| An_Asset > Account_ID | Record > Account > Account ID |
| An_Asset > Product_ID | Current loop > Product > Product ID |
| An_Asset > Quantity | Current loop > Quantity |
| An_Asset > Purchase Date | Record > Purchase Date |
| An_Asset > Name | Record > Account Name |

10. Again, add an Assignment element to make a collection of Assets in the record.
Enter the Label and the API Name for the assignment element, and I have labeled the second assignment element as Add asset to a collection.
To create a resource, in the field Variable click on New Resource.

11. Enter the below details for the New Resource.
- Select the Resource Type as a Variable.
- For this resource, I have entered the API Name as Asset_collection.
- Select the Data Type as Record and Object as Asset.
- Activate the checkbox Allow multiple values and click on the Done button.

12. In the section Set Variable Values, take the created Record variable, select Operator as Add, and Value as An_Asset ( variable from precious assignment element).

13. Add a Create Record element to create assets and

14. Save the flow, enter a relevant Flow Label and Flow API Name, and click the Save button.

15. At last, activate the flow and click on the Activate button.

After activation, the flow will start working, and it will trigger according to the defined conditions.
Test the Flow in the Salesforce console
To test and debug the flow, navigate to the Opportunity tab and follow the below steps.
1. In the Opportunity tab, open an opportunity record.
2. In the Opportunity record, set the stage to Closed Won.

As the stage is changed to closed won, the products in this opportunity will be added as assets to the opportunity’s account.
3. In the details section, click on the Account Name of the opportunity record.

4. In the account record, scroll to the section Assets and there you will see the products are added as assets in the account.

If you are not able to view the Assets in the account record, then you have to edit the page layout, i.e., the Account page layout, and then add Assets from related lists to the page layouts.
In this way, we can automate asset creation using flows in Salesforce by following the Avobe steps.
Conclusion
In Salesforce, using Flows to create assets is a simple and effective way to automate asset creation processes. By following the above steps, we have understood the process of automating asset creation using the Salesforce trigger flow.
You may like to read:
- How to Freeze User’s Account Using Salesforce Flow
- How to Bulk Create Campaigns in Salesforce Via Data Loader
- How to Setup Field History Tracking in Salesforce

Abhijeet is a skilled Salesforce developer with experience in developing and integrating dashboards, data reports, and Salesforce applications. He is also skilled at optimizing processes and flow automation processes, coding, and executing complex project architecture. Read more about us | LinkedIn Profile.