Handle published events webhook
curl --request POST \
--url https://apps-studio.thena.ai/incoming-webhook/events \
--header 'Content-Type: application/json' \
--header 'x-bot-key: <x-bot-key>' \
--data '
{
"event_name": "linear.contact.synced",
"payload": {}
}
'import requests
url = "https://apps-studio.thena.ai/incoming-webhook/events"
payload = {
"event_name": "linear.contact.synced",
"payload": {}
}
headers = {
"x-bot-key": "<x-bot-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-bot-key': '<x-bot-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({event_name: 'linear.contact.synced', payload: {}})
};
fetch('https://apps-studio.thena.ai/incoming-webhook/events', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://apps-studio.thena.ai/incoming-webhook/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'event_name' => 'linear.contact.synced',
'payload' => [
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-bot-key: <x-bot-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://apps-studio.thena.ai/incoming-webhook/events"
payload := strings.NewReader("{\n \"event_name\": \"linear.contact.synced\",\n \"payload\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-bot-key", "<x-bot-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://apps-studio.thena.ai/incoming-webhook/events")
.header("x-bot-key", "<x-bot-key>")
.header("Content-Type", "application/json")
.body("{\n \"event_name\": \"linear.contact.synced\",\n \"payload\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://apps-studio.thena.ai/incoming-webhook/events")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-bot-key"] = '<x-bot-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"event_name\": \"linear.contact.synced\",\n \"payload\": {}\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"messageId": "12345678-1234-1234-1234-123456789012",
"timestamp": "2024-02-20T12:00:00Z"
}Incoming webhook
Handle published events webhook
Handles the published events webhook
POST
/
incoming-webhook
/
events
Handle published events webhook
curl --request POST \
--url https://apps-studio.thena.ai/incoming-webhook/events \
--header 'Content-Type: application/json' \
--header 'x-bot-key: <x-bot-key>' \
--data '
{
"event_name": "linear.contact.synced",
"payload": {}
}
'import requests
url = "https://apps-studio.thena.ai/incoming-webhook/events"
payload = {
"event_name": "linear.contact.synced",
"payload": {}
}
headers = {
"x-bot-key": "<x-bot-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-bot-key': '<x-bot-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({event_name: 'linear.contact.synced', payload: {}})
};
fetch('https://apps-studio.thena.ai/incoming-webhook/events', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://apps-studio.thena.ai/incoming-webhook/events",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'event_name' => 'linear.contact.synced',
'payload' => [
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-bot-key: <x-bot-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://apps-studio.thena.ai/incoming-webhook/events"
payload := strings.NewReader("{\n \"event_name\": \"linear.contact.synced\",\n \"payload\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-bot-key", "<x-bot-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://apps-studio.thena.ai/incoming-webhook/events")
.header("x-bot-key", "<x-bot-key>")
.header("Content-Type", "application/json")
.body("{\n \"event_name\": \"linear.contact.synced\",\n \"payload\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://apps-studio.thena.ai/incoming-webhook/events")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-bot-key"] = '<x-bot-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"event_name\": \"linear.contact.synced\",\n \"payload\": {}\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"messageId": "12345678-1234-1234-1234-123456789012",
"timestamp": "2024-02-20T12:00:00Z"
}Headers
Bot Key
Body
application/json
Response
Event processed successfully
⌘I