Skip to content

PL-400 developer mechanics ​

Most PL-400 points depend on exact developer mechanics: which plug-in stage, which API family, which connector setting, which PCF manifest key. This page goes through them one primitive at a time.

First Principle: Choose The Right Primitive ​

If you get this layer-choice matrix right, a lot of the exam gets easier.

Requirement shapeDefault answerWhy
Simple model-driven form logic, no code preferredBusiness ruleOOTB UI/business logic for simple conditions
Model-driven app client-side logic, form events, command behaviorJavaScript + Client APIRuns in the client, targets form/controls/navigation
In-transaction server-side business logicPlug-inRuns in Dataverse execution pipeline
Reusable developer-defined operation callable from code or flowCustom APICreates a Dataverse message with request/response contract
Async orchestration / approvals / connector-heavy automationCloud flowGood for orchestration, not in-transaction logic
Long-running or external computeAzure FunctionBetter than plug-ins for long-running work
Surface an external REST API into Power Apps / Power AutomateCustom connectorPower Platform-facing wrapper over external API
Publish outbound Dataverse events to external systemsWebhook, Service Bus, Event Hub, or business eventDepends on sync vs async and listener model
Delta sync between Dataverse and external storeChange trackingThis is the intended delta-sync mechanism

Trap to avoid ​

Do not answer "cloud flow" just because automation is mentioned.
Do not answer "custom connector" just because an external system exists.
Do not answer "plug-in" when the question is really about surfacing an operation into flow/app consumption.


Dataverse Plug-ins ​

Pipeline stages ​

StageNumberTransactionUse it when...
PreValidation10Usually outsideValidate early, cancel before main operation
PreOperation20InsideChange incoming values before commit
MainOperation30InternalNot for normal plug-in steps
PostOperation40After core operationReact after save; response data exists

The rules to know cold ​

  • PreValidation is the best place to reject an operation.
  • PreOperation is where you change the Target before it is written.
  • MainOperation is internal only except special cases like custom API and virtual table providers.
  • PostOperation is where output data and completed state matter.
  • External calls are usually better in PostOperation, often asynchronous.

Execution context ​

The key object is IPluginExecutionContext.

Cold anchors:

  • IPluginExecutionContext
  • InputParameters
  • OutputParameters
  • SharedVariables
  • PreEntityImages
  • PostEntityImages
  • ParentContext

What each collection means ​

  • InputParameters: the incoming operation data. In PreValidation and PreOperation, you can inspect and sometimes change it.
  • OutputParameters: the outgoing response data. These are available after the core operation, so think PostOperation.
  • SharedVariables: pass serializable data from one step to a later step in the same pipeline.

Entity images ​

Use images instead of extra retrievals when the point is comparing old and new values.

Cold rules:

  • No Pre Image on Create
  • No Post Image on Delete
  • Post Image only makes sense in PostOperation
  • Only include needed columns; do not select all columns by default

Organization service inside plug-ins ​

Cold rules:

  • IOrganizationService is for Dataverse SDK-style operations
  • Do not assume every attribute exists on the retrieved entity
  • Defensive pattern: check Contains / avoid blind dictionary access
  • Prefer images over extra retrieve calls when comparing values

Tracing and debugging ​

Cold anchors:

  • ITracingService
  • PluginTraceLog
  • Plug-in Profiler

What matters:

  • Use ITracingService.Trace for real debug breadcrumbs
  • Tracing must be enabled in the environment
  • PluginTraceLog records survive transaction rollback
  • Plug-in Profiler captures execution context and lets you replay in Visual Studio

Profiling sequence ​

  1. Install Plug-in Profiler
  2. Start profiling the registered step
  3. Trigger the operation in the app
  4. Capture the profile row
  5. Replay/debug locally in Visual Studio
  6. Stop profiling

Plug-in performance rules ​

  • Prefer images over retrieve calls
  • Include only needed image columns
  • Avoid unnecessary service calls
  • Be cautious with recursion/depth
  • Keep synchronous logic short and focused

