Assistant
Compact thread.
Manually compact an assistant thread into a Revo-owned agent handoff artifact while preserving continuation context.
POST
/
api
/
v1
/
assistant
/
threads
/
{id}
/
compact
Compact thread.
curl --request POST \
--url https://api.revoengine.com/api/v1/assistant/threads/{id}/compact \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"keepContext": true,
"content": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({keepContext: true, content: '<string>'})
};
fetch('https://api.revoengine.com/api/v1/assistant/threads/{id}/compact', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.revoengine.com/api/v1/assistant/threads/{id}/compact"
payload = {
"keepContext": True,
"content": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)Authorizations
Bearer JWT token or API Key (sk-*).
Path Parameters
Body
application/json
Response
Thread compacted.
⌘I
Compact thread.
curl --request POST \
--url https://api.revoengine.com/api/v1/assistant/threads/{id}/compact \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"keepContext": true,
"content": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({keepContext: true, content: '<string>'})
};
fetch('https://api.revoengine.com/api/v1/assistant/threads/{id}/compact', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.revoengine.com/api/v1/assistant/threads/{id}/compact"
payload = {
"keepContext": True,
"content": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)
