curl --request PATCH \
--url http://localhost:8080/custom-statuses/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"description": "<string>",
"display_name": "<string>",
"display_description": "<string>",
"color": "<string>",
"icon": "<string>"
}
'import requests
url = "http://localhost:8080/custom-statuses/{id}"
payload = {
"name": "<string>",
"description": "<string>",
"display_name": "<string>",
"display_description": "<string>",
"color": "<string>",
"icon": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
display_name: '<string>',
display_description: '<string>',
color: '<string>',
icon: '<string>'
})
};
fetch('http://localhost:8080/custom-statuses/{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_PORT => "8080",
CURLOPT_URL => "http://localhost:8080/custom-statuses/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'display_name' => '<string>',
'display_description' => '<string>',
'color' => '<string>',
'icon' => '<string>'
]),
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 := "http://localhost:8080/custom-statuses/{id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"display_name\": \"<string>\",\n \"display_description\": \"<string>\",\n \"color\": \"<string>\",\n \"icon\": \"<string>\"\n}")
req, _ := http.NewRequest("PATCH", 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.patch("http://localhost:8080/custom-statuses/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"display_name\": \"<string>\",\n \"display_description\": \"<string>\",\n \"color\": \"<string>\",\n \"icon\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:8080/custom-statuses/{id}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"display_name\": \"<string>\",\n \"display_description\": \"<string>\",\n \"color\": \"<string>\",\n \"icon\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"org_id": "<string>",
"name": "<string>",
"description": "<string>",
"display_name": "<string>",
"display_description": "<string>",
"color": "<string>",
"icon": "<string>",
"parent_status": "closed_resolved",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"statusCode": 123,
"message": "<string>",
"error": "<string>"
}Update a custom status
Change any subset of a custom status. Omitted fields stay as they are; send null to clear a display field, color, or icon.
curl --request PATCH \
--url http://localhost:8080/custom-statuses/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"description": "<string>",
"display_name": "<string>",
"display_description": "<string>",
"color": "<string>",
"icon": "<string>"
}
'import requests
url = "http://localhost:8080/custom-statuses/{id}"
payload = {
"name": "<string>",
"description": "<string>",
"display_name": "<string>",
"display_description": "<string>",
"color": "<string>",
"icon": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
display_name: '<string>',
display_description: '<string>',
color: '<string>',
icon: '<string>'
})
};
fetch('http://localhost:8080/custom-statuses/{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_PORT => "8080",
CURLOPT_URL => "http://localhost:8080/custom-statuses/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'display_name' => '<string>',
'display_description' => '<string>',
'color' => '<string>',
'icon' => '<string>'
]),
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 := "http://localhost:8080/custom-statuses/{id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"display_name\": \"<string>\",\n \"display_description\": \"<string>\",\n \"color\": \"<string>\",\n \"icon\": \"<string>\"\n}")
req, _ := http.NewRequest("PATCH", 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.patch("http://localhost:8080/custom-statuses/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"display_name\": \"<string>\",\n \"display_description\": \"<string>\",\n \"color\": \"<string>\",\n \"icon\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:8080/custom-statuses/{id}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"display_name\": \"<string>\",\n \"display_description\": \"<string>\",\n \"color\": \"<string>\",\n \"icon\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"org_id": "<string>",
"name": "<string>",
"description": "<string>",
"display_name": "<string>",
"display_description": "<string>",
"color": "<string>",
"icon": "<string>",
"parent_status": "closed_resolved",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"statusCode": 123,
"message": "<string>",
"error": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The custom status id
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$Body
Internal name shown to agents (unique per organization, 1-100 chars)
1 - 100Internal note for agents on when to use this status
Built-in status this custom status refines: "open", "closed_resolved", or "closed_unresolved". Applying the custom status to a session moves the session to this built-in status, so an "open"-parented status reopens a closed session and a "closed_*"-parented one closes it. Moving a status across the open/closed boundary drops its ticketing-system stage mappings.
closed_resolved, closed_unresolved, open Customer-facing label (max 100 chars). null clears it back to name; omit to leave unchanged.
100Customer-facing explanation. null clears it; omit to leave unchanged.
Badge color as #RRGGBB. null restores the parent status color; omit to leave unchanged.
^#[0-9a-fA-F]{6}$Inline SVG markup for the badge icon. null restores the default icon; omit to leave unchanged.
10000^<svg[\s>]Response
Default Response
closed_resolved, closed_unresolved, open Was this page helpful?