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

Community site session details

Session Id :
Small and medium business | Business Central, N...
Answered

Best practices Integration events

(1) ShareShare
ReportReport
Posted on by 66

Hi, I have a project and I want to add integration events, but I have two questions. What are the best practices for using integration events?

1) Can we add all integration events in a codeunit and call them in every procedure where we want to have an integration event or is better to add in every object separately.

2) How do I know if I need to add an integration event in my code? My code is well structured in procedures, so I’m planning to add an integration event at the beginning and one at the end of the procedure, but how do I know if I need integration events somewhere else, like in triggers etc.

thanks in advance
I have the same question (0)
  • Verified answer
    Gokulavasan Srinivasan Profile Picture
    44 on at
    Best practices Integration events
    Hi,
     
    Can we add all integration events in a single codeunit?
    It's better to add integration events directly in the object where they are relevant, rather than putting them all in a single codeunit.
    So,that the events will be closely tied to the specific logic they relate to and easier to understand and maintain.
    Note: If you have shared logic used across multiple objects, it's better to use a dedicated codeunit for those specific events.
     
    How do I decide where to add integration events?
    It's good to add events at the start and end of a procedure.
    Additionally, in cases like conditional blocks, triggers, or decision points, you can add integration events wherever you expect a need for extensibility or external interaction with your code logic.
     

    Feel free to reach out here if you have any further questions about this.

    Thanks,

    Gokul

    Congruent Infotech - https://www.congruentsoft.com/

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…

Andrés Arias – Community Spotlight

We are honored to recognize Andrés Arias as our Community Spotlight honoree for…

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
Sumit Singh Profile Picture

Sumit Singh 3,055

#2
Sohail Ahmed Profile Picture

Sohail Ahmed 2,682 Super User 2025 Season 2

#3
YUN ZHU Profile Picture

YUN ZHU 2,209 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans