Chat messages

List and fetch chat.message rows for the API key owner. Data is limited to the key owner: messages use userId equal to the owner id.

List messages

GET/users/me/chat-messages
Lists messages for the owner, newest first.

Query parameters

query
FieldTypeRequiredDescription
limitnumber
Optional
How many messages to return per page. Defaults to 100. Must be between 1 and 500.
offsetnumber
Optional
How many messages to skip before returning results. Defaults to 0. Must be between 0 and 1,000,000.

Response

response
ResponseResponse shape
{
  "messages": [
    { "id", "sessionId", "userId", "role", "status", "content", "createdAt" },
    ...
  ]
}

One message

GET/users/me/chat-messages/:messageId
Returns a single message row when it belongs to the key owner.

Response

response
ResponseResponse shape
{
  "message": {
    "id", "sessionId", "userId", "role", "status", "content", "createdAt"
  }
}
404
Returned if the message is missing or not owned. To poll for a long-running Run models response, use this path with the messageId returned when the gateway applies a response deadline.