Javascript
const url = 'https://api.gnosispay.com/api/v1/webhooks/subscribe/{partnerId}'; const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"message":"<string>","signature":"<string>"}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); }
{ "success": true, "subscriptionId": "<string>" }
Partner ID to subscribe to
SIWE message obtained from /api/v1/webhooks/message/{partnerId}
Signature of the message by the user's wallet
Successfully subscribed to partner webhooks
Whether the subscription was successful
Unique ID of the created subscription