Create New Webhook
Create a new webhook that listens for events from a saved search and sends real-time HTTP POST notifications to your specified URL. Configure event types, filters, and delivery settings for automated data pipelines.
Authorization
Bearer In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
- active_event_typesarray<WebhookEventType>nullable
Event types this webhook subscribes to. If None, defaults to the search type's primary event (job_new for jobs, company_new for companies).
- job_new
- company_new
- job_closed
- descriptionstringnullable
Description of the webhook
- listening_start_timestringnullabledate-time
Date when the webhook started listening for events. If listening_start_time is None, the webhook will listen to all events matching the search query regardless of when they occurred.
- max_events_per_dayintegernullable0 <= value
Maximum number of events this webhook may send per day (UTC). The cap is applied when events are created, so events above it are never sent and never charged. Matches above the cap are dropped, not queued: the next day delivers that day's records only, never a backlog. Null means no daily cap.
- search_idintegerrequired
ID of the search that the webhook is listening to.
- secretstringnullablelength: 16 <= length
Secret used to sign webhook payloads with HMAC-SHA256. If set, deliveries include an X-TheirStack-Signature-256 header.
- trigger_once_per_companybooleandefault: false
Only for webhook type ='job.new'. If true, Company A with 5 jobs → 1 event triggered. If false, Company A with 5 jobs → 5 events triggered
- urlstringlength: 1 <= length <= 2083urirequired
URL of the webhook
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://api.theirstack.com/v0/webhooks" \ -H "Content-Type: application/json" \ -d '{ "search_id": 123, "url": "https://example.com/webhook" }'{
"active_event_types": [
"job_new"
],
"created_at": "2019-08-24T14:15:22Z",
"description": "Webhook for new jobs",
"event_type": "job_new",
"has_secret": true,
"id": 0,
"is_active": true,
"is_archived": true,
"listening_start_time": "2024-01-01T00:00:00Z",
"max_events_per_day": 500,
"scanning_frequency": "10m",
"search_id": 123,
"search_name": "string",
"team_id": 0,
"trigger_once_per_company": true,
"updated_at": "2019-08-24T14:15:22Z",
"url": "https://example.com/webhook",
"user_id": 0,
"webhook_type": "jobs"
}{
"error": {
"code": "E-001",
"description": "string",
"title": "Not allowed exception"
},
"request_id": null
}{
"error": {
"code": "E-001",
"description": "string",
"title": "Not allowed exception"
},
"request_id": null
}{
"error": {
"code": "E-001",
"description": "string",
"title": "Not allowed exception"
},
"request_id": null
}{
"error": {
"code": "E-001",
"description": "string",
"title": "Not allowed exception"
},
"request_id": null
}How is this guide?
Last updated on
