Create a Webhook Endpoint
Register an HTTPS URL that receives signed event deliveries such as profile.updated.
POST
/
v3
/
webhooks
Create a Webhook Endpoint
curl --request POST \
--url https://api.orbitsearch.com/v3/webhooks \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"url": "https://example.com/orbit/webhooks",
"event_types": [
"profile.updated"
]
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({url: 'https://example.com/orbit/webhooks', event_types: ['profile.updated']})
};
fetch('https://api.orbitsearch.com/v3/webhooks', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.orbitsearch.com/v3/webhooks"
payload = {
"url": "https://example.com/orbit/webhooks",
"event_types": ["profile.updated"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"url": "<string>",
"event_types": [
"profile.updated"
],
"enabled": true,
"created_at": "2023-11-07T05:31:56Z",
"secret": "<string>",
"supported_event_types": [
"profile.updated"
],
"description": "<string>",
"secret_prefix": "<string>",
"secret_suffix": "<string>",
"last_delivery_at": "2023-11-07T05:31:56Z"
}{
"status": "failed",
"error": {
"code": "<string>",
"message": "<string>",
"requiredCredits": 1,
"remainingCredits": 1
}
}{
"status": "failed",
"error": {
"code": "<string>",
"message": "<string>",
"requiredCredits": 1,
"remainingCredits": 1
}
}{
"status": "failed",
"error": {
"code": "<string>",
"message": "<string>",
"requiredCredits": 1,
"remainingCredits": 1
}
}{
"status": "failed",
"error": {
"code": "<string>",
"message": "<string>",
"requiredCredits": 1,
"remainingCredits": 1
}
}The response includes the signing
secret (a whsec_... value) once. Store it right away; later reads show a masked version. If you lose it, delete the endpoint and create a new one.
Deliveries are signed with HMAC-SHA256 — see Events & signatures for the payload and how to verify them.Body
application/json
Events to deliver. Omitting it subscribes the endpoint to profile.updated only, so name every event type you want, including search.profile.updated and search.completed.
Available options:
profile.updated, company.thesis.changed, company.alert, portfolio.changed, search.profile.updated, search.completed Response
The endpoint, with its signing secret.
⌘I
Create a Webhook Endpoint
curl --request POST \
--url https://api.orbitsearch.com/v3/webhooks \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"url": "https://example.com/orbit/webhooks",
"event_types": [
"profile.updated"
]
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({url: 'https://example.com/orbit/webhooks', event_types: ['profile.updated']})
};
fetch('https://api.orbitsearch.com/v3/webhooks', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.orbitsearch.com/v3/webhooks"
payload = {
"url": "https://example.com/orbit/webhooks",
"event_types": ["profile.updated"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"url": "<string>",
"event_types": [
"profile.updated"
],
"enabled": true,
"created_at": "2023-11-07T05:31:56Z",
"secret": "<string>",
"supported_event_types": [
"profile.updated"
],
"description": "<string>",
"secret_prefix": "<string>",
"secret_suffix": "<string>",
"last_delivery_at": "2023-11-07T05:31:56Z"
}{
"status": "failed",
"error": {
"code": "<string>",
"message": "<string>",
"requiredCredits": 1,
"remainingCredits": 1
}
}{
"status": "failed",
"error": {
"code": "<string>",
"message": "<string>",
"requiredCredits": 1,
"remainingCredits": 1
}
}{
"status": "failed",
"error": {
"code": "<string>",
"message": "<string>",
"requiredCredits": 1,
"remainingCredits": 1
}
}{
"status": "failed",
"error": {
"code": "<string>",
"message": "<string>",
"requiredCredits": 1,
"remainingCredits": 1
}
}