Preview or delete organization inputs (admin or owner)
curl --request POST \
--url https://api.trycarhub.com/mgmt/v1/uploads/deletions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"upload_refs": [
"upl_7Qm2hV9tXbLd"
],
"before": "2023-11-07T05:31:56Z",
"reclaim_bytes": 2,
"dry_run": false
}
'import requests
url = "https://api.trycarhub.com/mgmt/v1/uploads/deletions"
payload = {
"upload_refs": ["upl_7Qm2hV9tXbLd"],
"before": "2023-11-07T05:31:56Z",
"reclaim_bytes": 2,
"dry_run": False
}
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({
upload_refs: ['upl_7Qm2hV9tXbLd'],
before: '2023-11-07T05:31:56Z',
reclaim_bytes: 2,
dry_run: false
})
};
fetch('https://api.trycarhub.com/mgmt/v1/uploads/deletions', 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.trycarhub.com/mgmt/v1/uploads/deletions",
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([
'upload_refs' => [
'upl_7Qm2hV9tXbLd'
],
'before' => '2023-11-07T05:31:56Z',
'reclaim_bytes' => 2,
'dry_run' => false
]),
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.trycarhub.com/mgmt/v1/uploads/deletions"
payload := strings.NewReader("{\n \"upload_refs\": [\n \"upl_7Qm2hV9tXbLd\"\n ],\n \"before\": \"2023-11-07T05:31:56Z\",\n \"reclaim_bytes\": 2,\n \"dry_run\": false\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.trycarhub.com/mgmt/v1/uploads/deletions")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"upload_refs\": [\n \"upl_7Qm2hV9tXbLd\"\n ],\n \"before\": \"2023-11-07T05:31:56Z\",\n \"reclaim_bytes\": 2,\n \"dry_run\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.trycarhub.com/mgmt/v1/uploads/deletions")
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 \"upload_refs\": [\n \"upl_7Qm2hV9tXbLd\"\n ],\n \"before\": \"2023-11-07T05:31:56Z\",\n \"reclaim_bytes\": 2,\n \"dry_run\": false\n}"
response = http.request(request)
puts response.read_body{
"error": {
"type": "permission",
"code": "scope_not_granted",
"message": "This API key is not scoped for the `render` endpoint family.",
"param": null,
"doc_url": "https://docs.trycarhub.com/errors/scope_not_granted",
"request_id": "req_2Kd8xQmPvL4T"
}
}Management
Preview or delete organization inputs (admin or owner)
POST
/
mgmt
/
v1
/
uploads
/
deletions
Preview or delete organization inputs (admin or owner)
curl --request POST \
--url https://api.trycarhub.com/mgmt/v1/uploads/deletions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"upload_refs": [
"upl_7Qm2hV9tXbLd"
],
"before": "2023-11-07T05:31:56Z",
"reclaim_bytes": 2,
"dry_run": false
}
'import requests
url = "https://api.trycarhub.com/mgmt/v1/uploads/deletions"
payload = {
"upload_refs": ["upl_7Qm2hV9tXbLd"],
"before": "2023-11-07T05:31:56Z",
"reclaim_bytes": 2,
"dry_run": False
}
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({
upload_refs: ['upl_7Qm2hV9tXbLd'],
before: '2023-11-07T05:31:56Z',
reclaim_bytes: 2,
dry_run: false
})
};
fetch('https://api.trycarhub.com/mgmt/v1/uploads/deletions', 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.trycarhub.com/mgmt/v1/uploads/deletions",
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([
'upload_refs' => [
'upl_7Qm2hV9tXbLd'
],
'before' => '2023-11-07T05:31:56Z',
'reclaim_bytes' => 2,
'dry_run' => false
]),
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.trycarhub.com/mgmt/v1/uploads/deletions"
payload := strings.NewReader("{\n \"upload_refs\": [\n \"upl_7Qm2hV9tXbLd\"\n ],\n \"before\": \"2023-11-07T05:31:56Z\",\n \"reclaim_bytes\": 2,\n \"dry_run\": false\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.trycarhub.com/mgmt/v1/uploads/deletions")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"upload_refs\": [\n \"upl_7Qm2hV9tXbLd\"\n ],\n \"before\": \"2023-11-07T05:31:56Z\",\n \"reclaim_bytes\": 2,\n \"dry_run\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.trycarhub.com/mgmt/v1/uploads/deletions")
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 \"upload_refs\": [\n \"upl_7Qm2hV9tXbLd\"\n ],\n \"before\": \"2023-11-07T05:31:56Z\",\n \"reclaim_bytes\": 2,\n \"dry_run\": false\n}"
response = http.request(request)
puts response.read_body{
"error": {
"type": "permission",
"code": "scope_not_granted",
"message": "This API key is not scoped for the `render` endpoint family.",
"param": null,
"doc_url": "https://docs.trycarhub.com/errors/scope_not_granted",
"request_id": "req_2Kd8xQmPvL4T"
}
}Authorizations
Short-lived JWT issued by the CarHub auth service (Better Auth), verified against its
JWKS. Claims: sub (user), org_id (active organisation) and role
(owner | admin | member). Used by the dashboard for /mgmt/v1/… only — it is never
accepted on /v1/….
Body
application/json
- Option 1
- Option 2
- Option 3
Exactly one selector is required.
Response
Dry-run preview.