Must-know exam distinctions ​

  • PreValidation = reject
  • PreOperation = mutate
  • PostOperation = react
  • MainOperation = not your normal answer
  • InputParameters["Target"] = incoming entity/message payload

Custom APIs ​

Custom APIs are one of the most important "middle layer" concepts on PL-400.

What a custom API is ​

A custom API creates a new Dataverse message that can be called through:

  • Web API
  • SDK for .NET
  • sometimes workflows / Power Automate, if configured correctly

Function vs Action ​

TypeHTTP shapeMental model
FunctionGETRead-like operation, returns data, no state change
ActionPOSTOperation with side effects or complex inputs

Cold rules:

  • Is Function = true means GET
  • Functions must return data
  • A function with no response property is invalid and can show as 404 Not Found
  • If the custom API must be callable as a workflow action, Is Function must be false

Workflow / Power Automate angle ​

If the exam stem implies "callable from workflow/flow designer":

  • Enabled for Workflow must be true
  • Is Function must be false
  • Parameter types are constrained to workflow-supported types

This is the exact kind of detail you were repeatedly missing.

Bound vs unbound ​

ShapeMeaning
UnboundGlobal operation
Entity-boundOperation runs on one row
Collection-boundOperation targets a table collection

Cold rule:

  • Entity-bound custom APIs have an implicit Target request parameter

Plug-in relationship ​

  • A custom API usually uses a plug-in for main operation logic
  • But it does not need a plug-in if you are using it as a business event shell
  • The plug-in is set as the custom API's PluginTypeId
  • Do not think "register a normal plug-in step" as the execution model for a custom API

Security and visibility ​

Cold anchors:

  • Is Private
  • ExecutePrivilegeName

What they mean:

  • Is Private hides the API from $metadata and generated classes, but it does not make the API impossible to call if someone knows it exists
  • ExecutePrivilegeName lets you require an existing Dataverse privilege to invoke the API

Custom APIs vs custom process actions ​

Exam-safe read:

  • Custom API = developer-first, more control, code-centric
  • Custom process action = older/no-code message extension pattern

If the stem leans developer, modern extensibility, plug-ins, or reusable operation contracts, expect Custom API.


Dataverse Business Events ​

Business events are easy to blur together with plug-ins and webhooks. Do not blur them.

Core idea ​

Business events notify subscribers after the event completes successfully.

Cold rule:

  • Business events are not the answer when the logic must cancel or modify the in-flight operation

That is plug-in territory.

Important relationship to custom APIs ​

  • Custom business events can be created by using a custom API
  • A custom API can exist without plug-in logic if the purpose is event publication
  • Business events expose a message and a web-service endpoint consumers can call or subscribe to

Catalogs and categories ​

If the exam mentions the Dataverse action trigger in Power Automate:

  • Dataverse actions are organized by Catalog
  • then Category
  • then Table name if bound
  • then Action name

This matters when flows trigger on actions.


Platform APIs: Web API vs Organization Service ​

Dataverse Web API ​

Best mental model:

  • REST/OData surface
  • HTTP verbs
  • good for web apps, JavaScript, and integration clients

Cold anchors:

  • POST
  • PATCH
  • @odata.bind
  • Prefer: return=representation
  • OAuth

Organization Service ​

Best mental model:

  • SDK-style .NET service
  • message-based operations
  • richer request/response classes for advanced SDK scenarios

Cold anchors:

  • IOrganizationService
  • OrganizationRequest
  • OrganizationResponse
  • UpdateRequest
  • UpsertRequest
  • EntityReference

When to choose which ​

NeedBest answer
REST integration / JavaScript client / HTTP-first accessWeb API
SDK messages / .NET code / advanced message typesOrganization Service
App or flow needs to call a reusable Dataverse message you defineCustom API

ServiceClient ​

