A client migrating from another ERP to M3 CE is looking to generate X12 files for common EDI documents such as 810 (invoice), 850 (PO), etc. I have a custom MEC mapping that generates an XML document that mimics the structure of an X12 810. Its root element is named X12810, its children are the X12 810 segments such as ISA, GS, BIG, etc. The mapping is named Custom_X12810_Sync_Out, and when I publish it MEC automatically creates an agreement named M3_X12810_Sync_Out in the Custom (i.e. Extensibility 3) folder. When I activate that agreement I get the following INFO messages in the EC log:
Updating BOD type for agreement M3_X12810_Sync_Out
Which sounds like everything should be OK.
The agreement's detection is auto-configured with the usual defaults:

The SyncX12810 is the name of the BOD I use in the Event Analytics Rule that is supposed to trigger the agreement:


However, the agreement never gets triggered even though Event Hub shows the prerequisite events:
- MBMInitiator published by M3
- M3BEBOD published by Event Analytics and containing the correct data, including BOD verb and noun.
Why is the agreement not being triggered? Is it the fact that the name of the output document produced by the MEC mapping (X12810) is different from the BOD name (SyncX12810)?
I tried deleting BODVerb to see if the agreement will be triggered by the noun only, and it didn't work.
I also tried setting BODNoun to "810" and BODVerb to "X12" but that didn't work either.
I am reluctant to change the output document in the MEC mapping to SyncX12810 because I would have to remap many dozens of output elements.
My alternative workaround idea was to create an Extensibility 4 agreement (called Custom_X12810_Sync_Out) identical to the one MEC auto-generated, except on the Processes tab add a new Apply Envelope process towrap the original X12810 document produced by the MEC mapping in a custom XML envelope that mimics a Sync BOD.
However, that doesn't seem to work either because when I activate the new Ext 4 agreement I get the following in the EC log:
Updating BOD type for agreement Custom_X12810_Sync_Out
Invalid BOD agreement name: Custom_X12810_Sync_Out
What does the "Invalid BOD agreement name" error mean?
I get the same error no matter what name I give the new Ext 4 agreement, so I suspect the error message is misleading and the problem really has nothing to do with the agreement name.
I am at my wits end and hoping someone has run into a similar problem before and can point me in the right direction. Thanks in advance to all who responds!