web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / OCR to text Image Cont...
Power Automate
Unanswered

OCR to text Image Content field

(0) ShareShare
ReportReport
Posted on by 4

Hi, I am trying to get the Flow step "Optical Character Recognition (OCR) to Text (preview)" to work.

There are 2 fields you have to fill in, Image Source and Image Content.

When I set the Image Source to Image URL, everything is fine and my cognitive services OCR works.

The problem is when I set the Image Source to Image Content, I don't know what to put in the associated Image Content field.

I take it the Base64 image string should go in here?

Does it need any extra formatting around the Base64 string?

I've tried lost of combinations but can't get any to work.

Thanks, and apologies but I can't suss how to put a screenshot in this post.

Categories:
I have the same question (0)
  • heywoodheywood Profile Picture
    4 on at

    Here's the screenshot - think my ad-blocker messed it up earlier.

    So it's the Image Content field I don't know how to populate.  Thanks! 

    Automate.jpg

  • Verified answer
    RayHogan Profile Picture
    10 on at

    You can use a base64 representation of your image, so long as the content type is application/octet-stream.

     

    Syntax:

     

    {
     "$content-type": "application/octet-stream",
     "$content": "base 64 goes here"
    }

     

     

    Sample:

     

    {
     "$content-type": "application/octet-stream",
     "$content": "iVBORw0KGgoAAAANSUhEUgAAASQAAAC3CAIAAAA0HrTiAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAcRSURBVHhe7do7ctzGGgZQ8q6FdODSCsYrIJ04UnozKhQTZQ6dOZFCMbupIyUWV2CuQOXA5F50gQbIQQ/mAQxnPtGlc6psEa/uH48PaIA8/fr16wlwfP/p/wWOTNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRNggRN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Yy+h1Ypm1u1jrdL9/KI3X6F+ryGOoO3uAh9yyHame2nUd4nu7q7UcMvfPrdtZguF85cAGzTKi2OzGzBq3fxj6f/utB8/3fzZ5vfQvr4/npzV5Z65Xb1zbVhdKdov41omy64Tqa41DtzLX7CM/RHZrxA7oEaP3eHbaAWSZVe/FuzWhrpvaXcsf+a4p9wtanrd+5+hJsboJrxhhlg5ubeVlr76dPA8f2d5rVWGLVYvGl/XuB8vPDh/+2az9+q+je/ao3zart9Skaz9zZzhR7JHbKEZ6sv3rHp6Gco/WVPbuA7hdwe7wFTKy2Gfw06Wtep+vvKk2vU9/12xM5/8vAXP2dYotyE1m5t3Rfex9nDkcVzbx2cvX7ar/K+BZVq/vqeult/rZbVms3GtQx7mhY5Hj5culgyY6ZrcGCUsaUL9CrzdYHs1hta9hps2I7+bR0wuZLpaENRQ4bKusN2nxeAd3W1RoDz6+2NyyyNepwc09daxu6OpTT5r+usuNq7hzNSLvZ++gfo8ELstcwcr6NwwH4bmTCJmuQCVv5uiFrfOdS72zw3Qu9swHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBiHCBhEnJ/8HRKWZ8uaKPzUAAAAASUVORK5CYII="
    }

     

     

    Birds eye of my Flow:

    image.png

     

    I am storing the JSON as a string variable:

    image.png

     

    And then using the JSON() function, I can insert it into my OCR action:

    image.png

     

    Final variable in my Flow was just so I could see the output of the OCR action.

     
  • heywood1 Profile Picture
    5 on at

    Thanks Ray, I love you.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard