?

Send-only, by design

The SMS transport is send-only. Inbound SMS requires a public HTTP webhook that the carrier POSTs into — which directly conflicts with rousseau's zero-inbound-surface posture. If your use case needs inbound SMS, run rousseau alongside a purpose-built webhook receiver and route messages through the cron scheduler or the agent-loop embed API.

Start is implemented as a no-op that blocks on ctx.Done() so the transport still slots into the standard daemon wiring shape.

Supported carriers

Carrier Config provider Required fields
Twilio twilio from, account_sid, auth_token
Vonage (formerly Nexmo) vonage from, api_key, auth_token (the API secret)

Twilio configuration

sms:
  provider: twilio
  from: "+15550000000"
  account_sid: "AC..."
  auth_token: "..."

from can be either an E.164 sender number or a Twilio Messaging Service SID (starts with MG…). Messaging Services handle fleet management, sticky-sender routing, and geo-based sender selection — recommended for anything more than single-country traffic.

base_url defaults to https://api.twilio.com/2010-04-01 and only needs an override for regional endpoints or testing.

Vonage configuration

sms:
  provider: vonage
  from: "+15550000000"
  api_key: "abcd1234"
  auth_token: "efgh5678"

auth_token in the Vonage config maps to Vonage's API secret, not their JWT signing key — Vonage authenticates SMS submissions with a simple key/secret pair.

base_url defaults to https://rest.nexmo.com.

Command-line

# Twilio
rousseau sms \
  --provider twilio \
  --from '+15550000000' \
  --account-sid AC... \
  --auth-token ...

# Vonage
rousseau sms \
  --provider vonage \
  --from '+15550000000' \
  --api-key abcd1234 \
  --auth-token efgh5678

Since there is no inbound side, --allow does not apply.

Delivery API

Both providers use their respective REST endpoints:

  • Twilio. POST /2010-04-01/Accounts/{sid}/Messages.json with basic-auth SID/token.
  • Vonage. POST /sms/json with api_key + api_secret in the body.

Returned message IDs are logged; delivery-status webhooks are not consumed (again, no public HTTP surface).

E.164 formatting

from and destination numbers must be in E.164 (+<country><subscriber>). No spaces, no dashes. Twilio Messaging Service SIDs bypass this requirement for the from slot only.

Cost hygiene

  • Set max_tokens on your provider aggressively — SMS is cheap per message but bytes multiply fast if the model generates long replies (Twilio segments at 160 chars for GSM-7 or 70 for UCS-2).
  • Consider rewriting the outbound reply to be terse before handing it to the SMS transport. agent.Options.SystemPrompt is the right place.

Type to search 150+ pages. Ranking: BM25 with title/description boost.