New event processing API