Microsoft has introduced Translytical Task Flows (Preview) in Power BI — a groundbreaking capability that brings transactional actions directly into the analytical environment. With this new feature, users can initiate tasks such as creating, updating, or deleting records, and even trigger automated workflows — all within a Power BI report. This marks a major shift in Power BI’s functionality, transforming it from a purely analytical tool into a platform that also supports real-time interaction and operational decision-making. By enabling users to move seamlessly from insight to action, Power BI now empowers more dynamic and efficient business processes without the need to switch between applications.
A sales manager frequently monitors a Power BI dashboard that aggregates incoming leads from various sources such as web forms, marketing campaigns, and events. This dashboard provides real-time insights into critical lead metrics, including source, score, status, owner, and engagement level.
Previously, when the manager identified a high-potential lead meeting predefined qualification criteria such as a lead score above 80, confirmed budget, and established contact, they had to switch to Dynamics 365 or another CRM system to manually qualify the lead. This context switching disrupted the analytical workflow, reduced efficiency, and delayed timely follow-ups.
With the introduction of Translytical Task Flows in Power BI, this process becomes seamless. The sales manager can now take direct action — such as qualifying the lead—without leaving the Power BI report. This embedded transactional capability not only accelerates decision-making but also ensures a more fluid and productive user experience by integrating insights and actions in one unified interface.
Follow the steps below to set up the required features and dependencies that allow Translytical Flows to function.
Now the required Power BI desktop and fabric settings have been enabled.
After enabling the necessary features in Power BI and Microsoft Fabric, the next step is to create User Data Functions within Fabric. Follow the steps below to configure them properly.
import fabric.functions as fn import requests import json udf = fn.UserDataFunctions() # Function to get OAuth token using Client Credentials Flow def get_token(client_id: str, client_secret: str, tenant_id: str) -> str: token_url = f"https://login.microsoftonline.com/{tenant_id}/oauth2/v2.0/token" headers = { 'Content-Type': 'application/x-www-form-urlencoded' } body = { 'client_id': client_id, 'client_secret': client_secret, 'grant_type': 'client_credentials', 'scope': '<Environment URL>/.default' } response = requests.post(token_url, headers=headers, data=body) response.raise_for_status() return response.json()['access_token'] # Main UDF to qualify a lead in D365 @udf.function() def qualify_lead(topic: str,leadid:str) -> str: client_id = "<Client ID>" client_secret = "<Client Secret>" tenant_id = "<TenantID>" environment_url = "<Environment URL>" try: # Step 1: Get token token = get_token(client_id, client_secret, tenant_id) headers = { 'Authorization': f'Bearer {token}', 'Accept': 'application/json', 'OData-MaxVersion': '4.0', 'OData-Version': '4.0' } # Step 3: Update lead (e.g., set statecode = 1) update_url = f"{environment_url}/api/data/v9.2/leads({leadid})" payload = { "statecode": 1 # Example: mark lead as Qualified or Inactive (depending on your config) } patch_headers = headers.copy() patch_headers["Content-Type"] = "application/json" patch_headers["If-Match"] = "*" # Optional for force update patch_response = requests.patch(update_url, headers=patch_headers, json=payload) if patch_response.status_code in [204]: # 204 = success (no content) return f"Lead with subject '{topic}' has been Qualified." else: return f"Failed to update lead: {patch_response.status_code} - {patch_response.text}" except requests.exceptions.HTTPError as http_err: return f"HTTP error: {str(http_err)}" except Exception as e: return f"Unexpected error: {str(e)}"
Once the User Data Function has been published to the workspace, the next step is to build a Power BI report and execute the function. Follow the steps below to implement this integration and fulfill the requirement.
SelectedLeadID = SELECTEDVALUE(‘lead'[Lead])
SelectedLeadTopic = SELECTEDVALUE(‘lead'[Topic])
These measures will be passed as parameters to the data function.
While configuring the button action, ensure that you map the parameters required by the function.
This ensures that the function receives the correct context based on the selected row in the table.
With this setup, managers can now qualify leads directly from the Power BI report, eliminating the need to switch between systems. This enhances productivity and streamlines the lead management process.
Translytical Task Flows in Power BI mark a major step forward, allowing users to move from insight to action without leaving their reports. By embedding transactional capabilities, Power BI now enables real-time updates, workflow triggers, and automation, streamlining decision-making and improving business responsiveness.
The post Building Translytical Flows in Power BI Reports first appeared on Microsoft Dynamics 365 CRM Tips and Tricks.
Original Post https://www.inogic.com/blog/2025/06/building-translytical-flows-in-power-bi-reports/