Dataverse: Custom Automations and APIs
Custom Actions and Custom APIs to extend the standard automation capabilities of Microsoft Dataverse
This guide explains how Custom Actions and Custom APIs expand the automation and integration capabilities of Dataverse, offering Power Platform developers and architects full flexibility in managing complex business processes.
Introduction to Custom Automations in Dataverse
Microsoft Dataverse provides multiple standard automation capabilities, such as Business Rules, Classic Workflows, and Power Automate. However, in complex scenarios, these features might not be enough. This is where personalized automations—Custom Actions and Custom APIs—come into play.
Custom automations allow the definition of advanced, reusable business logic that can integrate with other platform components or external systems. Both technologies work closely with the Dataverse data model and API, ensuring security, consistency, and reusability.
Quick Comparison: Custom Actions vs Custom APIs
- Custom Actions: Configurable via interface or code, callable from flows or plug-ins.
- Custom APIs: Modern, REST endpoint-oriented, ideal for integration and microservices scenarios.
- Both can be distributed as part of a Dataverse solution and versioned across environments.
Custom Actions: Modular and Reusable Automations
Custom Actions represent an extension of the traditional Dataverse automation model. Unlike flows or classic processes, they are not automatically triggered by events but must be invoked by other processes or code.
Main Features
- They have no intrinsic trigger: they must be called from Power Automate flows, Business Process Flows, or client/server code.
- They allow defining input and output parameters to exchange data with calling services.
- They automatically create an API method and an event message usable for registering plug-ins or server-side extensions.
In practice, once a Custom Action is created, Dataverse generates an internal endpoint that can be called by flows or plug-ins, facilitating the implementation of shared logic across multiple processes.
Example of Use
A company may create a Custom Action to automatically calculate a personalized discount based on customer type and order volume. This action can be invoked by an approval flow, a plug-in, or a canvas app.
Custom APIs: Personalized Endpoints for Business Logic
Custom APIs are the modern evolution of Custom Actions and allow you to create actual REST-based API methods within Dataverse. Each Custom API can be configured to receive HTTP requests and return structured responses, integrating seamlessly with the Power Platform ecosystem and external applications.
Creation Methods
- Using the Plug-in Registration Tool (included in XrmToolBox or in the official Power Apps CLI).
- Directly from the Power Apps Maker Portal.
- Through C# code or by modifying exported solution files.
Each Custom API can include custom logic written in C# and integrated through plug-ins registered to the event generated by the API creation. This allows for complex operations such as validations, transactions, or communication with external systems.
For more technical details, see the official Microsoft documentation: Custom API - Microsoft Learn.
Architecture and Execution Flow
Custom automations integrate with the Dataverse event-message model. Each time a Custom Action or Custom API is invoked, the system generates a message that passes through the execution pipeline, allowing the insertion of plug-ins or validation steps.
This diagram shows how a request from an application or Power Automate flow travels through the Dataverse infrastructure, triggering the defined logic and finally returning the response to the caller.
Frequently Asked Questions
What are Custom Actions in Microsoft Dataverse?
Custom Actions allow you to create modular and reusable automations callable from flows, APIs, or plug-ins to extend Dataverse's standard capabilities.
What is the difference between Custom Actions and Custom APIs?
Custom Actions are internal calls and part of Dataverse’s event-message model, while Custom APIs introduce personalized REST endpoints ideal for integration scenarios.
Can I use plug-ins with Custom APIs?
Yes. Custom APIs generate an event that can be handled by a plug-in, allowing advanced server-side logic execution in response to API calls.
Explore Dataverse Extensibility in Depth
Do you want to learn how to create plug-ins, custom APIs, and advanced automations? Discover our official PL-400 course and become a certified Power Platform Developer.
 
          