# Has the event ON\_CAMPAIGN\_TRIGGER\_ACTION been deprecated along with CampaignExecutionEvent?

**URL:** <https://forum.mautic.org/t/has-the-event-on-campaign-trigger-action-been-deprecated-along-with-campaignexecutionevent/19773>\
**Category:** Development\
**Tags:** discussion, development, mautic-3\
**Created:** [June 8, 2021, 7:52am UTC](https://forum.mautic.org/t/has-the-event-on-campaign-trigger-action-been-deprecated-along-with-campaignexecutionevent/19773 "2021-06-08T07:52:17Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![asemk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/asemk/32/691_2.png) [@asemk](https://forum.mautic.org/u/asemk)\
**Post date:** [June 8, 2021, 7:52am UTC](https://forum.mautic.org/t/has-the-event-on-campaign-trigger-action-been-deprecated-along-with-campaignexecutionevent/19773/1 "2021-06-08T07:52:18Z")

</div>

Hey guys,

I want to consume PendingEvent instead of CampaignExecutionEvent in a plugin which I’m developing now ( when triggering a campaign via the command `mautic campaigns:trigger`.

When I looked into `PendingEvent` I noticed it’s used with the event `ON_CAMPAIGN_BATCH_ACTION` and not the one traditionally used with CampaignExecutionEvent which is`ON_CAMPAIGN_TRIGGER_ACTION`.

So if CampaignExecutionEvent has been deprecated, then what event should we use now to trigger PendingEvent ? is it `ON_CAMPAIGN_BATCH_ACTION` or can we still use `ON_CAMPAIGN_TRIGGER_ACTION` with PendingEvent ?

How come Mautic core plugins still work even though they still use CampaignExecutionEvent ? is it really deprecated ?!

**Extra quick Question** 😊 : According to the solution [here.](https://forum.mautic.org/t/which-event-to-use-instead-of-campaignexecutionevent-in-mautic-3-plugins/18614), however PendingEvent does not have the same methods, “getLead” “setFailed” and “setResult” as CampaignExecutionEvent has, Do you have any suggestions how can I do it ?

I’m using Mautic 3.3.1

Thanks for any help.

---

<div class="post-metadata">

**Author:** ![asemk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/asemk/32/691_2.png) [@asemk](https://forum.mautic.org/u/asemk)\
**Post date:** [June 8, 2021, 11:12am UTC](https://forum.mautic.org/t/has-the-event-on-campaign-trigger-action-been-deprecated-along-with-campaignexecutionevent/19773/2 "2021-06-08T11:12:58Z")

</div>

So I can confirm that this event has been deprecated, mentioned in here `Mautic\EmailBundle\EmailEvents`

But still How come Mautic core plugins still work even though they still use CampaignExecutionEvent ? is it really deprecated ?!

Also, what Mautic console command is the responsible for triggering `ON_CAMPAIGN_BATCH_ACTION` ?

Best
