Work with solutions using PowerShell
The Power Apps checker web API provides a mechanism to run static analysis checks against customizations and extensions to the Common Data Service platform. It's available for makers and developers to perform rich static analysis checks on their solutions against a set of best practice rules to quickly identify problematic patterns. To begin using the Power Apps checker Web API, see Getting started.
The checker service provides the logic for the solution checker feature in the Power Apps maker portal and is included as part of the automation for applications submitted to AppSource. In this section, we describe how to run a best practice solution analysis of your customizations and extensions in your DevOps pipeline to verify the quality of your solution component.
Tip #1: Consider using the PowerShell module, Microsoft.PowerApps.Checker.PowerShell, instead of using the web API. The module is a fully supported tool that's available in the PowerShell Gallery. The current restriction is that it does require Windows PowerShell in your project pipeline. If you're unable to meet this requirement, interacting with the web APIs directly will likely be the best approach.Tip #2: You can easily manage solutions using PowerShell as part of your custom automation. Refer to the Microsoft.Xrm.Data.PowerShell module and sample code. For example:
Export-CrmSolution -conn $conn -SolutionName "MySolution" -Managed -SolutionFilePath "C:\temp" -SolutionZipFileName "MySolution_Managed.zip"
Import-CrmSolutionAsync -SolutionFilePath c:\temp\mysolution.zip -ActivateWorkflows -OverwriteUnManagedCustomizations -MaxWaitTimeInSeconds 600
In addition, there is a checker task in the Azure DevOps build tools include a checker task. For more information about using that task in your build pipeline, see Quality check.