web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Suggested Answer

Invoking a web hook from a plugin

(0) ShareShare
ReportReport
Posted on by 146

Hi,

I'm trying to invoke a web hook from a plugin, which works successfully but the string returned from IServiceEndpointNotificationService.Execute is null.


web hook:
 public static async Task<HttpResponseMessage> Run([HttpTrigger(AuthorizationLevel.Function, "post", WebHookType = "genericJson", Route = null)]HttpRequestMessage req, TraceWriter log)

just returning:
            var contextJson = await req.Content.ReadAsStringAsync();
            var context = contextJson.GetContext();
            return req.CreateResponse(HttpStatusCode.OK, "Created");

I'm calling the web hook from the plugin with this line:

 cloudService.Execute(new EntityReference("serviceendpoint", endpoint.Id), Context);

I can see in my plugin traces and azure logs that the function is being hit and returning the right message (also seen from postman) but when it gets back to the plugin the response message is null.


The plugin is running synchonously, tried on pre-operation and post-operation but no difference.

Any ideas?

Thanks

I have the same question (0)
  • Suggested answer
    Wahaj Rashid Profile Picture
    11,321 on at
  • Davina Sungum Profile Picture
    146 on at

    Thanks Wahaj, I have updated my post with the correct information with the response message being null and will leave this open incase there are any other suggestion (as well as you looking at it on the other thread)

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Microsoft Dynamics 365 | Integration, Dataverse, and general topics

#1
Martin Dráb Profile Picture

Martin Dráb 46 Most Valuable Professional

#2
Pallavi Phade Profile Picture

Pallavi Phade 33

#3
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 28 Super User 2025 Season 2

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans