List workspace threads
curl --request GET \
--url https://api.matrices.com/v1/threads \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.matrices.com/v1/threads', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.matrices.com/v1/threads"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.matrices.com/v1/threads"
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))
}{
"threads": [
{
"lastSeq": 123,
"messageCount": 123,
"status": "running",
"thread": {
"agentId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"createdBy": {
"id": "<string>",
"type": "user",
"identity": "<string>",
"origin": {
"provider": "slack",
"senderId": "<string>",
"tenantId": "<string>",
"channelId": "<string>",
"messageId": "<string>",
"threadId": "<string>"
},
"sourceThreadId": "<string>"
},
"id": "<string>",
"updatedAt": "2023-11-07T05:31:56Z",
"updatedBy": {
"id": "<string>",
"type": "user",
"identity": "<string>",
"origin": {
"provider": "slack",
"senderId": "<string>",
"tenantId": "<string>",
"channelId": "<string>",
"messageId": "<string>",
"threadId": "<string>"
},
"sourceThreadId": "<string>"
},
"workspaceId": "<string>",
"identity": "<string>",
"maxCost": 1
},
"toolCallCount": 123,
"updatedAt": "2023-11-07T05:31:56Z",
"assistantPreview": "<string>",
"pendingWaits": [
{
"createdAt": "2023-11-07T05:31:56Z",
"id": "<string>",
"target": "url",
"turnId": "<string>",
"asks": [
{
"hookId": "<string>",
"processor": "url",
"reason": "<string>",
"description": "<string>",
"score": 0.5
}
],
"expiresAt": "2023-11-07T05:31:56Z",
"hookId": "<string>",
"point": "before_turn_start",
"preview": {
"title": "<string>",
"link": {
"label": "<string>",
"url": "<string>"
},
"note": "<string>",
"text": "<string>"
},
"processor": "url",
"reason": "<string>",
"toolCallId": "<string>",
"toolInput": "<unknown>",
"toolName": "<string>",
"toolsetId": "<string>"
}
],
"preview": "<string>",
"usage": {
"inputTokens": 123,
"outputTokens": 123,
"totalTokens": 123,
"cacheReadTokens": 123,
"cacheWriteTokens": 123,
"estimatedCost": 123,
"reasoningTokens": 123
},
"userPreview": "<string>"
}
],
"nextCursor": "<string>"
}{
"operation": {
"action": "<string>",
"agentId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"expiresAt": "2023-11-07T05:31:56Z",
"id": "<string>",
"state": "pending",
"resolvedAt": "2023-11-07T05:31:56Z",
"resolvedBy": {
"id": "<string>",
"type": "user",
"identity": "<string>",
"origin": {
"provider": "slack",
"senderId": "<string>",
"tenantId": "<string>",
"channelId": "<string>",
"messageId": "<string>",
"threadId": "<string>"
},
"sourceThreadId": "<string>"
},
"result": {
"status": 349,
"body": "<unknown>"
}
}
}{
"error": "<string>",
"message": "<string>",
"attemptsRemaining": 123,
"code": "<string>",
"retryAfterSeconds": 123
}{
"error": "<string>",
"message": "<string>",
"attemptsRemaining": 123,
"code": "<string>",
"retryAfterSeconds": 123
}Threads
List workspace threads
GET
/
v1
/
threads
List workspace threads
curl --request GET \
--url https://api.matrices.com/v1/threads \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.matrices.com/v1/threads', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.matrices.com/v1/threads"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.matrices.com/v1/threads"
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))
}{
"threads": [
{
"lastSeq": 123,
"messageCount": 123,
"status": "running",
"thread": {
"agentId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"createdBy": {
"id": "<string>",
"type": "user",
"identity": "<string>",
"origin": {
"provider": "slack",
"senderId": "<string>",
"tenantId": "<string>",
"channelId": "<string>",
"messageId": "<string>",
"threadId": "<string>"
},
"sourceThreadId": "<string>"
},
"id": "<string>",
"updatedAt": "2023-11-07T05:31:56Z",
"updatedBy": {
"id": "<string>",
"type": "user",
"identity": "<string>",
"origin": {
"provider": "slack",
"senderId": "<string>",
"tenantId": "<string>",
"channelId": "<string>",
"messageId": "<string>",
"threadId": "<string>"
},
"sourceThreadId": "<string>"
},
"workspaceId": "<string>",
"identity": "<string>",
"maxCost": 1
},
"toolCallCount": 123,
"updatedAt": "2023-11-07T05:31:56Z",
"assistantPreview": "<string>",
"pendingWaits": [
{
"createdAt": "2023-11-07T05:31:56Z",
"id": "<string>",
"target": "url",
"turnId": "<string>",
"asks": [
{
"hookId": "<string>",
"processor": "url",
"reason": "<string>",
"description": "<string>",
"score": 0.5
}
],
"expiresAt": "2023-11-07T05:31:56Z",
"hookId": "<string>",
"point": "before_turn_start",
"preview": {
"title": "<string>",
"link": {
"label": "<string>",
"url": "<string>"
},
"note": "<string>",
"text": "<string>"
},
"processor": "url",
"reason": "<string>",
"toolCallId": "<string>",
"toolInput": "<unknown>",
"toolName": "<string>",
"toolsetId": "<string>"
}
],
"preview": "<string>",
"usage": {
"inputTokens": 123,
"outputTokens": 123,
"totalTokens": 123,
"cacheReadTokens": 123,
"cacheWriteTokens": 123,
"estimatedCost": 123,
"reasoningTokens": 123
},
"userPreview": "<string>"
}
],
"nextCursor": "<string>"
}{
"operation": {
"action": "<string>",
"agentId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"expiresAt": "2023-11-07T05:31:56Z",
"id": "<string>",
"state": "pending",
"resolvedAt": "2023-11-07T05:31:56Z",
"resolvedBy": {
"id": "<string>",
"type": "user",
"identity": "<string>",
"origin": {
"provider": "slack",
"senderId": "<string>",
"tenantId": "<string>",
"channelId": "<string>",
"messageId": "<string>",
"threadId": "<string>"
},
"sourceThreadId": "<string>"
},
"result": {
"status": 349,
"body": "<unknown>"
}
}
}{
"error": "<string>",
"message": "<string>",
"attemptsRemaining": 123,
"code": "<string>",
"retryAfterSeconds": 123
}{
"error": "<string>",
"message": "<string>",
"attemptsRemaining": 123,
"code": "<string>",
"retryAfterSeconds": 123
}Authorizations
APIKeyBearerAgentLeaseBearer
Query Parameters
Filter thread list rows by who created each thread. triggered keeps threads a console user, an API key, or a trigger such as a Slack message started. routine keeps schedule runs and subscription evaluations. agent keeps threads another agent started, such as sub-threads, agent-to-agent asks, and hook-agent decisions. Omit it to list every thread.
Available options:
triggered, routine, agent