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 Apps / Get PowerApps Error Logs
Power Apps
Answered

Get PowerApps Error Logs

(0) ShareShare
ReportReport
Posted on by 8

Is there any way to get PowerApps error logs via API or something else? I would like to get the error logs of the PowerApps.

Categories:
I have the same question (0)
  • Ramole Profile Picture
    Super User 2024 Season 1 on at

    Hi @Kamlesh780 
    Am not aware if there is a API for that but here is an example explained by Shane Young which you can create a SharePoint list to handle and capture all errors on your app 
    Power Apps OnError to capture, suppress, and report all errors 

  • v-xiaochen-msft Profile Picture
    on at

    Hi @Kamlesh780 ,

     

    At my knowledge, we can use Application Insights to get powerapps error logs.

    https://sharepains.com/2022/08/09/power-apps-azure-application-insight/

     

    Best Regards,

    Wearsky

  • Kamlesh780 Profile Picture
    8 on at

    Hi @v-xiaochen-msft ,

    Thank you for your response.

    But I cannot use upcoming features (preview, experimental, or retired) in my project.

  • Kamlesh780 Profile Picture
    8 on at

    Hi @Ramole ,

    Thank you for your response 😊 

    This is the good one, but I have a few existing PowerApps and want to get error logs for all existing apps without updating them. I would like to get error logs by providing a PowerApp ID.

  • Ramole Profile Picture
    Super User 2024 Season 1 on at

    @Kamlesh780 

    Easier way to do it is hard coded on OnAppStart and added when patching to list you created for the error to capture so it will also added if any error occurs 

  • Verified answer
    Ramole Profile Picture
    Super User 2024 Season 1 on at

    @Kamlesh780 
    If you need an example 
    Add this AppOnStart

    Set(
     gblAppGlobalName,
     {
     ApplicationName: "My Project Software",
     ApplicationID: "17718e8c-f2e0-40e1-8be0-f1ab03e73ef7",
     SessionID: Text(
     Now(),
     "ddmmyy-hhmmss"
     )
     }
    );
    

    Reuse gblAppGlobalName example to get app name  gblAppGlobalName.ApplicationName

    testglobal.PNG

    Backend 
    SharePoint
    BackEnd.PNG

     ErrorCapture.PNG
    Patch

    Set(
     gblError,
     Patch(
     'Error Log',
     Defaults('Error Log'),
     {
     
    ControlName: "Test",
     User: $"{gblCurrentUser.Title}. at{Now()}.",
     ApplicationName:gblAppGlobalName.ApplicationName,
     ApplicationID:gblAppGlobalName.ApplicationID,
     SessionString:gblAppGlobalName.SessionID
     }
     )
    );
    If(
     IsBlankOrError(gblError),
     Error(
     {
     Message: "Patch failed",
     Kind: ErrorKind.GeneratedValue,
     Source: "Button25"
     }
     )
    )

     

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 Apps

#1
WarrenBelz Profile Picture

WarrenBelz 739 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard