Skip to main content
POST
Send a message to the Mihu Assistant

Authorizations

Authorization
string
header
required

Use a Bearer token to access these API endpoints. Example: "Bearer {your-token}"

Body

application/json
text
string
required

The message for the assistant, in any language. It answers in the language of the message.

Maximum string length: 20000
Example:

"How many appointments do we have tomorrow?"

session_uuid
string<uuid> | null

Continue an existing assistant session (from an earlier response or GET /api/v1/assistant/sessions). Omit to start a new one.

user_email
string<email>

The workspace member this conversation belongs to; defaults to the workspace owner when omitted. The session shows up in that member's assistant history in the app (Assistant → History), and a session_uuid can only be continued by the same member. Unknown email answers 404.

Example:

"john.doe@example.com"

callback_url
string<uri> | null

Where to POST the reply when it is ready (JSON {event, data, timestamp}, same data shape as the 200 response). Retried up to three times. Independent of the workspace webhook, which also fires.

Example:

"https://example.com/hooks/mihu-assistant"

callback_secret
string | null

When set, the callback carries X-Mihu-Signature: hex HMAC-SHA256 of the raw body with this secret.

wait
boolean
default:true

true (default) = run the turn now and return the reply in this response (up to about two minutes). false = answer 202 at once and deliver the reply later via callback_url, the assistant_reply webhook or polling.

title
string | null

Title for a new session; defaults to the first words of the message.

Maximum string length: 200

Response

Reply (default)

success
boolean
message
string
data
object