curl --request PATCH \
--url https://api.modem.dev/v1/topics/{topicId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"archived": true,
"archivedReason": "<string>",
"keywords": [
"<string>"
]
}
'import requests
url = "https://api.modem.dev/v1/topics/{topicId}"
payload = {
"archived": True,
"archivedReason": "<string>",
"keywords": ["<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({archived: true, archivedReason: '<string>', keywords: ['<string>']})
};
fetch('https://api.modem.dev/v1/topics/{topicId}', 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.modem.dev/v1/topics/{topicId}",
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([
'archived' => true,
'archivedReason' => '<string>',
'keywords' => [
'<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 := "https://api.modem.dev/v1/topics/{topicId}"
payload := strings.NewReader("{\n \"archived\": true,\n \"archivedReason\": \"<string>\",\n \"keywords\": [\n \"<string>\"\n ]\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("https://api.modem.dev/v1/topics/{topicId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"archived\": true,\n \"archivedReason\": \"<string>\",\n \"keywords\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.modem.dev/v1/topics/{topicId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"archived\": true,\n \"archivedReason\": \"<string>\",\n \"keywords\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"archivedByUserId": "<string>",
"archivedReason": "<string>",
"eventCount": 123,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"issueType": "bug_report",
"keywords": [
"<string>"
],
"lifecycleState": "completed",
"lifecycleStateConfidence": 0.5,
"priority": "default",
"priorityReasoning": "<string>",
"summary": "<string>",
"title": "<string>",
"archivedAt": "2023-11-07T05:31:56Z",
"createdAt": "2023-11-07T05:31:56Z",
"timeRangeEnd": "<unknown>",
"timeRangeStart": "<unknown>",
"updatedAt": "2023-11-07T05:31:56Z"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}Update topic
Update a single topic. Supports changing priority, lifecycle state, issue type, keywords, archiving (archived=true), and unarchiving (archived=false). At least one field must be provided.
curl --request PATCH \
--url https://api.modem.dev/v1/topics/{topicId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"archived": true,
"archivedReason": "<string>",
"keywords": [
"<string>"
]
}
'import requests
url = "https://api.modem.dev/v1/topics/{topicId}"
payload = {
"archived": True,
"archivedReason": "<string>",
"keywords": ["<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({archived: true, archivedReason: '<string>', keywords: ['<string>']})
};
fetch('https://api.modem.dev/v1/topics/{topicId}', 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.modem.dev/v1/topics/{topicId}",
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([
'archived' => true,
'archivedReason' => '<string>',
'keywords' => [
'<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 := "https://api.modem.dev/v1/topics/{topicId}"
payload := strings.NewReader("{\n \"archived\": true,\n \"archivedReason\": \"<string>\",\n \"keywords\": [\n \"<string>\"\n ]\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("https://api.modem.dev/v1/topics/{topicId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"archived\": true,\n \"archivedReason\": \"<string>\",\n \"keywords\": [\n \"<string>\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.modem.dev/v1/topics/{topicId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"archived\": true,\n \"archivedReason\": \"<string>\",\n \"keywords\": [\n \"<string>\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"archivedByUserId": "<string>",
"archivedReason": "<string>",
"eventCount": 123,
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"issueType": "bug_report",
"keywords": [
"<string>"
],
"lifecycleState": "completed",
"lifecycleStateConfidence": 0.5,
"priority": "default",
"priorityReasoning": "<string>",
"summary": "<string>",
"title": "<string>",
"archivedAt": "2023-11-07T05:31:56Z",
"createdAt": "2023-11-07T05:31:56Z",
"timeRangeEnd": "<unknown>",
"timeRangeStart": "<unknown>",
"updatedAt": "2023-11-07T05:31:56Z"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}{
"code": "NOT_FOUND",
"defined": true,
"message": "<string>",
"status": 404,
"data": "<unknown>"
}Authorizations
Organization API key (modem_…).
Headers
Replays a successful mutating request for 24 hours. Reuse with a different payload returns 409.
255Path Parameters
Body
Set to true to archive the topic, false to unarchive it.
Optional reason for archiving. Only used when archived=true.
4000Classification for the topic as a type of issue.
bug_report, complaint, discussion, feature_request, praise Replace the topic keywords/categories. Provide the full list of keywords.
201 - 50Update the topic lifecycle state. Valid values: open, in_progress, completed, dismissed. The unknown state is AI-assessed and cannot be set directly.
completed, dismissed, in_progress, open Update the topic priority. Valid values: very_low, low, default, high, very_high.
default, high, low, very_high, very_low Response
OK
Detailed topic fields including archived status.
User who archived the topic.
Optional reason for archiving.
4000Number of events grouped under this topic.
Classification for the topic as a type of issue.
bug_report, complaint, discussion, feature_request, praise Keywords associated with the topic.
LLM-assessed lifecycle state for a topic.
completed, dismissed, in_progress, open, unknown Confidence for the most recent lifecycle assessment.
0 <= x <= 1Priority level: very_low, low, default, high, or very_high
default, high, low, very_high, very_low Reasoning from the most recent automatic topic-priority scoring decision. Null when priority was manually overridden or never auto-scored.
Descriptive summary of the topic.
Short human-readable title of the topic.
Timestamp when the topic was archived.
Timestamp when the topic was last updated.
Was this page helpful?