AI bots
Make one third-party HTTP request
Rails makes the request for the run’s http_request tool (D-399). A public GET with no body or secret goes anywhere public; a body, another method or a named secret goes only to a host the bot’s owner or a steward approved, and the first time Rails posts a host card instead. A secret is injected by Rails into its own header and sent only to its host. Private addresses are refused, no redirect is followed, and the answer is marked untrusted.
POST
/
api
/
company
/
v2026-10
/
bots
/
{bot_id}
/
runs
/
{run_id}
/
http-request
Make one third-party HTTP request
curl --request POST \
--url https://api.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"method": "GET",
"url": "https://api.weather.gov/points/40.7608,-111.8910"
}
'import requests
url = "https://api.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request"
payload = {
"method": "GET",
"url": "https://api.weather.gov/points/40.7608,-111.8910"
}
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({method: 'GET', url: 'https://api.weather.gov/points/40.7608,-111.8910'})
};
fetch('https://api.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request', 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.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request",
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([
'method' => 'GET',
'url' => 'https://api.weather.gov/points/40.7608,-111.8910'
]),
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.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request"
payload := strings.NewReader("{\n \"method\": \"GET\",\n \"url\": \"https://api.weather.gov/points/40.7608,-111.8910\"\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.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"method\": \"GET\",\n \"url\": \"https://api.weather.gov/points/40.7608,-111.8910\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request")
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 \"method\": \"GET\",\n \"url\": \"https://api.weather.gov/points/40.7608,-111.8910\"\n}"
response = http.request(request)
puts response.read_body{
"response": {
"status": 200,
"content_type": "application/geo+json",
"body": "{\"properties\":{\"forecast\":\"https://api.weather.gov/gridpoints/SLC/97,175/forecast\"}}",
"truncated": false,
"untrusted": true
},
"status": 200,
"meta": {
"request_uuid": "7e2c9b41-3f8a-4d15-b6e0-9a4c21d7f583",
"timestamp": "2026-10-21T16:10:00Z"
}
}{
"message": "Invalid credentials."
}{
"message": "Not authorized."
}{
"error": {
"message": "Run not found",
"details": {}
},
"status": 404,
"meta": {
"request_uuid": "7e2c9b41-3f8a-4d15-b6e0-9a4c21d7f583",
"timestamp": "2026-10-26T15:32:08Z"
}
}{
"error": {
"message": "The run is not open",
"details": {
"type": "run_closed"
}
},
"status": 409,
"meta": {
"request_uuid": "7e2c9b41-3f8a-4d15-b6e0-9a4c21d7f583",
"timestamp": "2026-10-26T15:32:08Z"
}
}Authorizations
The session token of an admin of your company. Company API, partner and droplet installation tokens are refused.
Path Parameters
The bot's id.
The id of one of the bot's runs.
Body
application/json
Response
The answer, or why it was refused.
⌘I
Make one third-party HTTP request
curl --request POST \
--url https://api.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"method": "GET",
"url": "https://api.weather.gov/points/40.7608,-111.8910"
}
'import requests
url = "https://api.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request"
payload = {
"method": "GET",
"url": "https://api.weather.gov/points/40.7608,-111.8910"
}
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({method: 'GET', url: 'https://api.weather.gov/points/40.7608,-111.8910'})
};
fetch('https://api.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request', 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.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request",
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([
'method' => 'GET',
'url' => 'https://api.weather.gov/points/40.7608,-111.8910'
]),
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.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request"
payload := strings.NewReader("{\n \"method\": \"GET\",\n \"url\": \"https://api.weather.gov/points/40.7608,-111.8910\"\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.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"method\": \"GET\",\n \"url\": \"https://api.weather.gov/points/40.7608,-111.8910\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fluid.app/api/company/v2026-10/bots/{bot_id}/runs/{run_id}/http-request")
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 \"method\": \"GET\",\n \"url\": \"https://api.weather.gov/points/40.7608,-111.8910\"\n}"
response = http.request(request)
puts response.read_body{
"response": {
"status": 200,
"content_type": "application/geo+json",
"body": "{\"properties\":{\"forecast\":\"https://api.weather.gov/gridpoints/SLC/97,175/forecast\"}}",
"truncated": false,
"untrusted": true
},
"status": 200,
"meta": {
"request_uuid": "7e2c9b41-3f8a-4d15-b6e0-9a4c21d7f583",
"timestamp": "2026-10-21T16:10:00Z"
}
}{
"message": "Invalid credentials."
}{
"message": "Not authorized."
}{
"error": {
"message": "Run not found",
"details": {}
},
"status": 404,
"meta": {
"request_uuid": "7e2c9b41-3f8a-4d15-b6e0-9a4c21d7f583",
"timestamp": "2026-10-26T15:32:08Z"
}
}{
"error": {
"message": "The run is not open",
"details": {
"type": "run_closed"
}
},
"status": 409,
"meta": {
"request_uuid": "7e2c9b41-3f8a-4d15-b6e0-9a4c21d7f583",
"timestamp": "2026-10-26T15:32:08Z"
}
}