{"title":"AppSourceCop Warning AS0134","url":"https://jonas-paprotka.de/docs/dev-itpro/developer/analyzers/appsourcecop-as0134/","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/analyzers/appsourcecop-as0134, 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/analyzers/appsourcecop-as0134","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":"The version attribute parameter of an external business event cannot be changed because it might break external subscribers.","date":"2026-10-01","meta":{"topic":"reference"},"outline":[{"level":1,"title":"AppSourceCop Warning AS0134","slug":"appsourcecop-warning-as0134","at":0,"chars":3068},{"level":2,"title":"Description","slug":"description","at":91,"chars":288},{"level":2,"title":"How to fix this diagnostic?","slug":"how-to-fix-this-diagnostic","at":379,"chars":122},{"level":2,"title":"Examples triggering this rule","slug":"examples-triggering-this-rule","at":501,"chars":1591},{"level":3,"title":"Example 1 - Adding the version parameter to an existing external business event","slug":"example-1---adding-the-version-parameter-to-an-existing-external-business-event","at":534,"chars":521},{"level":3,"title":"Example 2 - Removing the version parameter from an external business event","slug":"example-2---removing-the-version-parameter-from-an-external-business-event","at":1055,"chars":516},{"level":3,"title":"Example 2 - Changing the version parameter of an external business event","slug":"example-2---changing-the-version-parameter-of-an-external-business-event","at":1571,"chars":521},{"level":2,"title":"Examples not triggering this rule","slug":"examples-not-triggering-this-rule","at":2092,"chars":825},{"level":3,"title":"Example 1 - Adding a new event with a different version and deprecating the existing event","slug":"example-1---adding-a-new-event-with-a-different-version-and-deprecating-the-existing-event","at":2129,"chars":788},{"level":2,"title":"Related information","slug":"related-information","at":2917,"chars":151}],"text":"# AppSourceCop Warning AS0134\nThe version of an external business event cannot be changed.\n## Description\nThe version attribute parameter of an external business event cannot be changed because it might break external subscribers. To update the version, introduce a new event with the increased version and follow the standard deprecation process to obsolete the existing event.\n## How to fix this diagnostic?\nRevert the changes done to the version attribute parameter of the external business event.\n## Examples triggering this rule\n### Example 1 - Adding the version parameter to an existing external business event\nVersion 1 of the extension\n```al\ncodeunit 10 MyCodeunit\n{\n    [ExternalBusinessEvent('MyEvent', 'MyEventDisplayName', 'Description', EventCategory::MyValue)]\n    procedure MyCodeunitEvent()\n    begin\n    end;\n}\n```\nVersion 2 of the extension\n```al\ncodeunit 10 MyCodeunit\n{\n    [ExternalBusinessEvent('MyEvent', 'MyEventDisplayName', 'Description', EventCategory::MyValue, '1.0')]\n    procedure MyCodeunitEvent()\n    begin\n    end;\n}\n```\n### Example 2 - Removing the version parameter from an external business event\nVersion 1 of the extension\n```al\ncodeunit 10 MyCodeunit\n{\n    [ExternalBusinessEvent('MyEvent', 'MyEventDisplayName', 'Description', EventCategory::MyValue, '1.0')]\n    procedure MyCodeunitEvent()\n    begin\n    end;\n}\n```\nVersion 2 of the extension\n```al\ncodeunit 10 MyCodeunit\n{\n    [ExternalBusinessEvent('MyEvent', 'MyEventDisplayName', 'Description', EventCategory::MyValue)]\n    procedure MyCodeunitEvent()\n    begin\n    end;\n}\n```\n### Example 2 - Changing the version parameter of an external business event\nVersion 1 of the extension\n```al\ncodeunit 10 MyCodeunit\n{\n    [ExternalBusinessEvent('MyEvent', 'MyEventDisplayName', 'Description', EventCategory::MyValue, '1.0')]\n    procedure MyCodeunitEvent()\n    begin\n    end;\n}\n```\nVersion 2 of the extension\n```al\ncodeunit 10 MyCodeunit\n{\n    [ExternalBusinessEvent('MyEvent', 'MyEventDisplayName', 'Description', EventCategory::MyValue, '2.0')]\n    procedure MyCodeunitEvent()\n    begin\n    end;\n}\n```\n## Examples not triggering this rule\n### Example 1 - Adding a new event with a different version and deprecating the existing event\nVersion 1 of the extension\n```al\ncodeunit 10 MyCodeunit\n{\n    [ExternalBusinessEvent('MyEvent', 'MyEventDisplayName', 'Description', EventCategory::MyValue, '1.0')]\n    procedure MyCodeunitEvent()\n    begin\n    end;\n}\n```\nVersion 2 of the extension\n```al\ncodeunit 10 MyCodeunit\n{\n    [ExternalBusinessEvent('MyEvent', '[OBSOLETE]MyEventDisplayName', 'Description', EventCategory::MyValue, '1.0')]\n    [Obsolete('The event will be replaced by version 2.0 of MyEvent', '27.0')]\n    procedure MyCodeunitEvent()\n    begin\n    end;\n\n    [ExternalBusinessEvent('MyEvent', 'MyEventDisplayName', 'Description', EventCategory::MyValue, '2.0')]\n    procedure MyCodeunitEvent2()\n    begin\n    end;\n}\n```\n## Related information\nAppSourceCop analyzer<appsourcecop>\nGetting started with AL<../devenv-get-started>\nDeveloping extensions<../devenv-dev-overview>"}