Cold read:

  • ServiceClient is the main .NET Dataverse client wrapper
  • it handles auth setup internally based on connection info
  • it can use public or confidential client flows internally
  • confidential client == app registration / secret or certificate / service principal style auth

@odata.bind ​

This is the exact anchor to know for associating an existing related row during create/update.

Cold rule:

  • Use @odata.bind to connect to an existing related row

Prefer: return=representation ​

Cold rules:

  • Returns data from the created/updated row
  • Useful when you need the response payload
  • Adds extra retrieve cost, so only ask for minimal columns

Optimistic concurrency ​

Cold anchors:

  • UpdateRequest
  • ConcurrencyBehavior
  • IfRowVersionMatches

Cold rule:

  • In SDK code, optimistic concurrency is an UpdateRequest / DeleteRequest concern
  • Use row version matching when the stem is about preventing overwrite of a newer change

429 / retry / throttling ​

Cold read:

  • Dataverse and connectors have throttling/service-protection limits
  • 429 Too Many Requests means back off and retry
  • In Power Automate, retry policies matter
  • The exam is more likely to test the concept than the raw numeric thresholds

Common traps ​

  • Do not answer Web API when the stem clearly wants SDK message features
  • Do not answer Organization Service when the stem is clearly REST/OData
  • Do not answer custom API when the question is just standard CRUD against tables

Data Synchronization: Change Tracking, Alternate Keys, Upsert ​

Change tracking ​

Best mental model:

  • efficient delta sync, not auditing

Cold anchors:

  • RetrieveEntityChanges
  • RetrieveEntityChangesRequest
  • DataToken
  • NewOrUpdatedItem

Cold rules:

  • First request returns the full table snapshot
  • Response returns a version/token for next sync
  • Subsequent requests use that token to return only changes since then
  • For standard tables, Dataverse typically returns new/updated items first, then deleted items
  • If the token is too old, sync breaks and you may need a fresh baseline

What change tracking is not ​

  • not auditing
  • not "who changed what"
  • not a broad analytics history mechanism

If the stem says "synchronize with external system efficiently," think change tracking.

Alternate keys ​

Best mental model:

  • business-meaningful unique identifiers used for integration

Cold rules:

  • Great when external systems do not know Dataverse GUID primary keys
  • Alternate keys are common with Upsert
  • If key data contains / < > * % & : \\ ? +, GET or PATCH based integration breaks
  • Therefore, not every "unique business value" is a good alternate key for API integration

Upsert ​

Cold anchors:

  • UpsertRequest
  • PATCH
  • alternate keys
  • If-Match: *

Cold rules:

  • Upsert = create if missing, update if present
  • SDK side often uses UpsertRequest
  • Web API side often uses PATCH
  • If the URL identifies the record by alternate key, do not also try to update those same key values in the body
  • If-Match: * forces update semantics instead of create-if-missing behavior

How to separate the three ​

NeedAnswer
Efficient delta syncChange tracking
Uniquely identify records without GUIDsAlternate keys
Create-or-update integration patternUpsertRequest / PATCH upsert

Dataverse Events and Service Endpoints ​

The choice matrix ​

RequirementBest default
In-transaction server-side logicPlug-in
Immediate outbound HTTP endpoint callbackWebhook
Durable async Azure messagingAzure Service Bus
Event-stream style Azure listenerAzure Event Hub
Dataverse-native event publication after successBusiness event

IServiceEndpointNotificationService ​

This is a cold anchor term.

Best mental model:

  • bridge used by Azure-aware plug-ins to notify the async service to post pipeline data context to Azure Service Bus

Azure-aware plug-ins ​

Cold rules:

  • Dataverse provides an out-of-box Azure-aware plug-in route
  • You register a service endpoint in the Plug-in Registration Tool
  • You then register a step that identifies the message + table combination
  • The plug-in notifies the async service through IServiceEndpointNotificationService
  • Microsoft recommends asynchronous registration for best system performance

Security anchor ​

  • Azure Service Bus posting uses SAS authorization

Service endpoint registration ​

