aiThreadsGetMessageById
AiThreadMessageLike aiThreadsGetMessageById(messageId)
GET /api/2.0/ai/threads/get-message-by-id
Get one chat message
Returns one message by its ID, wherever it sits, without needing the thread it belongs to. messageId is required. Unlike GET api/2.0/ai/threads/get-by-id an unknown ID is not reported as 404: the answer is an empty body with status 200, so a client has to treat a missing payload as no such message. Message IDs come from the thread history or from the answer of POST api/2.0/ai/threads/append-user-message.
Parameters
| Name | In | Type | Description | Notes |
|---|---|---|---|---|
| messageId | query | String | The globally unique chat message identifier. | [required] [example: 22222222-2222-2222-2222-222222222222] |
Responses
| Status code | Description | Type | Response headers |
|---|---|---|---|
| 200 | The message, or an empty body when no message has that ID. | AiThreadMessageLike | - |
| 400 | messageId is missing. | AiErrorResponse | - |
| 401 | Missing asc_auth_key cookie or Authorization header. | AiErrorResponse | - |
| 403 | AI is disabled for this portal, the caller is a guest, or the room named by entityId is one the caller cannot open. Relayed from the DocSpace AI service or the Files API. | AiErrorResponse | - |
| 500 | Unhandled failure. The reason is logged server-side and never echoed back. | AiErrorResponse | - |
Return type
Authorization
HTTP request headers
- Content-Type: Not defined
- Accept: application/json