Verification Attempt Lockout

Turn on a safeguard that locks a card after repeated failed verifications, for an hour or for good, and clear the lock with one API call.

For: developers and operations teams

Introduction

The verification attempt lockout is an opt-in safeguard that blocks a card after repeated failed verifications. It counts failures across your whole account and applies on every network.

📘

This is not the HIGHEST lockout

This page covers the attempt lockout, which applies to every verification, with or without a tier. The HIGHEST tier has its own, separate lock for each card (from the two-hold amount check). See HIGHEST Verification. Failures in one never count toward the other.

Enabling it

The lockout is off by default. Turn it on for a subaccount with the failedAttemptLockout flag on verificationPolicy, using the Update Subaccount endpoint:

PATCH /subaccounts/{subaccountId} HTTP/1.1
Authorization: Bearer YOUR_ACCESS_TOKEN
Content-Type: application/json

{
  "verificationPolicy": {
    "failedAttemptLockout": true
  }
}
curl -X PATCH https://api.astrada.co/subaccounts/{subaccountId} \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "verificationPolicy": {
      "failedAttemptLockout": true
    }
  }'
{
  "verificationPolicy": {
    "failedAttemptLockout": true
  }
}
  • Failures are always recorded. The flag only controls enforcement, so the lock protects you as soon as you turn it on, with no warm-up window.
  • Failures are counted for each card across all your subaccounts, whether or not the lock is on where they happened. Turning the lock on for a subaccount decides only whether that subaccount refuses a card that is over the limit.
  • Set it on a subaccount with true or false. A subaccount with no value (null) uses the account's setting, which Astrada can turn on for every subaccount with no value of its own. A subaccount created while the account had a value starts with a copy of it; to have that subaccount follow the account again, set null on it. To turn it off for one subaccount, set false.

How it works

The lockout is keyed to the card within your account, and counts failures across all networks. There are two levels:

  • Temporary lock: 5 failures inside a 60-minute window block the card for 60 minutes, then it clears on its own. The window is fixed: it starts at the first failure and starts again only when a failure arrives 60 minutes or more after that start. It doesn't move forward with each new failure.
  • Permanent lock: 15 failures in total (over any span of time) block the card with no expiry; it stays locked until you clear it.

What counts: any decline from the bank (including a wrong security code, an expired, lost or stolen card, insufficient funds and "contact your bank"), and a 3DS check the bank failed or refused, on any network.

What doesn't: errors on Astrada's or the bank's side ("try again later"), attempts the cardholder abandons or cancels, a card or bank that doesn't support 3DS, and the HIGHEST hold and amount steps.

How the verification attempt lockout locks a card and how the lock clears Every counted failure adds to the card's total; the lock applies only where failedAttemptLockout is in effect for the subaccount, and it is off by default. 5 failures inside a 60-minute window lock the card for 60 minutes, then it clears on its own. 15 failures in total lock it with no expiry. POST /card-verifications/unlock clears either lock and the card's failure count. Every counted failure adds to the card's total The lock applies only where failedAttemptLockout is in effect for the subaccount. It is off by default. Temporary lock 5 failures inside a 60-minute window. Locked for 60 minutes, then it clears on its own. Permanent lock 15 failures in total, over any span of time. No expiry: locked until you clear it. POST /card-verifications/unlock Clears either lock, and the card's failure count, so the 15-failure limit starts again from zero. How the verification attempt lockout locks a card and how the lock clears Every counted failure adds to the card's total; the lock applies only where failedAttemptLockout is in effect for the subaccount, and it is off by default. 5 failures inside a 60-minute window lock the card for 60 minutes, then it clears on its own. 15 failures in total lock it with no expiry. POST /card-verifications/unlock clears either lock and the card's failure count. Every counted failure adds to the card's total The lock applies only where failedAttemptLockout is in effect for the subaccount. It is off by default. Temporary lock 5 failures inside a 60-minute window. Locked for 60 minutes, then it clears on its own. Permanent lock 15 failures in total, over any span of time. No expiry: locked until you clear it. After either lock POST /card-verifications/unlock Clears either lock, and the card's failure count, so the 15-failure limit starts again from zero.

Error codes

When a locked card tries to verify, POST /card-verifications/3ds returns 400 before any check runs, with one of two codes:

  • verification.attempts_locked: the temporary lock. It carries metadata.lockedUntil, when it clears.
  • verification.attempts_locked_permanent: the permanent lock. No lockedUntil.

Both have category: verification-locked and retryable: false. What to do for each: Error States & Remediation.

What the cardholder sees

SDK v2 shows both lockout screens for you; there are no screens to build. Each lock shows its own screen, so the cardholder knows whether to wait or to ask for help.

  • Temporary: "Verification temporarily blocked", with "For your security, this card is temporarily blocked after too many failed verification attempts. Please wait a little while before trying again." and Done. The lock clears on its own at metadata.lockedUntil.
  • Permanent: "This card can't be checked any more", with "Ask" followed by your companyName, and Done. Clear it with POST /card-verifications/unlock below.

Unlocking a card

Clear a card's lock (temporary or permanent) with the Unlock Card Verification endpoint:

POST /card-verifications/unlock HTTP/1.1
Authorization: Bearer YOUR_ACCESS_TOKEN
Content-Type: application/json

{
  "cardId": "00cdba2d-01f0-46bb-b34a-c76d9699e991"
}
curl -X POST https://api.astrada.co/card-verifications/unlock \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "cardId": "00cdba2d-01f0-46bb-b34a-c76d9699e991"
  }'
{
  "cardId": "00cdba2d-01f0-46bb-b34a-c76d9699e991"
}

Returns 200 with { "unlocked": true, "cleared": true }. cleared is true when the card had failed attempts on record, whether or not they had locked it, and false when it had none. It is idempotent: unlocking a card with nothing on record succeeds and clears nothing.

Unlocking also clears the card's failure count, so the 15-failure limit starts again from zero.

📘

Token scope

Unlocking requires subaccounts:write (the same scope used to manage a subaccount's policy), not card-verifications:write (which creates verifications). A token without subaccounts:write is rejected with 403.

  • The endpoint clears both the temporary and the permanent lock. (The temporary lock also clears on its own once the 60-minute window passes.)
  • It doesn't touch the HIGHEST lock. See the note at the top of this page.

Did this page help you?