Previous Post - Call Azure Function using Console Application – Part 4
Note - This blog will not focus on plugin creation.
Pre-Requisite -
i) Create an entity named "Test" with 2 columns as below.
ii) Create and register plugin on entity "create" event
Plugin triggered on record creation will send the request to the Azure Function and the response will be updated on the source record.
Step 1 – Create a Class Library (.Net Framework) Project
from your Visual Studio.
Add a class “StudentDetail” and data member “name”. This data member will contain the request from Target (Test Entity record).
Step 2 – Add a method “CallingAzureFunction” to “DemoClass”
Step 3 – Add below code to the “Execute” method of plugin named “DemoClass”.
Step
Note: As we have used external assembly "Newtonsoft.json", to register plugin assembly in Sandbox Mode will require DLL Merge.
Refer to Post - D365 Plugin : Merge External Assemblies using IL Merge
Step 5 – After Successful registration of step, go to “Test" entity and create record.
Lets jump on to Part 5.2 - Call Azure Function from Dynamics 365 via Power Automate
Happy Learning, LET'S SHARE !
No comments:
Post a Comment