@spritz-finance/api-client 0.4.8 → 0.4.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1023,3 +1023,14 @@ const signature = createHmac("sha256", <YOUR_WEBHOOK_SECRET>)
1023
1023
  ```
1024
1024
 
1025
1025
  Ensure that the computed signature matches the Signature header received in the webhook request before processing the payload.
1026
+
1027
+ ### Setting webhook secret
1028
+
1029
+ To add or update a webhook secret for signing webhook requests:
1030
+
1031
+ ```typescript
1032
+ const result = await client.webhook.updateWebhookSecret('your-webhook-secret-here')
1033
+ // Returns: { success: true }
1034
+ ```
1035
+
1036
+ This secret will be used to sign all subsequent webhook requests sent to your endpoint. Always store your webhook secret securely and never expose it in client-side code.