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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Form Recognizer Model ...
Power Automate
Answered

Form Recognizer Model Id not found

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi all,

 

I am trying to use the Form Recognizer connector with no luck.

I trained a few models, with the Cognitive Services API using my Cognitive Services instance. It works fine, I am able to query all my models to analyze new documents using my Model Id, with the API.

 

Now I want to use these models in Flow using the Analyze Document connector, but I can't access my model Id's.

 

With the Get Models connector, no models in the list. And obviously when I try Get Model, the Model Id is not found....

Any idea of what's going on?

 

Thanks!

Ben

 

 

Flow_FormReco.PNG

 

 

 

Categories:
I have the same question (0)
  • v-litu-msft Profile Picture
    Microsoft Employee on at

    Hi @Anonymous,

     

    Sorry, I can't test the Get models action cause account limitation.

    But I can give some advice:

    1. You can check the Model location whether correct.

    2. Try to use the Train Model action by input the model ID to check whether it work.Annotation 2020-05-12 162118.jpg

     

    Best Regards,
    Community Support Team _ Lin Tu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

  • Verified answer
    Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi,

    I have the same problem and so far, I think its an issue with the Form Recognizer action / connector.

    I'll show with the "Get Keys" example, although I have tried with other actions:


    2020-05-19_20-32.png

     

    I get the same error as you, but if I try to make the request directly through the API I get a valid response:

     

    2020-05-19_20-46.png

    I've made sure that the connector to Form Recognizer is correctly configured to the same host used in the HTTP request above


    Something like this:

     

    2020-05-19_20-57.png

     

    Can you try making the request through the API to check if you (maybe) have the same issue as me or not?

    In your case, your HTTP request (same as "Get Model") should be "https://{endpoint}/formrecognizer/v2.0-preview/custom/models/{modelId}"
    (endpoint is https://{resource name}.cognitiveservices.azure.com)

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @Anonymous ,

     

    Thanks for your message, yes I was thinking using the http connector as well to make the API call rather than using the From Recognizer connector.

     

    I'd tried what you suggested and it worked! I can query the model I built through the API.

    I think I am going to go that way then.

     

    And about this Form Recognizer connector, I am wondering if it doesn't work because I am on the free Tier for my cognitive services instance. Are you on free tier as well?

     

    Cheers,

    Ben

  • MikeD1 Profile Picture
    11 on at

    Were you ever able to input a file through your model and extract the tags through Flow?  I am running into the same issues with trying to run my model on a file through flow.   I was able to query the model through the HTTP call, but unsure exactly how to have it analyze a new file.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    @Anonymous 

    Sorry for the late response. I am also on the free tier for Cognitive Services. I think the problem with the connector is that it's not updated to use the most recent version of the API. Check the answer here by Neta: https://stackoverflow.com/questions/61504780/adding-azure-logic-app-step-for-form-recognizer-2-0-has-issue-with-built-in-conn/61505963#61505963

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    @MikeD1 
    I actually got it to work. Might not be the best way but hey, if it works...
    Just for reference, check this API documentation for the form recognizer. It was very helpful to me: https://westus2.dev.cognitive.microsoft.com/docs/services/form-recognizer-api-v2/operations/AnalyzeWithCustomForm

    In short, what I did was:

     First, call the API (in my case, the file was in an email attachement)

    b_e_0-1597471658329.png

    Then chek the "statusCode" of the response. I was looking for the "202" response, meaning that the request was accepted and it would be worked on. That same response will have the "Operation-Location" which is a call to "analyzeresults"

     

     

    As said in the API docs, you can query the "Operation-Location" to track the progress, so that's what I did. I created a "Until" loop that kept sending another HTTP request (after a delay)

     

     

    This loop was untill the response was either "succeded" or "failed"

    2020-08-15 07_25_44-Outputs - Microsoft Azure.png

    In this same responde I had the results

    2020-08-15 07_28_24-Outputs - Microsoft Azure.png

    After this I just parsed the results and I could work with them as I needed.

    Hope this helps somehow

  • MikeD1 Profile Picture
    11 on at

    @Anonymous 

     

    Thanks for the help, this is helpful.  I did read the documentation and I may be having an issue with syntax.  If I set the "body" of the HTTP post as you I get an error:

     

    Invalid request body. analyzeJsonRequest is not valid.

     

    Here is my post:

     

    MikeD1_0-1597684252740.png

    When I run this code I get this:

     

    MikeD1_1-1597684317145.png

     

    -Which appears that the attachment content is empty.  The "Get Attachment" operation does show content type.  This might be getting off topic and I may need to post this on it's own.  Thanks for the help though!

     

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 605

#2
Valantis Profile Picture

Valantis 340

#3
11manish Profile Picture

11manish 284

Last 30 days Overall leaderboard