Skip to Content
Browse the Docs▾

Quickstart

From a fresh token to approving a card and getting a reply from your agent, using nothing but curl.

Five steps, each one curl command. By the end you will have approved a card and had a conversation with Revnu from a terminal.

No account yet? npx @revnu/cli setup creates one and sets it up from your terminal. See Install the CLI.

1. Mint a token

In the dashboard, open Settings → Developers, give it a label and only the scopes the tool needs. The token is shown once. We store a hash. Export it for the rest of this page:

export REVNU_API_TOKEN=rvp_…

Tip

For this walkthrough tick review:read, review:write and agent:message. For anything that only reads, use read scopes alone: a leaked review:read, results:read or leads:read token cannot cause a send, a publish or a spend. See Authentication and Scopes.

2. Check who you are

GET /me needs no scope, so it is the call to verify any token with.

curl -H "Authorization: Bearer $REVNU_API_TOKEN" https://revnu.com/api/v1/me
{
  "me": {
    "label": "quickstart",
    "scopes": ["review:read", "review:write", "agent:message"],
    "account": { "id": "…", "name": "Acme" },
    "inSetup": false,
    "limits": { "reads": { "perMinute": 300, "burst": 600 }, "…": "…" }
  }
}

3. Read what is waiting

curl -H "Authorization: Bearer $REVNU_API_TOKEN" "https://revnu.com/api/v1/review?limit=10"

Every card carries actions, the exact verbs the API accepts for it, and primaryLabel, what the dashboard's main button says. Drive your UI from those, never from the card type.

4. Approve it

curl -X POST -H "Authorization: Bearer $REVNU_API_TOKEN" \
  -H "content-type: application/json" -d '{"action":"approve"}' \
  https://revnu.com/api/v1/review/k97…/answer

Warning

This is a real approval. A blog draft publishes, a Reddit comment posts, an ad launch turns campaigns on. Email cards go through /send instead, because sending email holds a delivery lease. The full list is in Answer a card.

5. Ask the agent something

curl -X POST -H "Authorization: Bearer $REVNU_API_TOKEN" \
  -H "content-type: application/json" \
  -d '{"text":"What did we ship this week?","waitSeconds":90}' \
  https://revnu.com/api/v1/agent/messages

With waitSeconds the request stays open until Revnu replies, and the response is 200 with the reply inline. Without it you get 202 and a requestId to poll. A new message stops work Revnu is still doing for this token, so wait for the reply before sending the next one, or see Talk to Your Agent for handing over several jobs.

Next

Frequently Asked Questions

Do I need an SDK?

No. The API is plain JSON over HTTPS with a bearer header, so any HTTP client works. The @revnu/cli package is a convenience for the terminal and for MCP hosts, not a requirement.

Why did my approve return 409?

The card does not accept that verb right now. The response lists the verbs it does accept in actions. Most often the card was already resolved, or it is an email card that needs /send.