Disconnect a connection
curl --request DELETE \
--url https://api.runaether.dev/connections/{connectionID} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.runaether.dev/connections/{connectionID}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.runaether.dev/connections/{connectionID}', 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.runaether.dev/connections/{connectionID}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.runaether.dev/connections/{connectionID}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.runaether.dev/connections/{connectionID}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.runaether.dev/connections/{connectionID}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "org_membership_required",
"error": "<string>"
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}Connections
Disconnect a connection
Disconnects one of the caller’s connections, removing it and leaving every other connection in place.
Use this tool when you need to:
- Remove a stored credential the caller no longer wants tasks to run on
- Drop a connection that needs re-authentication and will not be reconnected
Examples:
- DELETE /connections/
- DELETE /connections/6f1c2a9e-3b7d-4c55-9a2e-0d8b1f4e7c21
Hints:
- connectionID is the connection’s uuid (the schema answers 422 for a value that is not a uuid, and one that is not a canonical lowercase uuid is 404 connection_not_found); answers 204.
- The connection is disconnected at once: it leaves every list and read, and its name and ChatGPT account are free for a new connection. The tasks and profiles that name it follow shortly after, in the background.
- Claude Code and Codex tasks that run on the connection move to the harness’s default as it stands when they move, so their next turn runs there; disconnecting the harness’s last connection moves them to Aether inference.
- OpenCode tasks that run on the connection are disconnected until a connection is chosen for each (patchTask with runs_on), and the last OpenCode connection leaves no default. A default’s or a profile’s fallback that names the connection is left disconnected (its connection_id absent).
- Refused, in this order, with 409 connection_runs_agent while the caller’s agent runs on it (move the agent with patchAgent’s runs_on first), 409 connection_runs_profiles while agent profiles run on it (the message names them: pin another connection, or nobody, on each with patchAgentProfile’s runs_on first), and 409 connection_is_default while it is a harness’s default and the caller holds another connection that harness’s tasks could run on (the message names them: make one the default with setDefaultConnection first).
- Use reconnectConnection instead to replace its credential and keep its id (createChatgptPlanDeviceAuth with mode reconnect for a ChatGPT plan).
- Any signed-in user, for their own connections; through a platform API key pinned to an org where the caller is a viewer or billing member it is refused with 403 org_role_insufficient, and an agent host’s grant with 403 agent_host_route_not_allowed. A connection the caller does not hold is 404 connection_not_found.
DELETE
/
connections
/
{connectionID}
Disconnect a connection
curl --request DELETE \
--url https://api.runaether.dev/connections/{connectionID} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.runaether.dev/connections/{connectionID}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.runaether.dev/connections/{connectionID}', 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.runaether.dev/connections/{connectionID}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.runaether.dev/connections/{connectionID}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.runaether.dev/connections/{connectionID}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.runaether.dev/connections/{connectionID}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "org_membership_required",
"error": "<string>"
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "aether_inference_unavailable",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}