Configure agent integration
curl --request POST \
--url https://api.whirl.sh/api/v1/agents/{agentId}/integration \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"connectedAccount": "<string>",
"enabledForInbound": true,
"enabledForResearch": true,
"config": {},
"rules": [
{
"op": "create",
"ruleText": "<string>",
"ruleId": "<string>",
"enabled": true
}
]
}
'import requests
url = "https://api.whirl.sh/api/v1/agents/{agentId}/integration"
payload = {
"connectedAccount": "<string>",
"enabledForInbound": True,
"enabledForResearch": True,
"config": {},
"rules": [
{
"op": "create",
"ruleText": "<string>",
"ruleId": "<string>",
"enabled": True
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
connectedAccount: '<string>',
enabledForInbound: true,
enabledForResearch: true,
config: {},
rules: [{op: 'create', ruleText: '<string>', ruleId: '<string>', enabled: true}]
})
};
fetch('https://api.whirl.sh/api/v1/agents/{agentId}/integration', 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://api.whirl.sh/api/v1/agents/{agentId}/integration",
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([
'connectedAccount' => '<string>',
'enabledForInbound' => true,
'enabledForResearch' => true,
'config' => [
],
'rules' => [
[
'op' => 'create',
'ruleText' => '<string>',
'ruleId' => '<string>',
'enabled' => true
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://api.whirl.sh/api/v1/agents/{agentId}/integration"
payload := strings.NewReader("{\n \"connectedAccount\": \"<string>\",\n \"enabledForInbound\": true,\n \"enabledForResearch\": true,\n \"config\": {},\n \"rules\": [\n {\n \"op\": \"create\",\n \"ruleText\": \"<string>\",\n \"ruleId\": \"<string>\",\n \"enabled\": true\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://api.whirl.sh/api/v1/agents/{agentId}/integration")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"connectedAccount\": \"<string>\",\n \"enabledForInbound\": true,\n \"enabledForResearch\": true,\n \"config\": {},\n \"rules\": [\n {\n \"op\": \"create\",\n \"ruleText\": \"<string>\",\n \"ruleId\": \"<string>\",\n \"enabled\": true\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.whirl.sh/api/v1/agents/{agentId}/integration")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"connectedAccount\": \"<string>\",\n \"enabledForInbound\": true,\n \"enabledForResearch\": true,\n \"config\": {},\n \"rules\": [\n {\n \"op\": \"create\",\n \"ruleText\": \"<string>\",\n \"ruleId\": \"<string>\",\n \"enabled\": true\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"agentId": "<string>",
"saved": true
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}Agent settings
Configure agent integration
Change an agent’s settings, access and rules for one connected app.
POST
/
agents
/
{agentId}
/
integration
Configure agent integration
curl --request POST \
--url https://api.whirl.sh/api/v1/agents/{agentId}/integration \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"connectedAccount": "<string>",
"enabledForInbound": true,
"enabledForResearch": true,
"config": {},
"rules": [
{
"op": "create",
"ruleText": "<string>",
"ruleId": "<string>",
"enabled": true
}
]
}
'import requests
url = "https://api.whirl.sh/api/v1/agents/{agentId}/integration"
payload = {
"connectedAccount": "<string>",
"enabledForInbound": True,
"enabledForResearch": True,
"config": {},
"rules": [
{
"op": "create",
"ruleText": "<string>",
"ruleId": "<string>",
"enabled": True
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
connectedAccount: '<string>',
enabledForInbound: true,
enabledForResearch: true,
config: {},
rules: [{op: 'create', ruleText: '<string>', ruleId: '<string>', enabled: true}]
})
};
fetch('https://api.whirl.sh/api/v1/agents/{agentId}/integration', 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://api.whirl.sh/api/v1/agents/{agentId}/integration",
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([
'connectedAccount' => '<string>',
'enabledForInbound' => true,
'enabledForResearch' => true,
'config' => [
],
'rules' => [
[
'op' => 'create',
'ruleText' => '<string>',
'ruleId' => '<string>',
'enabled' => true
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://api.whirl.sh/api/v1/agents/{agentId}/integration"
payload := strings.NewReader("{\n \"connectedAccount\": \"<string>\",\n \"enabledForInbound\": true,\n \"enabledForResearch\": true,\n \"config\": {},\n \"rules\": [\n {\n \"op\": \"create\",\n \"ruleText\": \"<string>\",\n \"ruleId\": \"<string>\",\n \"enabled\": true\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://api.whirl.sh/api/v1/agents/{agentId}/integration")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"connectedAccount\": \"<string>\",\n \"enabledForInbound\": true,\n \"enabledForResearch\": true,\n \"config\": {},\n \"rules\": [\n {\n \"op\": \"create\",\n \"ruleText\": \"<string>\",\n \"ruleId\": \"<string>\",\n \"enabled\": true\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.whirl.sh/api/v1/agents/{agentId}/integration")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"connectedAccount\": \"<string>\",\n \"enabledForInbound\": true,\n \"enabledForResearch\": true,\n \"config\": {},\n \"rules\": [\n {\n \"op\": \"create\",\n \"ruleText\": \"<string>\",\n \"ruleId\": \"<string>\",\n \"enabled\": true\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"agentId": "<string>",
"saved": true
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}{
"title": "<string>",
"status": 123,
"code": "<string>",
"type": "<string>",
"detail": "<string>"
}Authorizations
Scopes
Body
application/json
Connected integration type string, e.g. "gmail" or "slack".
Available options:
slack, google_calendar, google_drive, whatsapp, gmail, aircall, smily, granola, breezeway, basecamp, github, notion, optimo_route, onfleet, zendesk, autofleet, hostaway, airtable, ashby, shopify, breww, magento, outlook, outlook_calendar, onedrive, sharepoint, excel, word, teams, gorgias, xero_accounting, pimento, linear, clarus_wms, maxoptra, hubspot_crm, hubspot_conversations, fireflies, resend, guesty, orderspace, hospitable, sparklayer, unleashed, bigblue, otter, skio, trustpilot, webhook, mcp, browser 
