{"title":"Business events on Business Central (preview)","url":"https://jonas-paprotka.de/docs/dev-itpro/developer/business-events-overview/","by":"JOP-AL","license":"Copyright (c) Microsoft Corporation. CC BY 4.0, https://creativecommons.org/licenses/by/4.0/; code samples MIT. From https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/business-events-overview, MicrosoftDocs/dynamics365smb-devitpro-pb at 828b6ee (2026-11-19). Changed: includes filled in, links to this site, and for agents shortened without dropping a fact.","credit":"Microsoft Corporation, CC BY 4.0","origin":"https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/business-events-overview","source":{"name":"Business Central developer and IT pro docs","repo":"https://github.com/MicrosoftDocs/dynamics365smb-devitpro-pb","commit":"828b6ee72fcd75755627cd6011f3d20899217ab2","date":"2026-11-19"},"checked":"2026-11-19","description":"Business events provide our partners and customers a mechanism for notifying and triggering their external systems when actions are done on Business Central","date":"2025-04-23","meta":{"topic":"overview"},"outline":[{"level":1,"title":"Business events on Business Central (preview)","slug":"business-events-on-business-central-preview","at":0,"chars":16007},{"level":2,"title":"Introduction","slug":"introduction","at":523,"chars":1552},{"level":2,"title":"Prerequisites and step-by-step guidelines","slug":"prerequisites-and-step-by-step-guidelines","at":2075,"chars":3682},{"level":2,"title":"Business Central catalog of business events","slug":"business-central-catalog-of-business-events","at":5757,"chars":2865},{"level":2,"title":"Connect Business Central to Dataverse","slug":"connect-business-central-to-dataverse","at":8622,"chars":1600},{"level":2,"title":"Refresh Business Central catalog of business events","slug":"refresh-business-central-catalog-of-business-events","at":10222,"chars":681},{"level":2,"title":"Query Business Central catalog of business events in Dataverse","slug":"query-business-central-catalog-of-business-events-in-dataverse","at":10903,"chars":911},{"level":2,"title":"Build and install an extension for custom business events","slug":"build-and-install-an-extension-for-custom-business-events","at":11814,"chars":2462},{"level":2,"title":"Query Business Central catalog of business events in non-Dataverse systems","slug":"query-business-central-catalog-of-business-events-in-non-dataverse-systems","at":14276,"chars":1731},{"level":3,"title":"Query Business Central catalog of business events","slug":"query-business-central-catalog-of-business-events","at":14725,"chars":1282}],"text":"# Business events on Business Central (preview)\n> IMPORTANT\n> Some or all of the functionality noted in this article is available as part of a preview release. The content and the functionality are subject to change.\nIntegrating with Dataverse enables Business Central to interact with other apps in its ecosystem through business events. This article gives an introduction to the new business events feature, the prerequisites, and step-by-step instructions to preview it, and its current limitations/future improvements.\n## Introduction\nThere are four types of complementary app/system interactions between Business Central and Dataverse:\n Data sync that replicates data between Business Central and Dataverse\n Virtual tables in Dataverse via Business Central API for (Create/Read/Update/Delete) operations\n Data change (CUD) events\n Business events\n<https://learn.microsoft.com/dynamics365/business-central/dev-itpro/developer/media/four-complementary-interactions.png#lightbox>\nBusiness events provide our partners and customers a mechanism for notifying and triggering their external systems (Dataverse and non-Dataverse) when actions are done on Business Central. The external systems can react and perform other actions in response. With Dataverse, partners and customers can use Power Automate to subscribe to Business Central for its business events and react on other apps in its ecosystem, such as Dynamics 365 Sales or Customer Service, and others built using Power Apps. They can also react on non-Dataverse systems, such as non-Microsoft warehouse management, fulfillment, and e-invoicing services.\n![Shows the Business Central events interaction with Dataverse]<https://learn.microsoft.com/dynamics365/business-central/dev-itpro/developer/media/introducing-business-events.png#lightbox>\nTo learn more about Business Central and Dataverse integration, go to ![Opens a pdf that] Review of Business Central & Dataverse integration<https://learn.microsoft.com/dynamics365/business-central/dev-itpro/developer/media/business-central-and-dataverse-integration.pdf>.\n## Prerequisites and step-by-step guidelines\nTo preview the new feature of business events on Business Central, do the following tasks:\n1. Create or upgrade a Business Central environment with Business Central 2023 release wave 1, version 22.x.\n  On version 22.0 or 22.1, you have to build an extension that implements the Dynamics 365 Business Central catalog of sample business events. Go to step 2.\n  On v22.2 or later, the Dynamics 365 Business Central catalog of sample business events is built in. Go to step 3.\n1. On v22.0 or 22.1, get the source files published in preview section of the microsoft/bc365bcdv GitHub repo<https://github.com/microsoft/d365bcdv/tree/main/samples/Business%20Events/Preview>, and then build and install an extension that implements our sample business events.\n Follow the instructions in https://github.com/microsoft/d365bcdv/tree/main/samples/Business%20Events/Preview#build-and-install-an-extension-for-sample-business-events of the README.md\n> TIP\n> This repo is being prepared as a one-stop-shop for Business Central and Dataverse integration.\n1. In Business Central, use the Dataverse Connection Setup assisted setup guide to connect your Business Central environment to the Dataverse environment on which you want to submit subscriptions and receive notifications of business events.\n This assisted setup guides you to install the Business Central Virtual Table app from Marketplace that enables business event subscriptions/notifications on your Dataverse environment.\n> IMPORTANT\n> Make sure that you install the latest version that supports business events (1.023093.3 or higher).\nSee #connect-business-central-to-dataverse in this article.\n1. In Business Central, assign the Ext. Events - Subscr permission set to users who want to subscribe to specific companies for their business events.\n For more information about assigning permission sets, go to Assign Permissions to Users and Groups</ui-define-granular-permissions> in the business functionality help for Business Central.\n1. In Power Apps, find and edit the Business Central Virtual Data Source Configuration table to refresh Business Central catalog with sample business events on your Dataverse environment.\n See #refresh-business-central-catalog-of-business-events in this article.\n1. In Power Apps, create Power Automate flows with the When an action is performed trigger that query Business Central catalog, submit subscriptions, and receive notifications of business events on your Dataverse environment.\n See #query-business-central-catalog-of-business-events-in-dataverse in this article.\n1. (Optional) Follow our code to build and install your own AL extension that adds custom business events to Business Central catalog.\n See #build-and-install-an-extension-for-custom-business-events in this article.\n Use the same Business Central Virtual Data Source Configuration table to refresh Business Central catalog with custom business events on your Dataverse environment. This step should also be done if you make changes to your custom business events.\n1. (Optional) Query Business Central catalog, submit subscriptions, and receive notifications of business events on your non-Dataverse environment.\n See #query-business-central-catalog-of-business-events-in-non-dataverse-systems in this article.\n1. (Optional) Fill out our survey<https://forms.office.com/r/GkvB6pritG> to let us know what you think. You're asked for information like:\n  Which business events you plan to try or build in preview\n  Other business events we should add for general availability and in which scenarios do you expect to use these business events\n  Your email contact for us to follow up.\n## Business Central catalog of business events\nThe following table describes the business events in Business Central catalog. These business events are readily available in version 22.2 and later but must be implemented in an extension in version 22.0 and 22.1\nCategory|Name|Description\nAccounts Payable|Purchase credit memo posted|Triggered when a purchase credit memo is posted.\nAccounts Payable|Purchase invoice posted|Triggered when a vendor invoice is posted as part of the Procure-to-Pay process.\nAccounts Payable|Purchase payment posted|Triggered when a vendor payment is posted as part of the Procure-to-Pay process.\nAccounts Payable|Purchase receipt posted|Triggered when goods from a purchase order are received by the internal warehouse/external logistics company. This event can trigger Finance Department to post a purchase invoice.\nAccounts Receivable|Customer blocked|Triggered when a customer is blocked for shipping/invoicing.\nAccounts Receivable|Customer unblocked|Triggered when a customer is unblocked for shipping/invoicing.\nAccounts Receivable|Sales credit limit exceeded|Triggered when the credit limit for a customer is exceeded due to a posted sales invoice/changed credit limit for that customer.\nAccounts Receivable|Sales credit memo posted|Triggered when a sales credit memo is posted.\nAccounts Receivable|Sales invoice posted|Triggered when a sales invoice is posted as part of the Quote-to-Cash process.\nAccounts Receivable|Sales payment posted|Triggered when a customer payment is posted as part of the Quote-to-Cash process.\nAccounts Receivable|Sales shipment posted|Triggered when goods from a sales order are shipped by the internal warehouse/external logistics company. This event can trigger Finance Department to post a sales invoice.\nOpportunities|Opportunity activated|Triggered when an opportunity is activated as part of the Quote-to-Cash process.\nOpportunities|Quote created for opportunity|Triggered when a quote is created for an opportunity as part of the Quote-to-Cash process.\nOpportunities|Winning quote converted into sales order|Triggered when a winning quote for an opportunity is converted into a sales order as part of the Quote-to-Cash process.\nOpportunities|Opportunity closed as lost|Triggered when a lost opportunity is closed as part of the Quote-to-Cash process.\nPurchasing|Purchase order released|Triggered when a purchase order is released to the internal warehouse/external logistics company, so they're ready to receive goods coming their way. This trigger occurs when the Release button is clicked on Purchase Order page in Business Central.\nSales|Sales order released|Triggered when a sales order is released to the internal warehouse/external logistics company, so they're ready to pick and ship goods. This trigger occurs when the Release button is clicked on Sales Order page in Business Central.\n## Connect Business Central to Dataverse\nTo connect your Business Central environment to a Dataverse environment on which you want to submit subscriptions and receive notifications of business events, follow these steps:\n1. In Business Central, in the upper-right corner, select the Settings icon > Assisted setup > Set up a connection to Dataverse to open the Dataverse Connection Setup assisted setup guide.\n1. Turn on the Enable virtual tables and events switch, and then select Next.\n ![Shows the Dataverse connection setup page in Business Central]\n1. Review the relevant terms and conditions. If you agree to the terms, turn on the I accept switch and then select Next.\n1. Specify your Dataverse environment URL, sign in as an administrator user, and select Next.\n1. Install the Business Central Virtual Table app from Marketplace<https://appsource.microsoft.com/product/dynamics-365/microsoftdynsmb.businesscentral_virtualentity>.\n This app enables business event subscriptions and notifications on your Dataverse environment. Make sure that you install the latest version that supports business events (1.023093.3 or later).\n ![Show the Business Central virtual tables app installation page]<https://learn.microsoft.com/dynamics365/business-central/dev-itpro/developer/media/virtual-table-plugin.png#lightbox>\n1. Finally, in the Dataverse Connection Setup guide, select Finish when done.\nTo learn more about connecting Business Central to Dataverse, go to Connect to Microsoft Dataverse</admin-how-to-set-up-a-dynamics-crm-connection> in the business functionality help for Business Central.\n## Refresh Business Central catalog of business events\nTo refresh the business event catalog after installing your extension, follow these steps:\n1. Sign in to Power Apps<https://make.powerapps.com>.\n1. Select Tables, search for Business Central Virtual Data Source Configuration under the All tab, and then select it.\n1. Select the Edit, select the Business Central row, and then select Edit row using form to open a form.\n1. Select Refresh Business Event Catalog on the form.\n ![Shows a screen clip of the refreshing the Business Central virtual app]<https://learn.microsoft.com/dynamics365/business-central/dev-itpro/developer/media/refresh-business-event-catalog.png#lightbox>\n## Query Business Central catalog of business events in Dataverse\nTo query Business Central catalog, submit subscriptions, and receive notifications of business events in your Dataverse environment, follow these steps:\n1. In Power Apps, select the Flows, and create Power Automate flows with the Dataverse When an action is performed trigger.\n1. Select the Dynamics 365 Business Central catalog, then do the following:\n 1. Select one of the categories, such as Accounts Receivable\n 1. Select (none) as table name.\n 1. Select one of the business events to subscribe in that category, such as Customer blocked, as action name.\n1. Select the + New step button to continue your flows to process the received notifications.\n ![Shows the \"when an action is performed\" step in a Power Automate flow]<https://learn.microsoft.com/dynamics365/business-central/dev-itpro/developer/media/power-automate-flow3.png#lightbox>\n## Build and install an extension for custom business events\nTo build and install an extension that implements custom business events, see our code in the published source files and follow these steps:\n1. Identify or create relevant AL files to code your custom business events.\n1. Identify existing categories for your custom business events or create new ones using the extensible enum.\n1. Create a procedure with an empty body for each custom business event.\n1. Add the ExternalBusinessEvent attribute to define the business event name, display name, description, and category.\n1. Add the optional RequiredPermissions attribute to enforce more permissions for users to subscribe.\n1. Add the required parameters to define the business event payload.\n1. Identify a specific AL event to subscribe and invoke the custom business event procedure with appropriate parameters when it occurs.\n1. Build an extension by adding those files to your AL project in Visual Studio Code.\n See Developing in AL<devenv-dev-overview>.\n1. Install the extension on your Business Central environment.\n See Installing Extensions in Business Central</ui-extensions-install-uninstall>.\n1. Use the Business Central Virtual Data Source Configuration table to refresh the Business Central catalog with custom business events on your Dataverse environment (see previous section<#refresh-business-central-catalog-of-business-events>).\n```al\nnamespace MyCompany.SalesExtension;\n\nusing System.Integration;\nusing Microsoft.Sales.Document;\n\nenumextension 50101 MyEnumExtension extends EventCategory\n{\n   value(0; \"Sales\")\n   {\n   }\n}\n\ncodeunit 50102 MyCodeunit\n{\n   trigger OnRun()\n   begin\n   end;\n\n   [ExternalBusinessEvent('salesorderposted', 'Sales order posted', 'Triggered when sales order has been posted', EventCategory::\"Sales\")]\n   [RequiredPermissions(PermissionObjectType::TableData, Database::\"Sales Header\", 'R')] // optional\n   procedure SalesOrderPosted(salesOrderId: Guid; customerName: Text; orderNumber: Text)\n   begin\n   end;\n\n   [EventSubscriber(ObjectType::Page, Page::\"Sales Order\", 'OnPostDocumentBeforeNavigateAfterPosting', '', true, true)]\n   local procedure OnPostDocument(var SalesHeader: Record \"Sales Header\"; var PostingCodeunitID: Integer; var Navigate: Enum \"Navigate After Posting\"; DocumentIsPosted: Boolean; var IsHandled: Boolean)\n   begin\n      SalesOrderPosted(SalesHeader.SystemId, SalesHeader.\"Sell-to Customer Name\", SalesHeader.\"No.\");\n   end;\n}\n```\n## Query Business Central catalog of business events in non-Dataverse systems\nBusiness Central exposes specific APIs for business events that can be used to:\n Query Business Central catalog for business event definitions\n Submit business event subscriptions w/ your own notification URL\nThe Business Central Virtual Table app uses the same APIs to query Business Central catalog and submit subscriptions of business events for Power Automate flows.\n### Query Business Central catalog of business events\nTo query Business Central catalog for business event definitions, you can send a request to the externalbusinessdefinitions endpoint:\n```json\nRequest: GET api/microsoft/runtime/v1.0/externalbusinesseventdefinitions\n\nResponse: \"value\": [{\n   \"category\": \"Sales\",\n   \"name\": \"salesorderposted\",\n   \"displayName\": \"Sales order posted\",\n   \"description\": \"Triggered when sales order has been posted\",\n   \"payload\": \"[{\\\"Index\\\":0,\\\"Name\\\":\\\"salesOrderId\\\",\\\"Type\\\":\\\"Guid\\\"},{\\\"Index\\\":1,\\\"Name\\\":\\\"customerName\\\",\\\"Type\\\":\\\"Text\\\"},{\\\"Index\\\":2,\\\"Name\\\":\\\"orderNumber\\\",\\\"Type\\\":\\\"Text\\\"}]\",\n   \"appId\": \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\",\n   \"appName\": \"MyBCExtension\",\n   \"appVersion\": \"1.0.0.0\",\n   \"appPublisher\": \"Default publisher\"\n}]\n```\nFor each business event, the response to your request contains the following data:\n category: The enum value of category for this business event\n name: The name of this business event\n displayName: The display name of this business event\n description: The description of this business event\n payload: The serialized text in JSON format that defines the payload parameters for this business event. Each payload parameter is defined by an array of objects in JSON format, for example:"}