If the question is about outbound Dataverse integration using Azure messaging infrastructure:

  • think service endpoint
  • think Plug-in Registration Tool
  • think Service Bus / Event Hub / webhook registration

What not to confuse ​

  • Webhook is not the same thing as Service Bus
  • Business event is not the same thing as an in-flight plug-in
  • Plug-in is not the same thing as "publish external event"

Custom Connectors ​

What a custom connector is ​

A custom connector exposes an external API to:

  • Power Apps
  • Power Automate
  • Copilot Studio / other Power Platform surfaces where supported

Normal build sequence ​

  1. Understand the backend API
  2. Have a stable API definition
  3. Choose/import from OpenAPI, Azure service, or Postman
  4. Configure authentication
  5. Add policy templates if needed
  6. Add custom code only if policies are not enough
  7. Test

Authentication choices ​

API styleTypical answer
API key in header/queryAPI Key
OAuth 2.0 / Entra IDOAuth 2.0
Simple username/passwordBasic

Policy templates ​

Best mental model:

  • modify connector behavior at runtime without writing code

Common use cases:

  • route requests
  • set or override values
  • host/path shaping
  • data conversion

Set Host URL ​

This is a repeated exact-term miss.

Cold rule:

  • Use Set Host URL when the backend host endpoint is dynamic and depends on parameters

Important caveat:

  • DLP/custom connector policy evaluation happens before Set Host URL
  • So if the stem hints at governance risk, remember dynamic host rewrite does not change how DLP initially classifies the connector

Custom code in connectors ​

Cold anchors:

  • Script
  • ScriptBase
  • ExecuteAsync

Cold rules:

  • Custom code is used when policy templates are not enough
  • The class must be named Script
  • It must implement ScriptBase
  • Runtime entry point is ExecuteAsync
  • Only one script file is supported
  • Code execution has a time limit; do not treat connector code as a long-running compute layer

OpenAPI extension anchors ​

Cold anchors:

  • x-ms-capabilities
  • x-ms-dynamic-values

What they mean:

  • x-ms-capabilities at operation level can indicate things like chunk-transfer support
  • x-ms-dynamic-values drives dynamic selectable values for parameters from another operation

Connector vs other tools ​

Do not default to custom connector when the real need is:

  • transaction-safe Dataverse business logic -> Plug-in
  • reusable Dataverse message -> Custom API
  • long-running backend logic -> Azure Function

Cloud Flows ​

Dataverse connector triggers and actions ​

Cold areas:

  • trigger filters
  • retry policies
  • run context
  • service principal connections

Trigger filtering ​

Best mental model:

  • reduce noise and unnecessary runs at the trigger, not after the trigger

Cold read:

  • use OData filter conditions for Dataverse triggers
  • select only needed columns
  • do not pull broad payloads if the trigger can already narrow the scope

Run-as behavior ​

For When a row is created, modified, or deleted:

  • Run as can use the user who modified the row or the row owner
  • To save those options, the flow owner needs prvActOnBehalfOfAnotherUser or the Delegate role

Service principal connections ​

Cold rules:

  • Dataverse connector supports user, guest, and service-principal connections
  • Service principal setup requires:
    • Entra service principal
    • client secret
    • Dataverse application user linked to it
    • sufficient Dataverse permissions

Sensitive data ​

Cold anchors:

  • Secure inputs
  • Secure outputs
  • Azure Key Vault

Cold rules:

  • do not hardcode secrets in flows
  • use secure inputs/outputs to hide sensitive data in run history
  • use Azure Key Vault or environment-variable secret references where appropriate

Azure Key Vault secret environment variables ​

Cold anchors:

  • Data Type = Secret
  • Secret Store = Azure Key Vault
  • RetrieveEnvironmentVariableSecretValue

Cold rules:

  • Secret environment variables reference Azure Key Vault rather than storing the secret in Dataverse
  • Power Automate can retrieve the value via Dataverse unbound action RetrieveEnvironmentVariableSecretValue
  • This is the pattern to know, not the exact clicks

