Threads

Send message

Sends a user message with optional uploaded attachments to a thread and triggers AI processing.

The thread must be in ready state — the only state in which new messages are accepted. Returns 409 if the thread is not ready.

After sending, the thread transitions:

  • waiting — message is queued for the AI processor
  • active — the LLM is generating a response
  • ready — response is complete; the thread accepts new messages again

Use the SSE stream endpoint or poll the thread state field to know when the thread returns to ready.

post/threads/{thread-id}/messages

Request

  • Base URL: https://api.korey.ai/api/v1
  • URL: https://api.korey.ai/api/v1/threads/{thread-id}/messages
  • Auth: HTTP bearer

Path parameters

thread-idstring uuid required

The thread ID.

Request body

textstring required

The user message text to send.

attachment_idsstring[]

IDs of files uploaded to this thread, in display order. May reference files from multiple upload requests, up to the thread limit of 25 attachments.

Response

Created

message_idstring required

ID of the newly created message. Use this to poll or stream the AI response.

Changes

No recorded changes to this operation across all 1 revision of this API.