Skip to main content
Every other channel puts a person at one end — a phone, an inbox, a chat window. This one puts your code there instead. Send your assistant a message with an HTTP request, poll for its reply, and wire it into whatever you’re building. No browser, no phone number, no connected account — just your API key. It’s the same assistant either way. Something you ask for over the API is something you can follow up on in Chat an hour later, and it’ll know what you mean.

What you need

  • Your API key and your assistant’s ID, both from the Console.
  • The base URL: https://api.unify.ai/v0
  • A Bearer token header on every request:
Assistants running in a local deployment don’t receive API messages — this channel is for assistants hosted by Unify.

Sending a message

POST /messages with the assistant’s ID and your message:
You get back a message_id straight away, before your assistant has done anything with it:

Polling for the reply

Your assistant works on the message in the background — it might answer in a second, or go off and actually do the thing first. Poll GET /messages/{message_id} until status flips from processing to completed:
response can come back null on a completed message. That’s not an error — your assistant decides whether a reply is warranted, the same way it does on any other channel, and sometimes doing the task quietly is the right answer.

From Python

The SDK wraps both calls:

Sending files

Upload each file first, then reference it in the message.
1

Upload the file

You get back the file’s metadata:
2

Send the message with the attachment

Files are capped at 25 MB each. Your assistant can send files back too — they arrive as response_attachments on the completed message, each with a download URL.

Tags

Tags are arbitrary strings you can hang off a message. Your assistant treats them as opaque routing labels — it doesn’t read anything into them — and echoes them back on its reply as response_tags.
That’s what makes them useful for bridging: if you’re relaying messages from somewhere else, tag the inbound message with wherever it came from and the reply tells you where to send it back.
Tags are how you keep one assistant serving several surfaces at once without losing track of which reply belongs to which request.