Guides / Talk to Your Agent
Talk to Your Agent
Send messages, wait for the reply inline or poll, and keep retries safe with a client request id.
A message through the API is exactly what typing into the dashboard chat does. The agent reads it, works, and replies in one or more bubbles.
One call, with the reply inline
Pass waitSeconds (up to 120) and the request stays open until the agent has replied or failed. Replies usually land in well under a minute.
curl -X POST -H "Authorization: Bearer $REVNU_API_TOKEN" \
-H "content-type: application/json" \
-d '{"text":"Which leads replied this week?","waitSeconds":90}' \
https://revnu.com/api/v1/agent/messagesA 200 carries the finished message with its replies. If the wait runs out you get 202 with the last observed state and a requestId to keep polling.
Or post and poll
Without waitSeconds the POST returns 202 immediately. Poll GET /agent/messages/{requestId} every few seconds; status moves queued → running → replied, or failed with a failure message.
Safe retries
Pass clientRequestId (up to 128 characters). A retried POST with the same id returns the original requestId instead of sending a second message. A failed message should be re-sent with a new id.
Each token is its own conversation
Your dashboard and Slack threads are not visible through the API, and API messages do not appear in them. GET /agent/thread returns this token's conversation, newest first.
Agents: this page is also markdown at /docs/talk-to-your-agent.md, answers Accept: text/markdown, and is listed in /docs/llms.txt.
Frequently Asked Questions
Yes. It is the same agent with the same tools. Ask it to draft outreach and the draft lands in the review queue like any other.