After the Document AI Apex Action element, click the + button, search and select Action.
Search and select the second Apex class you created in Step 3 - Create Apex Classes: de_ExtractDocumentAIDetails.
Configure the action:
Label: Handle JSON Output
Set Input Values:
Document AI JSON or Raw Data: Select the output from the previous Apex action (Outputs from Document AI Apex Action) and then select Extracted Data (JSON).
6. Create a Flow Element to Display Extracted Data
With this flow element, you can review and edit the extracted data before it updates the Contact record.
After the Handle JSON Output element, click the + button, find and select Screen.
Select Screen.
In the Components tab, find and select Text.
In the Properties tab, set the component label, for example: First Name.
Under Default Value find and select the corresponding Apex value from the second Apex class you created: Extract Resume Details with Document AI. For example: Outputs from Handle_JSON_Outout > First_name.
Click Finish.
Repeat steps 3-5 for each component.
Label
Map to Apex value
First Name
(from Apex output)
Last Name
(from Apex output)
Email Address
(from Apex output)
Phone Number
(from Apex output)
Street Address
(from Apex output)
City
(from Apex output)
State or Province
(from Apex output)
Country
(from Apex output)
Pin Code or Zip Code
(from Apex output)
Summary of Qualifications
(from Apex output)
After you have on your screen a text field for each of these items, click Done.
7. Create a Flow Element to Update Contact Record
After the Screen** element, click the + button.
Find and select Update Records.
Configure the element:
Label: Update Contact Record
How to Find Records to Update: Specify conditions to identify records, and set fields individually
Object: Contact
Filter Contact Records:
Field: Contact ID
Operator: Equals
Value:recordId
Set Field Values for the Contact Record: Map each field in the table to the corresponding output from the Screen element. For example: For Mailing City Select Raw Output from Document AI > City.
Contact Field
Screen / Source Value
MailingCity
City
MailingState
State or Province
MailingCountry
Country
MailingStreet
Street Address
MailingPostalCode
Pin Code or Zip Code
Description
Summary of Qualifications
Email
Email Address
MobilePhone
Phone Number
Click Save to save the element.
Click Activate to make the flow available for use.