Update
This commit is contained in:
32
app/Helpers/FirstParty/Stripe/StripeHelper.php
Normal file
32
app/Helpers/FirstParty/Stripe/StripeHelper.php
Normal file
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
namespace App\Helpers\FirstParty\Stripe;
|
||||
|
||||
use Laravel\Cashier\Events\WebhookReceived;
|
||||
|
||||
class StripeHelper
|
||||
{
|
||||
public static function handleSubscriptionWebhookEvents(WebhookReceived $event)
|
||||
{
|
||||
switch ($event->payload['type']) {
|
||||
case 'customer.subscription.created':
|
||||
case 'customer.subscription.updated':
|
||||
self::handleSubscriptionUpsert($event);
|
||||
break;
|
||||
|
||||
case 'customer.subscription.deleted':
|
||||
self::handleSubscriptionDelete($event);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private static function handleSubscriptionUpsert(WebhookReceived $event)
|
||||
{
|
||||
///
|
||||
}
|
||||
|
||||
private static function handleSubscriptionDelete(WebhookReceived $event)
|
||||
{
|
||||
///
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user