Computers
Delete computer
Permanently delete a computer.
DELETE
/
computers
/
{id}
Delete computer
curl --request DELETE \
--url https://www.orgo.ai/api/computers/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://www.orgo.ai/api/computers/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://www.orgo.ai/api/computers/{id}', 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://www.orgo.ai/api/computers/{id}",
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://www.orgo.ai/api/computers/{id}"
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://www.orgo.ai/api/computers/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.orgo.ai/api/computers/{id}")
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{
"success": true
}Permanently deletes a computer and all its data.
The record is always removed, even when the computer has no live host. An already-terminated computer, an unreachable host, and a
This cannot be undone. The disk and everything on it is lost.
creating record that never finished provisioning all delete cleanly. Tearing down the computer on its host is best-effort and never blocks the delete.
Deleting a computer does not release its dedicated egress IP, and does not stop the charge for it. The delete tears down the route to the computer and clears the designation, so the IP stops carrying traffic. The IP itself stays allocated to you and stays billed. Release it separately with
DELETE /api/egress-ips/{id}, or reassign it to another computer with PATCH /api/egress-ips/{id}.Path parameters
string
required
Computer UUID or
instance_id. Both resolve to the same computer.Response
boolean
true when the computer was deleted.Example
curl -X DELETE https://www.orgo.ai/api/computers/$COMPUTER_ID \
-H "Authorization: Bearer $ORGO_API_KEY"
import requests
response = requests.delete(
f"https://www.orgo.ai/api/computers/{computer_id}",
headers={"Authorization": f"Bearer {api_key}"}
)
if response.json().get("success"):
print("Computer deleted")
const response = await fetch(`https://www.orgo.ai/api/computers/${computerId}`, {
method: 'DELETE',
headers: { 'Authorization': `Bearer ${apiKey}` }
});
const { success } = await response.json();
if (success) console.log('Computer deleted');
Response
{
"success": true
}
Errors
| Status | Body | When |
|---|---|---|
401 | { "error": "Invalid API key" } | The Bearer token starts with sk_ but is not a known Orgo key. |
401 | { "error": "Authentication required" } | No Authorization header, or a Bearer token that is not an sk_ key. |
403 | { "error": "Access denied" } | You are neither the owner nor a member of the computer’s workspace. |
404 | { "error": "Desktop not found" } | No computer matches the id. |
500 | { "error": "…" } | The record could not be removed; the body carries the failure message. |
⌘I
Delete computer
curl --request DELETE \
--url https://www.orgo.ai/api/computers/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://www.orgo.ai/api/computers/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://www.orgo.ai/api/computers/{id}', 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://www.orgo.ai/api/computers/{id}",
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://www.orgo.ai/api/computers/{id}"
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://www.orgo.ai/api/computers/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.orgo.ai/api/computers/{id}")
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{
"success": true
}