GET /api/v1/webhooks
Returns all registered webhook endpoints on your account.Response fields
Total number of registered endpoints.
POST /api/v1/webhooks
Registers a new webhook endpoint. The response includes asecret that you use to verify incoming payloads — save it immediately, as it is never shown again.
Request body
The HTTPS (or HTTP) URL NearIQ should POST events to. Must be a valid URL.
One or more event types to subscribe to. See supported events below.
Supported events
| Event | Triggered when |
|---|---|
competitor.rating_change | A tracked competitor’s Google rating changes |
competitor.review_surge | A tracked competitor receives an unusual spike in reviews |
competitor.hours_change | A tracked competitor updates their opening hours |
competitor.website_change | A tracked competitor changes their website URL |
competitor.new_competitor | A new competitor is detected in your area |
business.rating_change | Your own Google rating changes |
business.review_surge | Your own listing receives a review spike |
alert.created | Any new alert is created for your account |
Response fields
Unique ID for the new endpoint.
The registered URL.
The subscribed event types.
Always
true for a newly created endpoint.Signing secret prefixed with
whsec_. Used to verify the X-NearIQ-Signature header on incoming deliveries. This field is only returned once.ISO 8601 creation timestamp.
A reminder that the secret will not be shown again.
PATCH /api/v1/webhooks/:id
Updates a webhook endpoint. You can change the URL, update the subscribed events, or toggle the endpoint on and off. Only include the fields you want to change.Path parameters
The webhook endpoint ID to update.
Request body
New delivery URL. Must be a valid HTTP or HTTPS URL.
Replacement list of subscribed events. Must be a non-empty array of valid event types.
Set to
false to pause deliveries without deleting the endpoint.Response
Returns the updatedWebhookEndpoint object (same shape as the GET /webhooks list items).
DELETE /api/v1/webhooks/:id
Permanently deletes a webhook endpoint. In-flight deliveries may still be attempted. Returns204 No Content on success.
Path parameters
The webhook endpoint ID to delete.
Verifying webhook payloads
Every delivery includes anX-NearIQ-Signature header with a sha256=<hmac> value. You should always verify this signature before processing the payload.
NearIQ computes the HMAC-SHA256 of the raw request body using your endpoint’s whsec_... secret as the key.
X-NearIQ-Event header containing the event type (e.g., competitor.rating_change), which you can use to route events without parsing the body first.