Best practice for webhook management #235
Unanswered
matthewhaworth
asked this question in
Q&A
Replies: 1 comment
-
class SyncWebhooksAction
{
public function execute(User $shop): void
{
$shopId = ShopId::fromNative($shop->id);
$webhooks = config('shopify-app.webhooks');
WebhookInstaller::dispatch($shopId, $webhooks);
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello! I'm new to this world so excuse my naivety.
I can see that by default you set your webhooks up with Shopify when a store installs your app; that is how this module works here. However, how might I handle adding webhooks to shops after they have installed the app later down the line? Say for example initially I only require a webhook when an order is created, and I release my app. Later down the line I add a feature that requires me to observe refunds also. What's the best practice approach to doing that?
Beta Was this translation helpful? Give feedback.
All reactions