curl --request GET \
--url https://api.hq.zone/v1/api/email/endpoints \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.hq.zone/v1/api/email/endpoints"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.hq.zone/v1/api/email/endpoints', 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.hq.zone/v1/api/email/endpoints",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
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.hq.zone/v1/api/email/endpoints"
req, _ := http.NewRequest("GET", 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.get("https://api.hq.zone/v1/api/email/endpoints")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hq.zone/v1/api/email/endpoints")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"endpoints": [
{
"allow_escalation": true,
"allow_patterns": [
"<string>"
],
"awaiting_review": 123,
"court_intake_enabled": true,
"court_secure_mail_password_set": true,
"created_at": "2023-11-07T05:31:56Z",
"enabled": true,
"escalated": 123,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"is_system": true,
"kind": "<string>",
"localpart": "<string>",
"message_count": 123,
"needs_attention": 123,
"plane": "<string>",
"received": 123,
"replied": 123,
"reply_languages": "<unknown>",
"reply_policy": "<string>",
"sender_policy": "<string>",
"unrouted": 123,
"updated_at": "2023-11-07T05:31:56Z",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"category_policy": "<unknown>",
"default_reply_lang": "<string>",
"deliver_to": "<unknown>",
"instructions": "<string>",
"last_occurred_at": "2023-11-07T05:31:56Z",
"max_turns_per_day": 123,
"max_turns_per_sender_day": 123,
"spam_score_max": 123
}
],
"outbound_mailbox_localpart": "<string>",
"domain": "<string>",
"tenant_email_slug": "<string>"
}List email endpoints
Lists the workspace’s inbound email endpoints (custom inboxes plus the HQ-managed workspace mailbox), each with its configuration and per-endpoint counters: total messages, items needing attention, inbound received, outbound replies, awaiting-review, unrouted and escalated counts, and a reply-language distribution. Also returns the workspace email slug, email domain and outbound mailbox localpart so a full address can be previewed without another call. Admin only and scoped to the caller’s workspace.
curl --request GET \
--url https://api.hq.zone/v1/api/email/endpoints \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.hq.zone/v1/api/email/endpoints"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.hq.zone/v1/api/email/endpoints', 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.hq.zone/v1/api/email/endpoints",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
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.hq.zone/v1/api/email/endpoints"
req, _ := http.NewRequest("GET", 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.get("https://api.hq.zone/v1/api/email/endpoints")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hq.zone/v1/api/email/endpoints")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"endpoints": [
{
"allow_escalation": true,
"allow_patterns": [
"<string>"
],
"awaiting_review": 123,
"court_intake_enabled": true,
"court_secure_mail_password_set": true,
"created_at": "2023-11-07T05:31:56Z",
"enabled": true,
"escalated": 123,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"is_system": true,
"kind": "<string>",
"localpart": "<string>",
"message_count": 123,
"needs_attention": 123,
"plane": "<string>",
"received": 123,
"replied": 123,
"reply_languages": "<unknown>",
"reply_policy": "<string>",
"sender_policy": "<string>",
"unrouted": 123,
"updated_at": "2023-11-07T05:31:56Z",
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"category_policy": "<unknown>",
"default_reply_lang": "<string>",
"deliver_to": "<unknown>",
"instructions": "<string>",
"last_occurred_at": "2023-11-07T05:31:56Z",
"max_turns_per_day": 123,
"max_turns_per_sender_day": 123,
"spam_score_max": 123
}
],
"outbound_mailbox_localpart": "<string>",
"domain": "<string>",
"tenant_email_slug": "<string>"
}Authorizations
Personal Access Token. Send as Authorization: Bearer hq_pat_....
Response
Inbound email endpoints + counters
Show child attributes
Show child attributes
The localpart of the workspace outbound mailbox (default 'team'); the
full address is <localpart>-<tenant_email_slug>@<domain>.
The tenant's canonical email slug + domain so the UI can preview the
full <localpart>-<slug>@<domain> address without another call.