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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Business Central forum

Consume Webhook Request in BC

(1) ShareShare
ReportReport
Posted on by 4

Hi all,

I'm currently trying to consume a WebHook Request in Business Central.

Unfortunately I haven't found any solution, yet.

In one of the last updates of business central Webhooks became available in Business Central to give a client the opportunity to be notified of changes to entities in Business Central.

Unfortunately this is not the direction i need for my case.

Has anyone some advices for me?

Best regards,

Hendrik

Categories:
  • Suggested answer
    Stefano Demiliani Profile Picture
    37,172 Most Valuable Professional on at

    Webhooks are for definition way to get notified if an entity changes in Dynamics 365 Business Central.

    To use WebHooks:

    docs.microsoft.com/.../dynamics_subscriptions

    community.dynamics.com/.../webhooks-don-39-t-call-us-we-will-call-you

  • Hendrik244 Profile Picture
    4 on at

    Hi Stefano,

    thanks for your answer, but unfortunately I need it the other way around. Because I don't want somebody to get notified, when I do something in BC, but do consume a Webhook Request.

    To make this clearer:

    I want to communicate between my bc365 app and a registration/authorization service from the internet.

    When the registration was successfull, this service is posting a webhook request to a specified "callback url" with some information about the authorization.

    So I need a opportunity to cosume this webhook request in BC to process the included information.

    This is the documentation about using business central webhooks to give a client the opportunity to be notified of changes to entities:

    docs.microsoft.com/.../dynamics_subscriptions

    Now you know what I meant?

    /Hendrik

  • Stefano Demiliani Profile Picture
    37,172 Most Valuable Professional on at

    Ok so you need the opposite way: you have an external webhook and you need to subscribe to it.

    Never tryed this but I think you can create for example a webhook listener, host it in Azure and call it from D365BC code with HttpClient.

  • Hendrik244 Profile Picture
    4 on at

    Thanks for your answer.

    I was thinking about a webservice "listener-service" to run in BC.

    But I don't know, if this is possible and how to do something like that.

  • meile_l Profile Picture
    5 on at

    Have you found a solution for your problem yet?

  • AA-27041049-0 Profile Picture
    2 on at
    Hi Hendrik,
    To create a WebHook Listener in BC, you need to create a Codeunit and expose it through the Web services page. There is no standard Webhook Listener available since each event is unique, so you must write a codeunit specific to your requirements (the events you are going to receive).
     

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard > Business Central

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans