cURL
curl --request PATCH \ --url https://api.planetscale.com/v1/organizations/{organization}/databases/{database}/webhooks/{id} \ --header 'Authorization: <api-key>' \ --header 'Content-Type: application/json' \ --data '{ "url": "<string>", "enabled": true, "events": [ "<string>" ] }'
{ "id": "<string>", "url": "<string>", "secret": "<string>", "enabled": true, "last_sent_result": "<string>", "last_sent_success": true, "last_sent_at": "<string>", "created_at": "<string>", "updated_at": "<string>", "events": [ "branch.ready" ] }
A service token or OAuth token must have at least one of the following access or scopes in order to use this API endpoint:
Service Token Accesses write_database
write_database
OAuth Scopes
write_databases
Show child attributes