public function listAction()
    {
        $subscriptionManager = $this->get('phlexible_message.subscription_manager');

        $subscriptions = [];

        foreach ($subscriptionManager->findAll() as $subscription) {
            $subscriptions[] = [
                'id' => $subscription->getId(),
                'filterId' => $subscription->getFilter()->getId(),
                'filter' => $subscription->getFilter()->getTitle(),
                'handler' => $subscription->getHandler(),
            ];
        }

        return new JsonResponse($subscriptions);
    }