Webhooks

Create a webhook endpoint

Registers an HTTPS endpoint. The signing secret is returned once. Private, loopback, and otherwise unsafe destinations are rejected. Requires the webhooks:write scope when called with a scoped key.

POST/v1/webhooks

Registers an HTTPS endpoint. The signing secret is returned once. Private, loopback, and otherwise unsafe destinations are rejected. Requires the webhooks:write scope when called with a scoped key.

AuthorizationBearer <token>

Pass Authorization: Bearer mapleads_xxx.

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

url*string
Formaturi
Lengthlength <= 2048
eventTypes*array<>
Items1 <= items

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/webhooks" \  -H "Content-Type: application/json" \  -d '{    "url": "http://example.com",    "eventTypes": [      "search.completed"    ]  }'
{  "id": "string",  "url": "http://example.com",  "eventTypes": [    "string"  ],  "enabled": true,  "createdAt": "2019-08-24T14:15:22Z",  "secret": "string"}