跳转到主要内容
POST
curl
Didit 会通过上一次的投递渠道发送相同的验证码来重试电话验证。验证 ID 和有效期保持不变。省略 channel,或传入上一次的投递渠道。若要切换渠道,请使用将电话验证移至下一渠道。 请检查 HTTP 200 响应中的 status。重试成功时返回 pending,并附带发送次数和有效期。若投递被阻止,验证将结束,响应返回 blocked 及 reason。只有您的应用通过发送启动的验证才能重试。托管验证会话中的电话步骤在此处为只读,并返回 404 not_found。 距离上一次发送至少等待 30 秒。首次发送和每次重试都计入三次发送上限。过早重试或超出发送上限时,返回 429。 指定了与上一次不同但允许使用的渠道,或 Didit 无法重复发送该验证码时,返回 409 code_not_resendable。验证码由调用方提供时,返回 409 custom_code_not_resendable。有效窗口已过期时,返回 410 expired;验证已结束时,返回 409 already_final。同一号码的另一次发送正在进行且轮到其执行,而本次发送无法及时获得执行机会时,返回 409 verification_in_progress。若 Didit 无法判断是否有另一次发送正在进行,则返回 503 phone_send_unavailable,且不会发送任何内容,请稍后再试。

授权

x-api-key
string
header
必填

Your application's API key, from Developers -> API keys in the Business Console. The primary key has full access. A named key can be scoped: none, read or write per resource, limited to some workflows or to approved sessions, to a list of IP addresses, and to an expiry date. 401 means the key is wrong, revoked or expired; 403 means no key was sent, the key has no access to this resource or action, or the request came from an address outside its IP list; 404 on a session route means the session is outside the key's workflows or statuses. A key without media access receives image, video and PDF URLs as null, and a key without sessions write receives session links and tokens as null. See https://docs.didit.me/console/api-keys.

请求头

Idempotency-Key
string

Optional retry-safety key you choose for one operation, up to 255 characters (a UUID works). A request repeated with the same key, endpoint, query and body is answered with the first response, same status and same body, and runs and bills nothing a second time. The same key with another endpoint, query or body returns 409 idempotency_key_reused, and while the first request is still running, 409 idempotency_key_in_progress with Retry-After. A failed request (any 4xx or 5xx) is not stored, so you can send it again with the same key. Keys belong to your application, whether you call with an API key or an access token. See Retries and idempotency.

Required string length: 1 - 255

路径参数

verification_id
string<uuid>
必填

The verification.

示例:

"c9b18621-9f8f-4590-a3b4-f8ebea4baa7d"

请求体

application/json

Omit the body to retry on the last delivery channel. If supplied, channel must match that channel.

Optional channel confirmation for a same-window retry.

channel
enum<string>

The last delivery channel. Requesting a different allowed channel returns 409 code_not_resendable.

可用选项:
silent,
sms,
whatsapp,
telegram,
voice,
rcs,
viber,
zalo,
email,
push,
totp,
passkey

响应

Inspect status. A successful send returns pending. A blocked attempt ends the verification and returns blocked with a reason.

A pending retry includes sends, sends_left, expires_at and charged. A blocked retry returns the reason instead.

verification_id
string<uuid>
必填

The same verification.

示例:

"c9b18621-9f8f-4590-a3b4-f8ebea4baa7d"

status
enum<string>
必填

A successful send remains pending. A blocked send ends the verification.

可用选项:
pending,
blocked
示例:

"pending"

channel
enum<string>
必填

The channel this send went by.

可用选项:
silent,
sms,
whatsapp,
telegram,
voice,
rcs,
viber,
zalo,
email,
push,
totp,
passkey
示例:

"sms"

sends
integer

Sends of this code so far, the first one included.

示例:

2

sends_left
integer

Retries left in this window.

示例:

1

expires_at
string<date-time>

Unchanged: a retry keeps the window and the code.

示例:

"2026-11-21T10:05:00Z"

charged
boolean

True when the channel accepts the retry and returns a send ID. Delivery confirmation can arrive later. Check the verification's attempt history for the delivery status and price.

示例:

true

reason
string | null

Returned on a blocked send. May be null when no reason is available.

示例:

"suspicious"

最后修改于 2026年11月24日