Delete a team organization
curl --request DELETE \
--url https://api.runaether.dev/orgs/{orgID} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.runaether.dev/orgs/{orgID}"
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/orgs/{orgID}', 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/orgs/{orgID}",
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/orgs/{orgID}"
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/orgs/{orgID}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.runaether.dev/orgs/{orgID}")
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": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "org_membership_required",
"error": "<string>"
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}Organizations
Delete a team organization
Deletes a team organization with its memberships, invitations, seat requests and org-pinned API keys, once it holds nothing else.
Use this tool when you need to:
- Delete a team organization nobody uses any more
- Remove an organization created by mistake, before anything was made in it
Examples:
- DELETE /orgs/6f1c2a9e-3b7d-4c55-9a2e-0d8b1f4e7c21
Hints:
- orgID is the organization’s uuid. Answers 204; there is no undo.
- Refused, deleting nothing, for a personal organization (409 personal_org_delete_forbidden), while it has another member (409 org_has_members), while a subscription still bills it, active, trialing, incomplete, past_due, unpaid or paused (409 org_has_subscription), and while it still holds projects, tasks, workspaces, warm slots, automations, agent profiles, integrations or billing history (409 org_not_empty, naming them).
- Any such record holds it: an archived project, an ended subscription or any other payment record counts.
- Use removeOrgMember first to clear the other members, or updateOrgMemberRole with role owner instead to hand the organization over; getBillingSubscription reads the subscription, and a personal organization goes only with its account (deleteProfile).
- Only its owner may, from a session-authenticated sign-in: a JWT without a session is refused with 403 session_auth_required before membership is checked, any other member with 403 org_role_insufficient, a non-member with 404 org_not_found, and credentials other than a session, such as a platform API key, with 401.
DELETE
/
orgs
/
{orgID}
Delete a team organization
curl --request DELETE \
--url https://api.runaether.dev/orgs/{orgID} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.runaether.dev/orgs/{orgID}"
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/orgs/{orgID}', 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/orgs/{orgID}",
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/orgs/{orgID}"
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/orgs/{orgID}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.runaether.dev/orgs/{orgID}")
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": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "org_membership_required",
"error": "<string>"
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}{
"code": "already_org_member",
"error": "<string>",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
]
}