You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -122,7 +122,7 @@ If the receiving app doesn't respond with a response code starting with `2`, the
122
122
123
123
### Send webhook synchronously
124
124
125
-
If you would like to call the webhook immediately (synchronously), you may use the dispatchSync method. When using this method, the webhook will not be queued and will be run immediately. This can be helpfull in situation where sending the webhook is part of a bigger job that already has been queued.
125
+
If you would like to call the webhook immediately (synchronously), you may use the dispatchSync method. When using this method, the webhook will not be queued and will be run immediately. This can be helpful in situations where sending the webhook is part of a bigger job that already has been queued.
126
126
127
127
```php
128
128
WebhookCall::create()
@@ -132,7 +132,7 @@ WebhookCall::create()
132
132
133
133
### Conditionally sending webhooks
134
134
135
-
If you would like to conditionally dispatch a webhook, you may use the `dispatchIf`, `dispatchUnless`, `dispatchSyncIf` and `dispatchSyncUnless` methods:
135
+
If you would like to conditionally dispatch a webhook, you may use the `dispatchIf`, `dispatchUnless`, `dispatchSyncIf`, and `dispatchSyncUnless` methods:
136
136
137
137
```php
138
138
WebhookCall::create()
@@ -152,11 +152,11 @@ WebhookCall::create()
152
152
->dispatchSyncUnless($condition);
153
153
```
154
154
155
-
### How signing requests works
155
+
### How signing requests work
156
156
157
157
When setting up, it's common to generate, store, and share a secret between your app and the app that wants to receive webhooks. Generating the secret could be done with `Illuminate\Support\Str::random()`, but it's entirely up to you. The package will use the secret to sign a webhook call.
158
158
159
-
By default, the package will add a header called `Signature` that will contain a signature the receiving app can use the payload hasn't been tampered with. This is how that signature is calculated:
159
+
By default, the package will add a header called `Signature` that will contain a signature the receiving app can use if the payload hasn't been tampered with. This is how that signature is calculated:
160
160
161
161
```php
162
162
// payload is the array passed to the `payload` method of the webhook
We don't recommend this, but if you don't want the web hook request to be signed call the `doNotSign` method.
172
+
We don't recommend this, but if you don't want the webhook request to be signed call the `doNotSign` method.
173
173
174
174
```php
175
175
WebhookCall::create()
@@ -231,7 +231,7 @@ WebhookCall::create()
231
231
->dispatch();
232
232
```
233
233
234
-
To not hammer the remote app we'll wait some time between each attempt. By default, we wait 10 seconds between the first and second attempt, 100 seconds between the third and the fourth, 1000 between the fourth and the fifth and so on. The maximum amount of seconds that we'll wait is 100 000, which is about 27 hours. This behavior is implemented in the default `ExponentialBackoffStrategy`.
234
+
To not hammer the remote app we'll wait some time between each attempt. By default, we wait 10 seconds between the first and second attempts, 100 seconds between the third and the fourth, 1000 between the fourth and the fifth, and so on. The maximum amount of seconds that we'll wait is 100 000, which is about 27 hours. This behavior is implemented in the default `ExponentialBackoffStrategy`.
235
235
236
236
You can define your own backoff strategy by creating a class that implements `Spatie\WebhookServer\BackoffStrategy\BackoffStrategy`. This is what that interface looks like:
237
237
@@ -315,7 +315,7 @@ The proxy specification follows the [guzzlehttp proxy format](https://docs.guzzl
315
315
316
316
### Verifying the SSL certificate of the receiving app
317
317
318
-
When using an URL that starts with `https://` the package will verify if the SSL certificate of the receiving party is valid. If it is not, we will consider the webhook call failed. We don't recommend this, but you can turn off this verification by setting the `verify_ssl` key in the `webhook-server` config file to `false`.
318
+
When using a URL that starts with `https://` the package will verify if the SSL certificate of the receiving party is valid. If it is not, we will consider the webhook call failed. We don't recommend this, but you can turn off this verification by setting the `verify_ssl` key in the `webhook-server` config file to `false`.
319
319
320
320
You can also disable the verification per webhook call with the `doNotVerifySsl` method.
321
321
@@ -371,7 +371,7 @@ or activate the `throw_exception_on_failure` global option of the `webhook-serve
371
371
372
372
By default, all webhooks will transform the payload into JSON. Instead of sending JSON, you can send any string by using the `sendRawBody(string $body)` option instead.
373
373
374
-
Due to type mismatch in the Signer API, it is currently not support to sign raw data requests.
374
+
Due to a type mismatch in the Signer API, it is currently not supported to sign raw data requests.
375
375
When using the _sendRawBody_ option, you will receive a _string_ payload in the WebhookEvents.
0 commit comments