API Reference
Update a webhook
PUT
/web_hooks/{id}Body Parameters
namestring(optional)The mode for the web hook. Possible values are: Test or Production
modestring(optional)The mode for the web hook. Possible values are: Test or Production
addressstring(optional)The URL for the web hook to target. This must start with http:// or https://
authentication_usernamestring(optional)· Defaults to OptionalThe username for HTTP Basic authentication
authentication_passwordstring(optional)· Defaults to OptionalThe password for HTTP Basic authentication (optional)
eventsstring(optional)A list of events for the web hook to target. This is a comma separated list of events, and it is possible to use wildcards (e.g. * for all events, or direct_entry:* for all direct entry hooks, or direct_entry:created,direct_entry:failed)
Query Parameters
idstringId of the webhook
Request
curl
curl -X PUT https://gateway.pmnts-sandbox.io/v1.0/web_hooks/071-WH-ABCD1234 -u TEST:TEST -d '
{
"name": "Test Hook Updated"
}'Response
200Result
json
{
"successful": true,
"response": {
"address": "https://www.your-server.com/payment/hook",
"events": "*",
"mode": "Test",
"authentication_username": null,
"authentication_password": "",
"is_active": null,
"name": "Test Hook Updated",
"id": "071-WH-ABCD1234"
},
"errors": [],
"test": true
}400Result
json
{}