Child flows ​

Cold rules:

  • Parent and child should live in the same solution
  • Child flow uses Manually trigger a flow
  • Parent uses Run a Child Flow
  • Parent waits for the child to complete

Retry / throttling ​

Best mental model:

  • 429 or transient connector failures mean retry/backoff is part of the design

The exam is more likely to test:

  • "should there be retry handling?"
  • "should this trigger be filtered?"
  • "should this secret be secured?"

than the exact numeric policy settings.


Environment Variables and ALM ​

Environment variables ​

Best mental model:

  • ALM-friendly configuration values that move with solutions

Cold rules:

  • Values are visible during solution import and pipeline deployment
  • If you remove the value before export, the dev environment can keep it while the exported solution does not ship it
  • Default, current, and target-environment values are distinct concepts
  • Missing current value often means fallback behavior surprises people

Security and ownership ​

  • environmentvariabledefinition is user/team owned
  • environmentvariablevalue permissions inherit from the definition

Reserved flow names ​

Avoid environment variable names:

  • $authentication
  • $connection

Caching / refresh nuance ​

Environment-variable-based data source references can be cached or slow to reflect changes in some scenarios.
Exam takeaway: do not assume that changing a value instantly rewires every consumer everywhere.

Solutions and layering ​

Cold anchors:

  • Managed
  • Unmanaged
  • Active layer
  • Apply upgrade

Cold rules:

  • Build in unmanaged
  • Deploy to higher environments in managed
  • Unmanaged customizations create an active layer that can override managed behavior
  • The last managed import can win or merge depending on component type
  • Staged upgrades can be flattened with Apply upgrade
  • Components with unmanaged layers often do not receive updates cleanly

PCF: Power Apps Component Framework ​

You improved in client scripting, but PCF is still too brittle.

Lifecycle ​

Cold anchors:

  • init
  • updateView
  • getOutputs
  • destroy
  • notifyOutputChanged

What each one means ​

MethodWhat to remember
initinitialize component instance, start setup, request resources
updateViewapp/framework changed data or context; refresh UI
getOutputsreturn changed output values back to framework
destroyclean up listeners/resources when component unloads

Core runtime mental model ​

  • User changes something -> component calls notifyOutputChanged
  • Framework then asks getOutputs for the new value
  • If the platform changes the data -> framework calls updateView

Packaging / deployment ​

Cold anchors:

  • pac pcf init
  • pac pcf push
  • solution packaging
  • build tools / pipeline packaging

Best mental model:

  • pac pcf push is the development/test deployment path
  • solution packaging is the ALM/deployment path
  • for CI/CD, package the control into solutions and use build tools/pipelines

Manifest exactness ​

This is where exam questions like to get annoyingly specific.

Cold anchors:

  • feature-usage
  • uses-feature
  • required="true" / required="false"

uses-feature rule ​

If your component wants a feature such as WebAPI or device capability:

  • declare it under feature-usage
  • then add one or more uses-feature entries

Cold rules:

  • if no uses-feature items exist, feature-usage is unnecessary
  • required="true" means the component requires that feature; unsupported host can cause runtime failure
  • required="false" means you should code defensively and check whether the feature is available at runtime

Exact recurring anchor ​

  • Device.getCurrentPosition

This is the exact kind of thing you can verify in Learn, but you must already know the question is about PCF feature declaration and device capability.

Host support caveat ​

Do not assume every PCF API is available in every host.
Example: context.webAPI availability differs by host, so check support.


Client Scripting and Model-Driven UX Extension ​

This lane improved, but a few exact anchors still matter.

Cold anchors:

  • addPreSearch
  • setFormNotification
  • setNotification
  • showProgressIndicator
  • Xrm.WebApi

What they mean ​

  • addPreSearch: register lookup filtering logic before search
  • setFormNotification: form-level notification
  • setNotification: control-level notification
  • showProgressIndicator: block/wait UX indicator
  • Xrm.WebApi: client-side Dataverse API access

