Create a custom action to generate an object from a record
- UpdatedJan 30, 2025
- 3 minutes to read
- Yokohama
- Create Workflows
Generate an object from a User record. Learn how to use an Action output to create an object from record values.
Before you begin
About this task
- Create action inputs for the User record fields First name, Last name, and Email.
- Lookup a User record matching the action input values.
- Create an action output for a contact object.
- Save the contact object as a template.
- Map contact object values to User record field values.
- Test the action with a sample user.
Procedure
-
Create an application to store your work.
Use the Guided Application Creator.For example, create My Application.
-
Navigate to Process Automation > Flow Designer.
The system displays the Workflow Studio landing page.
-
Select New > Action
The system displays the Action Properties dialog.
-
Enter these sample values.
Field Value Name Create Contact Object From User Application My Application Accessible From All application scopes -
Select Submit.
The system displays the Workflow Studio interface.
-
From the Action Outline, select Inputs > Create Input
The system displays a new action input.
-
Configure the action input with these values.
Field Value Label First name Type String Mandatory True -
From the Action Outline, select Inputs > Create Input
The system displays a new action input.
-
Configure the action input with these values.
Field Value Label Last name Type String Mandatory True -
From the Action Outline, select Inputs > Create Input
The system displays a new action input.
-
Configure the action input with these values.
Field Value Label Email address Type String Mandatory False -
From Action Outline, select Outputs > Create Output.
The system displays a new action ouput.
-
Configure the output variable with these values.
Label Name Type Mandatory contact contact Object False - From the row for the contact Object, select Add Child Item.
-
Configure the child item with these values.
Label Name Type Mandatory First name first_name String True - From the row for the contact Object, select Add Child Item.
-
Configure the child item with these values.
Label Name Type Mandatory Last name last_name String True - From the row for the contact Object, select Add Child Item.
-
Configure the child item with these values.
Label Name Type Mandatory Email address email_address String False - From the row for the contact Object, select Toggle Advanced Inputs.
-
From the Advanced Options, select Save As
Template.
The system displays the Save As Template dialog.
- For Enter a Name, enter contact.
- Click Save.
-
Select Exit Edit Mode.
The System displays the output fields you created.
-
Configure the outputs with these values.
Label Value First name [step->Look Up Record step->Record->First name] Last name [step->Look Up Record step->Record->Last name] Email Address [step->Look Up Record step->Record->Email] Note: You can select data pills from the data panel or from the Data Pill Picker button. - Select Save.
-
Select Test.
The system displays the Test Action dialog.
-
Enter these test values.
Input Value First name Abel Last name Tuter -
Select Run Test.
The system runs the action with the test values provided.
-
Select Action has executed. To view the action, click
here.
The system displays the action execution details.
-
Review the runtime value for the action Output data.
The system displays output data in JSON format.For example, sample contact object JSON for the user Abel Tuter.
{ "contact": { "email_address": "abel.tuter@example.com", "last_name": "Tuter", "first_name": "Abel" } }
Result
What to do next