DoConure

How do I choose how a signer proves it's them?

Set validationMode on that signer. The default, "sign", is the fastest: a mark plus an explicit slide-to-confirm gesture, no code at all. "email" adds a one-time code sent to that signer's own address before their mark counts:

"signers": {
  "A": { "email": "...", "fullName": "...", "validationMode": "email",
         "fields": [ /* ... */ ] }
}

"sms" works the same way as "email" — request a code, submit it — with the code sent by text to the signer's phone. It requires a "phone" field on that signer (free text, any shape). Where the code cannot be delivered by SMS (no gateway configured, or a country the sender is not registered in) the envelope is refused at creation with SMS_VALIDATION_UNAVAILABLE, and nothing is created or sent.

An SMS code is something your organisation buys. We switch it on for you; until then a request that asks for "sms" (or an organisation default of sms) is refused with FEATURE_NOT_ENABLED and details.feature set to smsValidation, nothing is created, and nothing is quietly sent by email instead. If the service is withdrawn after an envelope was sent, its signers still get their code, by email: nothing is bought that your organisation no longer holds.

Each SMS costs two credits, charged to your organisation when the SMS gateway accepts the message: a signer who asks for a new code gets a new message, charged again (at most eight codes per signer). A message that does not leave is not charged. The charge never stops the signer: the code is sent even if your balance has run out, and the next credit you add repays it first. output.credits.used of the envelope includes these charges as they happen. With a plan that has an SMS counter, the code is taken from the plan first, and past it from the credit.

Every outcome an envelope call can produce: Outcomes and error codes. Replacing a signer who confirms by SMS, or a signer passing their own turn on, needs the new person's mobile number: the old number is never kept and the code never goes to it (Replacing a signer). Signature levels (SES/AES/QES) are a separate axis from validation mode — see Signature levels: SES, AES, QES.