interface · Browser and Node

# AcceptPolicy

What a verifier accepts. Groups are in statement slot order.

`@toip-tools/anon-membership` · [View source](https://github.com/yourbuddyconner/toip-tools/blob/main/packages/anon-membership/src/accept.ts#L9)

Import:

```ts
import { type AcceptPolicy } from "@toip-tools/anon-membership";
```

## Declaration

interface:

```ts
interface AcceptPolicy {
  /** 1 to 4 groups, each with the issuer DID pinned out of band. */
  groups: { group: string; issuer: string }[];
  /** Pinned verification-key hashes. */
  vkHashes: string[];
  /** How many epochs after a root stops being the newest it is still accepted. */
  maxEpochAge: number;
  /** The smallest anonymity set: the sum of the groups' sizes at the roots used. */
  minSize: number;
  schemaId?: Field;
  predicates?: Predicate[];
  /** registeredBy must be today minus this. Default 0. */
  minRegisteredDays?: number;
  /** Nullifiers per member in the scope. Default 1. */
  limit?: number;
  /** Roots fixed in advance (a poll's), hex, per slot. If set, only these are accepted. */
  pinnedRoots?: string[];
  /** How many days `today` may lag the verifier's clock. Default 1. */
  maxDayLag?: number;
}
```

## Properties

**`groups` (required)**

`{ group: string; issuer: string; }[]`

1 to 4 groups, each with the issuer DID pinned out of band.

**`vkHashes` (required)**

`string[]`

Pinned verification-key hashes.

**`maxEpochAge` (required)**

`number`

How many epochs after a root stops being the newest it is still accepted.

**`minSize` (required)**

`number`

The smallest anonymity set: the sum of the groups' sizes at the roots used.

**`schemaId` (optional)**

`bigint | undefined`

**`predicates` (optional)**

`Predicate[] | undefined`

**`minRegisteredDays` (optional)**

`number | undefined`

registeredBy must be today minus this. Default 0.

**`limit` (optional)**

`number | undefined`

Nullifiers per member in the scope. Default 1.

**`pinnedRoots` (optional)**

`string[] | undefined`

Roots fixed in advance (a poll's), hex, per slot. If set, only these are accepted.

**`maxDayLag` (optional)**

`number | undefined`

How many days `today` may lag the verifier's clock. Default 1.

[Usage guide](https://toip.tools/toolkit/anon-membership/#usage) · [Error handling](https://toip.tools/toolkit/anon-membership/#errors) · [All exports](https://toip.tools/toolkit/anon-membership/api/)

---

This is the Markdown version of https://toip.tools/toolkit/anon-membership/api/AcceptPolicy/. An index of the documentation for AI assistants is at https://toip.tools/llms.txt.
