diff --git a/api/v3/WebhookQueueRunner/Run.php b/api/v3/PaymentWebhookRunner/Run.php similarity index 88% rename from api/v3/WebhookQueueRunner/Run.php rename to api/v3/PaymentWebhookRunner/Run.php index 37cd199..7ca5a45 100644 --- a/api/v3/WebhookQueueRunner/Run.php +++ b/api/v3/PaymentWebhookRunner/Run.php @@ -3,7 +3,7 @@ use Civi\Paymentprocessingcore\Service\WebhookQueueRunnerService; /** - * WebhookQueueRunner.Run API. + * PaymentWebhookRunner.Run API. * * Process queued webhook events from payment processors. * @@ -29,7 +29,7 @@ * * @throws \CRM_Core_Exception */ -function civicrm_api3_webhook_queue_runner_Run(array $params): array { +function civicrm_api3_payment_webhook_runner_Run(array $params): array { $processorType = $params['processor_type'] ?? 'all'; $batchSize = (int) ($params['batch_size'] ?? WebhookQueueRunnerService::DEFAULT_BATCH_SIZE); @@ -44,16 +44,16 @@ function civicrm_api3_webhook_queue_runner_Run(array $params): array { $result = [$processorType => $runnerService->runQueue($processorType, $batchSize)]; } - return civicrm_api3_create_success($result, $params, 'WebhookQueueRunner', 'Run'); + return civicrm_api3_create_success($result, $params, 'PaymentWebhookRunner', 'Run'); } /** - * WebhookQueueRunner.Run API specification. + * PaymentWebhookRunner.Run API specification. * * @param array $spec * API specification array. */ -function _civicrm_api3_webhook_queue_runner_Run_spec(array &$spec): void { +function _civicrm_api3_payment_webhook_runner_Run_spec(array &$spec): void { $spec['processor_type'] = [ 'title' => 'Processor Type', 'description' => 'Payment processor type. Use "all" (default) to process webhooks from all registered processors, or specify one: stripe, gocardless, deluxe, etc.', diff --git a/managed/Job_WebhookQueueRunner.mgd.php b/managed/Job_PaymentWebhookRunner.mgd.php similarity index 88% rename from managed/Job_WebhookQueueRunner.mgd.php rename to managed/Job_PaymentWebhookRunner.mgd.php index f3e483c..209aaa9 100644 --- a/managed/Job_WebhookQueueRunner.mgd.php +++ b/managed/Job_PaymentWebhookRunner.mgd.php @@ -10,18 +10,18 @@ * handlers via the WebhookHandlerRegistry, it automatically appears in the * processing queue without any configuration changes. * - * @see api/v3/WebhookQueueRunner/Run.php + * @see api/v3/PaymentWebhookRunner/Run.php */ return [ [ - 'name' => 'Job:WebhookQueueRunner', + 'name' => 'Job:PaymentWebhookRunner', 'entity' => 'Job', 'params' => [ 'version' => 3, 'name' => 'Process Payment Webhooks', 'description' => 'Process queued webhook events from all registered payment processors (Stripe, GoCardless, Deluxe, etc.). Automatically processes webhooks from all enabled processors with retry logic and exponential backoff.', 'run_frequency' => 'Always', - 'api_entity' => 'WebhookQueueRunner', + 'api_entity' => 'PaymentWebhookRunner', 'api_action' => 'Run', 'parameters' => 'processor_type=all&batch_size=250', 'is_active' => 1,