Delete inbox
curl --request DELETE \
--url https://api.withallo.com/v2/api/inboxes/{inbox_id} \
--header 'Authorization: <api-key>'import requests
url = "https://api.withallo.com/v2/api/inboxes/{inbox_id}"
headers = {"Authorization": "<api-key>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: '<api-key>'}};
fetch('https://api.withallo.com/v2/api/inboxes/{inbox_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://api.withallo.com/v2/api/inboxes/{inbox_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: <api-key>"
],
]);
$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.withallo.com/v2/api/inboxes/{inbox_id}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "<api-key>")
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.withallo.com/v2/api/inboxes/{inbox_id}")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.withallo.com/v2/api/inboxes/{inbox_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}Boîtes de réception
Supprimer une boîte de réception
Deletes the inbox. Conversations are not affected. With user_id, an inbox with no source in a workspace the caller manages returns 404, and an inbox that also holds lines from another workspace returns 403 FORBIDDEN.
DELETE
/
v2
/
api
/
inboxes
/
{inbox_id}
Delete inbox
curl --request DELETE \
--url https://api.withallo.com/v2/api/inboxes/{inbox_id} \
--header 'Authorization: <api-key>'import requests
url = "https://api.withallo.com/v2/api/inboxes/{inbox_id}"
headers = {"Authorization": "<api-key>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: '<api-key>'}};
fetch('https://api.withallo.com/v2/api/inboxes/{inbox_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://api.withallo.com/v2/api/inboxes/{inbox_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: <api-key>"
],
]);
$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.withallo.com/v2/api/inboxes/{inbox_id}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "<api-key>")
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.withallo.com/v2/api/inboxes/{inbox_id}")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.withallo.com/v2/api/inboxes/{inbox_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}{
"error": {
"type": "<string>",
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"retry_after_seconds": 123
}
}Scope requis :
INBOXES_WRITEComportement
Supprime la boîte de réception et retourne un204 sans corps. Les conversations qu’elle affichait ne sont pas touchées et restent sur leurs lignes.
Passez le paramètre de requête user_id pour supprimer la boîte d’un coéquipier. Seuls les admins et managers de l’espace de travail du coéquipier peuvent le faire. Une boîte sans source dans un espace de travail que l’appelant gère retourne une erreur 404. Une boîte qui contient aussi des lignes d’un autre espace retourne une erreur 403 : seul le coéquipier peut la supprimer.
La suppression d’une boîte est définitive. Les assistants IA connectés via le serveur MCP ne suppriment une boîte que si vous le demandez.
Erreurs
| Statut | Code | Quand |
|---|---|---|
403 | FORBIDDEN | user_id est renseigné et l’appelant n’est ni admin ni manager de l’espace de travail de ce coéquipier, ou la boîte contient aussi des lignes d’un autre espace de travail |
404 | INBOX_NOT_FOUND | Aucune boîte avec cet ID n’appartient au propriétaire, ou, avec user_id, elle n’a aucune source dans un espace de travail que l’appelant gère |
Autorisations
Paramètres de chemin
Inbox ID (inb-*).
Exemple:
"inb-abc123"
Paramètres de requête
Act on a teammate's inbox (usr-*). The caller must be an admin or manager of that teammate's workspace, and only reaches inboxes and sources in workspaces they manage. Omit to act on your own inboxes.
Exemple:
"usr-abc123"
Réponse
Inbox deleted
Cette page vous a-t-elle été utile ?