Agents

Verify the person

Have the person the task acts for prove it is them from inside the conversation, then redeem the proof on the check.

A permission that requires verification answers allow_with_step_up. The agent then starts a verification for the person its task acts for, the person completes it (reads a code back, approves a push, opens a link), and the agent passes the verification's token as challenge on the next check.

Every answer has a say line the agent can speak or write as is.

Start a verification#

POST/v1/auth/:app_id/agent/verificationsTask token
methodstringrequired
email_otp, sms_otp, totp, backup_code, entra_push, push or magic_link.
permissionstring
The permission this verification is for, for example invoice:refund. The proof then counts only for that permission. Must be within the task's actions.
session_idstring
The conversation it was started from. When it completes, that session is marked verified.
curl -X POST https://api.scute.io/v1/auth/$SCUTE_APP_ID/agent/verifications \  -H "Authorization: Bearer $TASK_TOKEN" \  -H "Content-Type: application/json" \  -d '{ "method": "email_otp", "permission": "invoice:refund" }'

Scute answers 201:

{  "token": "CHALLENGE_TOKEN",  "status": "pending",  "method": "email_otp",  "expires_at": "2026-11-19T10:10:00Z",  "say": "I've emailed a code to s***@example.com. What's the code?"}

For code methods the answer also has remaining_attempts. A task can start at most 5 verifications per hour, so a looping agent cannot flood the person.

Pass on a code#

POST/v1/auth/:app_id/agent/verifications/:token/codeTask token
codestringrequired
The code the person read out.

Answers 200 with status: "completed" when the code is right, or 422 with error and a say line such as "That code didn't work. Want to try again?" while attempts remain.

GET/v1/auth/:app_id/agent/verifications/:tokenTask token

For push, entra_push and magic_link, poll until status is no longer pending.

statusMeaning
pendingWaiting for the person
completedVerified
expiredRan out of time
deniedThe person declined
failed, cancelledDid not go through

Redeem the proof#

Send the completed verification's token as challenge on the check:

curl -X POST https://api.scute.io/v1/auth/$SCUTE_APP_ID/agent/check \  -H "Authorization: Bearer $TASK_TOKEN" \  -H "Content-Type: application/json" \  -d '{ "action": "refund", "resource": "invoice:42", "challenge": "CHALLENGE_TOKEN" }'

A proof counts when it belongs to the same person, completed in the last 10 minutes, and has not been used. When it was started with permission, it counts only for that permission. When the permission has a verification TTL, one proof covers it for that long; otherwise every check needs a new proof.

Conversations#

A session records one conversation or call under a task: the channel, your reference for it, and whether the person was verified in it. Sessions are what session trust and the backend's conversation lookups work on.

POST/v1/auth/:app_id/agent/sessionsTask token
channelstring
For example voice or chat. Up to 40 characters.
external_refstring
Your platform's id for the conversation. Up to 200 characters. Your backend can look the conversation up by it.
callerobject
What you know about the caller.
POST/v1/auth/:app_id/agent/sessions/:id/verifiedTask token

Marks the session verified with a completed verification (challenge) of the person the task acts for, completed in the last 10 minutes. A verification started with session_id marks its session on its own.

POST/v1/auth/:app_id/agent/sessions/:id/endTask token

Ends the session. Session trust stops applying.

Errors#

Statuserror_codeWhen
409needs_humanThe task acts for nobody
422invalid_methodmethod is not one of the list
422unknown_permissionNo such permission
403outside_taskThe task's actions do not include permission
429too_many_verifications5 verifications this hour for this task
422challenge_invalidOn /verified: the challenge is not a fresh, completed one for this person
404not_foundThe verification or session is not this task's