ONE voice:receive
← Receivers

voice:receive

voice family

One Twilio-signed call status post (status callback, Dial action or Record action) for a workspace's own number. When it says the call was missed: text the caller back once from that number (fixed words naming the business, Reply STOP to opt out; never to a number that said STOP; at most once per caller per workspace in 24 hours), file the caller as a lead tagged missed-call, keep a voicemail's RecordingSid and URL on the person, and alert the owner (owner-alert, kind missed_call). Missed means the Dial said no-answer, busy, failed or canceled, the call's own status said so, or a voicemail was recorded. Only the channels voice-status door, carrying its HMAC over what Twilio signed; the workspace is read from the called number, never from the caller. A CallSid, and a RecordingSid, are acted on once.

Effect
ask
Awaits an outcome — the call returns the response below.
Caller
write
The class of authority the caller must already hold, decided from the attested context with no round trip.
Cost
variable
What one call costs, so you can budget before acting.
Reversible
no
This cannot be undone. Dry-run it first where the contract allows.
Idempotent
yes
Safe to retry as-is.
Version
1.0.0
Pin this to keep a contract stable; additive bumps never break callers.

Send it with your agent

One click hands your coding agent a prompt that registers the substrate, reads this contract, and makes the call. Launch opens the app; the others copy the prompt.

Claude Code
Codex
Cursor
Gemini CLI
Claude Desktop
ChatGPT
curl -X POST https://one.ie/api/ask/voice:receive \
  -H "Authorization: Bearer $ONE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"data": { "callSid": <string>, "from": <string>, "to": <string>, "attest": <string> }}'

The key is never in a link. npx -y @oneie/cli login writes it to ~/.config/oneie/key on your machine.

Request

Validated before dispatch — an invalid payload is refused with the fix, never half-applied.

  • callSid string required Twilio CallSid: acted on once
  • from string required The caller's number (Twilio From); a hidden or non-E.164 caller is alerted on but never texted
  • to string required The workspace's number that was called (Twilio To): the workspace is read from it
  • callStatus string optional Twilio CallStatus
  • dialStatus string optional Twilio DialCallStatus, from a <Dial action>; wins over callStatus when present
  • recordingSid string optional RE… from a <Record action>: the voicemail
  • recordingUrl string optional Twilio's URL for that recording; kept only when it is api.twilio.com's URL for that very sid
  • recordingDuration string optional
  • attest string required The voice-status door's HMAC-SHA256 (SMS_ATTEST_SECRET) over the eight fields above; without it nothing runs

Response

What comes back from the call.

  • ok boolean
  • workspace string
  • missed boolean false: an answered call; nothing was done
  • duplicate boolean true: this call (and recording) was already handled
  • text string sent · already_texted (inside 24 hours) · no_caller_id · not_first · or sms:send's refusal (consent_declined, sms_not_configured, …)
  • person string The caller's person id in the workspace
  • alerted boolean | "already" The owner alert went out (already: the alert helper had told the owner about this number in the last 30 minutes)
  • alertError string
  • recording "kept"
  • error string forbidden (not a service caller) · unattested (no or wrong door HMAC) · unknown_number · no_db

Traffic

Every call to voice:receive, counted where it is dispatched — over HTTP or in-process alike. Aggregate only — no actor, no payload, no workspace.

Counting…

Wiring

Every place in the open source that names voice:receive, and the file that answers it. Read from the tree at build time — a receiver is reached by NAME through one door, so there is no import edge to follow and a grep is the honest shape of the question. Structure, not volume — the count is in Traffic above.

Called from

API route 3
  • one.ie/web/src/lib/receiver-index.generated.ts:532
  • one.ie/web/src/lib/voice/missed-call.ts:3
  • one.ie/web/src/lib/voice/phone-answer.ts:8
Agent runtime 2
  • channels/src/voice-inbound.ts:29
  • channels/src/voice-status.ts:12
→

Answered by

voice:receive one.ie/web/src/lib/resolvers/voice.ts:183 Dispatched through POST /api/ask/voice:receive, after the envelope validates the payload.
JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "callSid": {
      "type": "string",
      "description": "Twilio CallSid: acted on once"
    },
    "from": {
      "type": "string",
      "description": "The caller's number (Twilio From); a hidden or non-E.164 caller is alerted on but never texted"
    },
    "to": {
      "type": "string",
      "description": "The workspace's number that was called (Twilio To): the workspace is read from it"
    },
    "callStatus": {
      "description": "Twilio CallStatus",
      "type": "string"
    },
    "dialStatus": {
      "description": "Twilio DialCallStatus, from a <Dial action>; wins over callStatus when present",
      "type": "string"
    },
    "recordingSid": {
      "description": "RE… from a <Record action>: the voicemail",
      "type": "string"
    },
    "recordingUrl": {
      "description": "Twilio's URL for that recording; kept only when it is api.twilio.com's URL for that very sid",
      "type": "string"
    },
    "recordingDuration": {
      "type": "string"
    },
    "attest": {
      "type": "string",
      "description": "The voice-status door's HMAC-SHA256 (SMS_ATTEST_SECRET) over the eight fields above; without it nothing runs"
    }
  },
  "required": [
    "callSid",
    "from",
    "to",
    "attest"
  ]
}
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "ok": {
      "type": "boolean"
    },
    "workspace": {
      "type": "string"
    },
    "missed": {
      "description": "false: an answered call; nothing was done",
      "type": "boolean"
    },
    "duplicate": {
      "description": "true: this call (and recording) was already handled",
      "type": "boolean"
    },
    "text": {
      "description": "sent · already_texted (inside 24 hours) · no_caller_id · not_first · or sms:send's refusal (consent_declined, sms_not_configured, …)",
      "type": "string"
    },
    "person": {
      "description": "The caller's person id in the workspace",
      "type": "string"
    },
    "alerted": {
      "description": "The owner alert went out (already: the alert helper had told the owner about this number in the last 30 minutes)",
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "string",
          "const": "already"
        }
      ]
    },
    "alertError": {
      "type": "string"
    },
    "recording": {
      "type": "string",
      "const": "kept"
    },
    "error": {
      "description": "forbidden (not a service caller) · unattested (no or wrong door HMAC) · unknown_number · no_db",
      "type": "string"
    }
  },
  "required": [
    "ok"
  ]
}