give
/
src
/
PaymentGateways
/
PayPalCommerce
/
PayPalCheckoutSdk
/
Requests
/
VerifyWebhookSignature.php
CreateWebhook.php
2 years ago
DeleteWebhook.php
2 years ago
GenerateClientToken.php
2 years ago
GetAccessToken.php
2 years ago
UpdateWebhook.php
2 years ago
VerifyWebhookSignature.php
3 years ago
VerifyWebhookSignature.php
25 lines
| 1 | <?php |
| 2 | namespace Give\PaymentGateways\PayPalCommerce\PayPalCheckoutSdk\Requests; |
| 3 | |
| 4 | use PayPalHttp\HttpRequest; |
| 5 | |
| 6 | /** |
| 7 | * Class VerifyWebhookSignature |
| 8 | * |
| 9 | * @since 2.30.0 |
| 10 | */ |
| 11 | class VerifyWebhookSignature extends HttpRequest |
| 12 | { |
| 13 | /** |
| 14 | * @since 2.30.0 |
| 15 | * @param array $requestBody Request body. |
| 16 | */ |
| 17 | public function __construct(array $requestBody) |
| 18 | { |
| 19 | parent::__construct('/v1/notifications/verify-webhook-signature', 'POST'); |
| 20 | |
| 21 | $this->headers["Content-Type"] = "application/json"; |
| 22 | $this->body = wp_json_encode($requestBody); |
| 23 | } |
| 24 | } |
| 25 |