Posts

Bypass Power Apps Consent Prompts Using PowerShell

Image
When a user opens a Power App for the first time, they are often presented with a consent form asking for permission to access data sources or APIs used by the app. This Canvas API consent form can be disruptive, especially in scenarios where the app is intended for a broad user base or part of an automated deployment. The consent form can create unnecessary friction, requiring every user to individually approve permissions. Fortunately, there’s a way to bypass this pop-up consent form using PowerShell. In this blog post, I will guide you through automating the process of bypassing the Power Apps consent form using PowerShell. The goal is to either allow users to select an app from a specific environment or use a configuration file to perform actions on multiple environments. This automation can be particularly useful for initial deployments of a new app or to ensure all apps currently have this applied. Background: Bypassing Power Apps Consent Before diving into the PowerShell s

Custom Auto Number in Dataverse with Fiscal Year-Based Incrementing Using Plugin Code

Image
In many scenarios, businesses require custom auto-numbering for records in Microsoft Dataverse that go beyond the default functionality provided. In this article, I’ll walk you through a solution that involves creating a custom auto-number field without using the out-of-the-box auto-numbering feature in Dataverse. Instead, we’ll use a combination of a custom entity as a counter and a plugin that triggers on the pre-create event of the target table. The Approach For this solution, we’ll create a custom table called Fiscal Year Counter . This table will manage our numbering sequence based on the fiscal year. The idea is to dynamically generate invoice numbers that reset each fiscal year, providing a high level of customization to fit your organization’s unique fiscal calendar. The Fiscal Year Counter Table Setup First, create a table named Fiscal Year Counter with the following fields: Name (String): To store the fiscal year name, such as “FY2024.” Start Date (Date Only, Time

Connecting the Paconn CLI Tool to GCC, GCCH, and DoD Environments for Power Platform Connectors

Image
When working with the paconn CLI tool to create and manage custom connectors in the Power Platform, it’s essential to configure your environment settings properly, especially when targeting different government cloud environments like GCC, GCC High, and DoD. In this article, we’ll guide you through setting up these configurations, including creating a connectionSettings.json file for each environment, downloading a custom connector, and updating the connector’s settings for seamless management. Prerequisites Azure Subscription : You need an active Azure subscription to register an application. Paconn CLI Tool : Ensure you have the paconn CLI tool installed. You can install it using Python’s pip: pip install paconn Step 1: Create an Azure App Registration Begin by registering an application in Azure Active Directory (Azure AD) that will serve as the identity for your paconn operations. Navigate to Azure AD : Sign in to the Azure portal and go to Azure Active Directory .

Overcoming OpenAPI 2.0 `multi` CollectionFormat Challenges in Power Automate Custom Connectors

Image
Integrating APIs into Power Automate flows often requires creating custom connectors, a process that can encounter challenges with certain API specifications. Specifically, the OpenAPI 2.0 specification allows array and multi-value parameters to be passed in various formats, including the multi collection format. This format is particularly troublesome for Power Automate’s Custom Connector wizard, which does not support it natively. This article outlines the issue and provides a detailed workaround using custom code components and modifying input parameters, ensuring seamless API integration. The Challenge with multi CollectionFormat The OpenAPI 2.0 specification introduces several collection formats for array parameters, with multi being one of them. This format allows multiple values for the same parameter to be passed by repeating the parameter’s name in the query string, which is not directly supported in Power Automate Custom Connectors. Attempting to import an OpenAPI speci

Installing PowerShell Modules in Firewalled and Air-Gapped Systems

Image
Managing IT environments with limited or no internet access, such as firewalled systems or air-gapped setups, presents unique challenges. One of the critical tasks in such environments is the installation and usage of PowerShell modules, which often require internet access for download and updates. This guide provides a method to facilitate the offline installation of PowerShell modules using custom scripts and includes a practical example of managing Power Platform environments by limiting developer environments. Background Firewalled systems have restricted internet access, necessitating special methods to manage and configure software. Air-gapped systems are completely isolated from the internet, making direct downloads impossible. In such environments, administrators need to manually transfer and install PowerShell modules to manage various tasks effectively. Step-by-Step Guide Step 1: Prepare the PowerShell Module for Offline Use The first script, PowerShellModuleOfflinePack