If the application connects several webhook clients, it is now easy to find out which webhook it is. This allows errors to be dealt with individually.
In our specific example, the external webhook service cannot correctly calculate the signature with a UTF8 payload, so that we can call the GET API of the external service in the event of an error.
e.g.
public function handle(InvalidWebhookSignatureEvent $event): void
{
if ($event->config->processWebhookJobClass !== CustomWebhookJob::class) {
return;
}
// do something specific
}
If the application connects several webhook clients, it is now easy to find out which webhook it is. This allows errors to be dealt with individually.
In our specific example, the external webhook service cannot correctly calculate the signature with a UTF8 payload, so that we can call the GET API of the external service in the event of an error.
e.g.