Live line acceptance check#
Prove that a real inbound call and a real inbound SMS complete end to end on a
deployed demarc runtime, and record a redacted evidence file. The runner reads
runtime state over read-only GET requests: it places no call, sends no
message, and changes no number, carrier or runtime setting.
Before you start#
- A deployed runtime reporting
productionand a healthy/api/ready. - The runtime API token, held in a protected file or secret manager.
- A checkout of the exact revision that is deployed.
- A demarc DID in E.164 form, using
aiorfallbackrouting, with SMS auto-reply enabled and messaging compliance approved for its number type. - A separate phone you can call and text from, also in E.164 form.
- About ten uninterrupted minutes in a quiet place.
The check exercises the receptionist and SMS auto-reply path. Incoming browser calls are not part of it.
Run the check#
Put the runtime API token in the process environment. Read it from a protected file rather than typing it into the command line, where it would enter shell history:
$env:DEMARC_AUTH_TOKEN = (Get-Content -Raw .\runtime-token.txt).Trim()Start the runner against the deployed origin:
uv run python scripts/live_acceptance.py ` --base-url https://runtime.example.com ` --did '+1XXXXXXXXXX' ` --caller '+1YYYYYYYYYY'The origin must be absolute HTTPS. The runner rejects a loopback address and any URL carrying credentials, a query or a fragment.
Wait for preflight to pass. The runner stops before any live action if the runtime is not in production, if database, schema, authentication, Telnyx signature or live voice readiness is incomplete, if operations status reports stale active calls, if the DID is absent from the number list, if the DID is not using
aiorfallbackrouting, if SMS auto-reply is off, or if the number's messaging compliance status is not approved.When preflight passes, the runner prints a one-time SMS marker and polls for the observation window. While it runs, perform only these live actions:
- Call the DID from the caller phone.
- Say the displayed acceptance phrase, hear a meaningful spoken reply, and hang up normally.
- Send the exact displayed marker by SMS to the DID.
Answer the two prompts with
YESonly if the call had intelligible two-way audio and the reply arrived on the caller phone. Any other answer records an incomplete result.
Clear DEMARC_AUTH_TOKEN from the shell when the run finishes.
Options#
| Option | Default | Notes |
|---|---|---|
--base-url |
A built-in origin | Always pass your own deployed HTTPS origin |
--did |
— | Required. demarc DID in E.164 form |
--caller |
— | Required. Caller phone in E.164 form |
--timeout-seconds |
600 |
Observation window, 30 to 3600 |
--poll-seconds |
3 |
Polling interval, 1 to 30 |
--output |
A timestamped file under docs/evidence |
Redacted JSON evidence path |
Verify#
A passing run exits 0, prints ACCEPTANCE PASSED with an acceptance ID, and
writes the redacted JSON evidence file. Open the file and confirm it records the
preflight state, the correlated call and message identifiers, the transcript turn
count and both operator attestations.
The evidence file stores per-run hashes instead of phone numbers, and it records no transcript text, no API token and no auto-reply body.
The runner accepts only records created after the run begins, matched on the exact caller, the exact DID and the printed marker, and it requires a completed call carrying both a caller turn and an assistant turn.
Warning An outbound message state of
sentmeans the carrier accepted the request. It is not a delivery receipt, which is why the handset confirmation is required.
If it does not work#
| Symptom | Check | Recovery |
|---|---|---|
| Preflight failure | The named readiness, routing or compliance setting | Correct it in Configuration or the number's settings, then start a fresh run |
| Timeout with no records | Carrier and platform logs for the printed observation window | Diagnose first, then start a fresh run; a timeout does not identify a failing component |
| Call completed without both turns | Provider health and transcripts, using Troubleshooting | Restore the voice provider chain and start a fresh run |
Outbound message queued, failed or mocked |
Messaging profile, auto-reply setting and compliance status | Fix the messaging path; the round trip is not complete |
Attestation answered as anything but YES |
The handset itself | Keep the artefact for diagnosis only and do not treat the run as acceptance |
A preflight failure is a configuration result, not acceptance evidence. Never treat a local smoke run or an incomplete artefact as a substitute for a passing live check.