Tips & Tricks | Power Automate [Cognitive Services]

Using Power Automate to automate workflow to extract information from pictures and map it to a field in the common data services.

Below is an example of a flow to extract ID Number from a scanned passport or National ID.

  
Azure Cognitive Services

we are going to use Cognitive Services for OCR.
•  Open https://portal.azure.com/
•  Search for Cognitive Services
•  Click Create



•  Fill Name "ex: OCR Cognitive Services"
•  Fill Form

•  Navigate to created Cognitive Services
• Click on Keys and Endpoint
• Copy Key and Endpoint




  
Power Automate

Using Power Automate to create a flow to extract information from the image.
•  Navigate to https://flow.microsoft.com
• Create a new flow
• Select Computer Vision API connector
• Select Optical Character Recognaition (OCR) to Text

•  Enter Connection Name "ex: Cognitiev Services Connection"
• Enter Key
• Enter Site Url
• Click Create
•  Select Image source "URL or Image Content" 
   if you have if from previous step in the flow
• Enter URL Sample ID
•  To Get Index for searched text:
add(indexOf(body('Optical_Character_Recognition_(OCR)_to_Text')?['text'],'ID Number / الهوية رقم'),22)

•  To Get substring in one step
substring(add(indexOf(body('Optical_Character_Recognition_(OCR)_to_Text')?['text'],'ID Number / الهوية رقم'),22),19)

Popular posts from this blog

Tips & Tricks | Solution Layers [Remove Active Customization]

Tips & Tricks | Power Apps Community Plan [Development Environment]