A policy says what the wallet has to prove and which credentials count. Every verification uses exactly one. You can start with a built-in preset and create your own when you need something specific.

Built-in presets

Presets work in every project with no setup. They don’t appear in your project’s policy list, but you can use their IDs anywhere a policy ID is accepted.
PresetPolicy IDWhat it checks
KYC_BASICpol_kyc_basic_authbound_v1Name, date of birth and nationality, and that the user is 18 or older
IDENTITY_BASICpol_identity_basic_authbound_v1Name and date of birth
AGE_GATE_18pol_age_over_18_authbound_v1That the user is 18 or older, without sharing their birth date
KYC_BASIC_EUDIpol_kyc_basic_eudi_v1Name and nationality, from an EU PID
IDENTITY_BASIC_EUDIpol_identity_basic_eudi_v1Name and date of birth, from an EU PID
AGE_GATE_18_EUDIpol_age_over_18_eudi_v1That the user is 18 or older. The wallet answers with the EU Proof of Age credential, or an EU PID’s age_over_18. If it has neither, it shares the PID date of birth
PENSIONpol_authbound_pension_v1Name and pension start date, from an Authbound pension credential
The first three accept an Authbound Digital ID, including the test ID you can issue yourself. In code, use the PolicyPresets constants rather than typing IDs:
import { PolicyPresets } from "@authbound/core";

PolicyPresets.KYC_BASIC; // "pol_kyc_basic_authbound_v1"
Resolve preset keys or slugs without hardcoding IDs:
import { getPresetPolicyId } from "@authbound/core";

getPresetPolicyId("kyc_basic"); // "pol_kyc_basic_authbound_v1"
To show presets in your own UI, fetchPresetRegistry("https://sandbox.authbound.io") loads their names and descriptions from /v1/presets.

Create your own policy

Create a policy when no preset asks for exactly what you need. Ask only for what your app needs: every claim you request is shown to the user and returned to you. You can create one on your project’s Policies page in the dashboard, or from your server with @authbound/server 0.4.0 or later:
const policy = await authbound.policies.create({
  name: "Age gate",
  attestationType: "pid",
  ecosystem: "authbound",
  format: "dc+sd-jwt",
  requestedClaims: [{ claim: "age_over_18", values: [true] }],
  idempotencyKey: "policy:age-gate:v1",
});

// Use it like any other policy ID
await authbound.verifications.create({ policyId: policy.id });
Your secret key needs the policies:write scope to create policies, and policies:read to list or fetch them.

Choose what to verify

Set exactly one of these:
FieldUse it for
attestationTypeA standard credential, such as a PID. Also set ecosystem and format.
credentialDefinitionIdA credential you issue yourself with Authbound. See Credential definitions.
vctAny SD-JWT credential, identified by its type.
Custom credential and vct policies support the dc+sd-jwt format.

Choose claims

requestedClaims lists what the wallet must share. Each entry is either a claim name, or a claim with the values it must have:
requestedClaims: [
  "given_name",                             // must be present, any value
  { claim: "age_over_18", values: [true] }, // must be exactly true
]
  • Values must match exactly. Strings, booleans and whole numbers are supported, and nothing is converted: "true" doesn’t match true.
  • Yes/no claims like age_over_18 only accept [true]. Bare age_over_18 and ticket_valid strings also require a positive assertion; a false eligibility value does not pass a presence check.
  • An age check doesn’t need the birth date. Request age_over_18 and the user’s birth date is never shared.
  • Each claim can appear once.

What you get back

The returned policy has a read-only returnAttrs list: the names of the claims that come back in a verified result. They can differ slightly from what you requested, because some claims have a standard name. For example, a requested birthdate comes back as birth_date. EUDI PID nationality results are arrays. Authbound PID nationality stays a scalar string. Do not add exact-value constraints on EUDI PID nationality.

Change a policy

Policies can’t be edited. To change what you ask for, create a new policy and switch your app to its ID, then archive the old one with authbound.policies.archive(id). This keeps every change deliberate. Put the version in the name or idempotency key, for example policy:age-gate:v2, so it’s clear which one is current.