Key separation ​

NeedAnswer
Filter lookup options before user searchaddPreSearch
Show form-wide messagesetFormNotification
Show message on one controlsetNotification
Call Dataverse from client scriptXrm.WebApi

Common async trap ​

Exam-safe read:

  • Xrm.WebApi calls are asynchronous
  • if code checks a variable immediately after starting an async request, that check can run before the result arrives

You do not need full syntax memorized, but you do need to recognize the async bug pattern.


Security Feature Selection ​

These questions are usually about putting the right control in the right layer.

RequirementBest default answer
Grant or restrict table/row privilegesSecurity roles
Protect a specific sensitive columnColumn-level security
Show different forms to different audiencesRole-based forms
Share a row with specific users/teamsRow sharing
Group access and ownership modelTeams / Business units
Limit connector mixing and data movementDLP policies

Cold trap:

  • Do not answer column-level security when the problem is actually form audience or general table privilege
  • Do not answer role-based form when the issue is data protection at the field level

Azure Functions For PL-400 ​

This is usually not the hardest lane, but it matters because it overlaps custom connectors and integrations.

Best mental model ​

Use Azure Functions when the requirement implies:

  • long-running work
  • scheduled or event-driven external processing
  • server-side custom logic outside Dataverse runtime limits

Cold anchors ​

  • scheduled trigger
  • event-driven trigger
  • managed identity
  • HTTP-triggered Azure Function

Exam-safe rules ​

  • If the work is too long or too external for a plug-in, Azure Function becomes much more attractive
  • If the function is being surfaced into Power Platform consumption, the exam often pairs it with custom connector
  • If auth should avoid stored credentials, think managed identity

Say it out loud ​

If you can say these without hesitating, you know the mechanics.

Plug-ins ​

  • "PreValidation rejects, PreOperation mutates, PostOperation reacts."
  • "Use images instead of extra retrieves when comparing old and new values."
  • "MainOperation is not my normal plug-in answer."
  • "Tracing is ITracingService, and profiling replays captured context."

Custom APIs ​

  • "Function is GET and must return data."
  • "Workflow-callable custom API means Is Function = false."
  • "Entity-bound custom APIs have implicit Target."
  • "The plug-in type belongs on the custom API, not as a normal step registration."

Platform APIs ​

  • "Web API is REST/OData; Organization Service is SDK/message-based."
  • "@odata.bind links existing rows."
  • "Prefer: return=representation returns data but costs an extra retrieve."
  • "Optimistic concurrency is UpdateRequest plus IfRowVersionMatches."

Integrations ​

  • "Webhook is immediate HTTP; Service Bus is async durable messaging; Event Hub is event streaming."
  • "Azure-aware posting uses IServiceEndpointNotificationService."
  • "Business events happen after successful completion, not in-flight."

Data sync ​

  • "Change tracking is for delta sync; auditing is not."
  • "RetrieveEntityChanges returns a DataToken for next sync."
  • "Alternate keys are integration identifiers, but certain characters break GET/PATCH use."
  • "UpsertRequest is create-or-update."

Connectors ​

  • "Policy templates first, custom code second."
  • "Set Host URL is the dynamic endpoint policy template."
  • "Connector code uses Script : ScriptBase and ExecuteAsync."
  • "x-ms-capabilities and x-ms-dynamic-values are OpenAPI extension anchors."

Cloud flows ​

  • "Filter at the trigger whenever possible."
  • "Secure inputs/outputs hide secrets from run history."
  • "Child flows belong in the same solution."
  • "Dataverse connector supports service principal connections."

PCF ​

  • "init, updateView, getOutputs, destroy."
  • "notifyOutputChanged tells the framework there are new outputs."
  • "uses-feature declares required capabilities like Device.getCurrentPosition."


Personal study notes written from official documentation. Not affiliated with Microsoft or GitHub. Contains no exam questions.