@sekyro/node 1.0.0-rc.17 → 1.0.0-rc.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,33 @@
1
1
  # @sekyro/node
2
2
 
3
+ ## 1.0.0-rc.19
4
+
5
+ ### Major Changes
6
+
7
+ - 62987ea: Breaking: `person.suspicious_activity` is no longer sent. `PersonSuspiciousActivityEventData` and the `WebhookEventDataMap` entry are removed. A person rejected on a device they never used raises the `known_person_new_device` signal: subscribe to `signal.raised`.
8
+
9
+ ## 1.0.0-rc.18
10
+
11
+ ### Major Changes
12
+
13
+ - db1d4d4: Breaking: the Sandbox speaks the Live contract, and the test tools live under `sekyro.test`.
14
+
15
+ Removed:
16
+
17
+ - `sekyro.sessions.simulate`: call `sekyro.test.sessions.simulate(id, input, opts)`.
18
+ - The `simulated` value of `CreatedSession.delivery.status` and `SessionLinkDelivery.delivery.status`: the status uses the Live values, and a Sandbox send that is not to an enrolled tester carries `simulated: true` instead.
19
+
20
+ Changed:
21
+
22
+ - `SimulateSessionInput` reaches every outcome of the session model: `status`, then optional `reason`, `closedBy`, `reasonCode`, `step` and `then` (`retake`, `decide:approve`, `decide:reject`, `binding_retake`). A pair the model cannot produce answers `422 simulate_pair_invalid`; a session a tester runs real checks in answers `409 session_bound`.
23
+
24
+ Added:
25
+
26
+ - `sekyro.webhooks.test({ event })`: sends a realistic sample of any event to the endpoints of the key's environment. Types `WebhooksApi`, `WebhookTestInput`, `WebhookTestResult`, `SekyroTestApi`, `SessionTestApi`.
27
+ - `sekyro.readiness()`: what Live would change for your integration, from the key environment's sessions of the last 30 days (`GET /readiness`), so CI can assert readiness. Types `ReadinessReport`, `ReadinessProtection`.
28
+
29
+ The connector snippets read `env` from your configuration (`SEKYRO_ENV`) instead of a literal.
30
+
3
31
  ## 1.0.0-rc.17
4
32
 
5
33
  ### Major Changes
package/README.md CHANGED
@@ -26,6 +26,11 @@ Next.js and Express, billing). The hosted-flow path is in the
26
26
  npm install @sekyro/node@next
27
27
  ```
28
28
 
29
+ Samples: [`node-express`](https://github.com/IBTIKAR-Technologies/sekyro-examples/tree/main/node-express) (create a session, receive and
30
+ verify webhooks, finish a Sandbox session in development) and
31
+ [`nextjs-app-router`](https://github.com/IBTIKAR-Technologies/sekyro-examples/tree/main/nextjs-app-router) (Server Action and webhook route
32
+ handler).
33
+
29
34
  The SDK is licensed under the
30
35
  [Sekyro AI SDK License](https://sekyro.ai/legal/sdk-license).
31
36
 
@@ -92,8 +97,8 @@ A session is open while its status is `created`, `in_progress` or
92
97
  | `rejected` | a check decided against the person, or a reviewer did |
93
98
  | `inconclusive` | no verdict could be reached: the model was unsure, the captures stayed unreadable, or a review was not decided by its deadline |
94
99
  | `unavailable` | a check could not run |
95
- | `abandoned` | the person left before a result |
96
- | `not_opened` | nobody opened the link before it expired |
100
+ | `abandoned` | the person started the verification but the session expired before a result |
101
+ | `not_opened` | the link was sent but the session expired before it was opened |
97
102
  | `policy` | a flow rule stopped the session (location, anonymizer, device, eligibility, your blocks) |
98
103
  | `cancelled` | you cancelled the session |
99
104
  | `superseded` | a newer session of the same person took its review over (`supersededBy` names it) |
@@ -197,30 +202,58 @@ for await (const s of sekyro.sessions.iterate({ externalRef: userId, status: "ve
197
202
  ### Test in the Sandbox
198
203
 
199
204
  A `sk_test_…` key runs on the same API as a `sk_live_…` key; the key chooses the
200
- environment. `sekyro.me()` tells you which key you hold, and
201
- `sekyro.sessions.simulate()` finishes a simulated session in one call, for tests
202
- and CI. It runs the real engine, so the webhooks, the result token and the
203
- dashboard behave as for a session driven by a person. It is never billed.
205
+ environment, and your production code runs unchanged with either. `sekyro.me()`
206
+ tells you which key you hold. The tools for tests and CI live under
207
+ `sekyro.test`, so they stay out of your production path:
208
+ `sekyro.test.sessions.simulate()` ends a simulated session with the outcome you
209
+ name, in one call. It runs the real engine (expiry, cancel, supersession,
210
+ reviewer decision), so the webhooks, the result token and the dashboard behave
211
+ as for a session driven by a person. It is never billed.
204
212
 
205
213
  ```ts
206
214
  const me = await sekyro.me();
207
215
  // { env: "sandbox", keyPrefix, scopes, app: { id, slug, name }, org: { name } }
208
216
 
209
217
  const { id } = await sekyro.sessions.create({ person: { externalRef: "<your user id>" } });
210
- const session = await sekyro.sessions.simulate(
218
+ const session = await sekyro.test.sessions.simulate(
211
219
  id,
212
- { status: "not_verified", reasonCode: "spoof_detected" }, // or { status: "verified" }, { status: "review_pending" }
220
+ { status: "not_verified", reason: "rejected", reasonCode: "spoof_detected" },
213
221
  { idempotencyKey: "<your CI run id>" },
214
222
  );
223
+ // Other outcomes: { status: "verified" }, { status: "not_verified", reason: "abandoned" },
224
+ // { status: "review_pending", then: "decide:approve" }, { status: "review_pending", then: "retake" }
225
+ ```
226
+
227
+ `status` is required. `reason` and `closedBy` default to the pair the engine
228
+ produces for the path; `reasonCode` and `step` name the step that decides it;
229
+ `then` runs a follow-up: after `review_pending`, `decide:approve`,
230
+ `decide:reject` or `retake`; with `verified`, `binding_retake`. Errors:
231
+ `400 sandbox_only` (a Live key), `409 session_bound` (a tester runs real
232
+ checks in it), `409 session_already_final`,
233
+ `422 simulate_pair_invalid` (`details.validPairs` lists the valid pairs),
234
+ `422 simulate_status_unreachable` (`details.issues` says why) and
235
+ `422 simulate_reason_invalid`.
236
+
237
+ `sekyro.webhooks.test({ event })` sends a realistic sample of any event to the
238
+ endpoints of the key's environment, signed like a real delivery:
239
+
240
+ ```ts
241
+ await sekyro.webhooks.test({ event: "session.verified" }); // { dispatched, endpoints }
242
+ ```
243
+
244
+ `sekyro.readiness()` reports what Live would change for your integration, from
245
+ the last 30 days of the key environment's sessions: client protections Live
246
+ would enforce, webhook endpoints per environment and failed deliveries, registry
247
+ access per flow, Live rate limits against your peak, and the SDK versions your
248
+ sessions used. Assert on it in CI before you go live:
249
+
250
+ ```ts
251
+ const report = await sekyro.readiness();
252
+ if (report.webhooks.endpoints.live === 0) throw new Error("no Live webhook endpoint");
215
253
  ```
216
254
 
217
- `reasonCode` is optional and goes only with `not_verified`: the code a step on
218
- the flow's path fails with. Errors: `400 sandbox_only` (a Live key),
219
- `409 session_not_simulated` (bound to a tester), `409 session_already_final`,
220
- `422 simulate_status_unreachable` (the flow cannot reach this status;
221
- `details.issues` says why) and `422 simulate_reason_invalid` (no step on the
222
- path can fail with that code).
223
- See the [Sandbox guide](https://docs.sekyro.ai/en/getting-started/sandbox).
255
+ See the [Sandbox guide](https://docs.sekyro.ai/en/getting-started/sandbox) and
256
+ [Test identities and outcomes](https://docs.sekyro.ai/en/getting-started/test-identities).
224
257
 
225
258
  ### Identity data and media
226
259
 
@@ -321,8 +354,7 @@ Partner-supplied identity data is not billed: the Partner-supplied identity step
321
354
  records no usage event (other steps, such as the face match, bill as usual).
322
355
 
323
356
  The step reasons and codes about the number are `registry_record_not_found`,
324
- `id_number_invalid`, `id_number_locked`, `document_id_number_mismatch` and
325
- `sandbox_id_number_not_seeded`. See
357
+ `id_number_invalid`, `id_number_locked` and `document_id_number_mismatch`. See
326
358
  [Person data](https://docs.sekyro.ai/en/guides/person-data).
327
359
 
328
360
  ### Errors
@@ -611,7 +643,7 @@ import { createConnector } from "@sekyro/node/connect";
611
643
  const connector = createConnector({
612
644
  sekyro: new Sekyro({ apiKey: process.env.SEKYRO_API_KEY! }),
613
645
  appId: process.env.SEKYRO_APP_ID!, // or an array of app ids
614
- env: "live",
646
+ env: process.env.SEKYRO_ENV as "sandbox" | "live", // "sandbox" with an sk_test_ key, "live" with an sk_live_ key
615
647
  webhookSecret: process.env.SEKYRO_WEBHOOK_SECRET!,
616
648
  provider, // from a provider package
617
649
  onUserDeleted: "ignore", // 'ignore' | 'revoke' | 'delete'
@@ -18,9 +18,10 @@ type SessionStatus = "created" | "in_progress" | "review_pending" | "verified" |
18
18
  * Why a `not_verified` session was not verified: `rejected` (a check decided against the
19
19
  * person, or a reviewer did), `inconclusive` (no verdict could be reached: the model was
20
20
  * unsure, the captures stayed unreadable, or a review was not decided by its deadline),
21
- * `unavailable` (the check could not run), `abandoned` (the person left before a result),
22
- * `not_opened` (nobody opened the link), `policy` (a flow rule stopped it), `cancelled` (you
23
- * cancelled it) or `superseded` (a newer session of the same person took its review over).
21
+ * `unavailable` (the check could not run), `abandoned` (the person started the verification but
22
+ * the session expired before a result), `not_opened` (the link was sent but the session expired
23
+ * before it was opened), `policy` (a flow rule stopped it), `cancelled` (you cancelled it) or
24
+ * `superseded` (a newer session of the same person took its review over).
24
25
  * @public
25
26
  */
26
27
  type SessionReason = "rejected" | "inconclusive" | "unavailable" | "abandoned" | "not_opened" | "policy" | "cancelled" | "superseded";
@@ -1030,21 +1031,140 @@ interface SessionFlowRef {
1030
1031
  version: number;
1031
1032
  }
1032
1033
  /**
1033
- * Input of {@link SessionsApi.simulate}.
1034
+ * Input of {@link SessionTestApi.simulate}: where a simulated Sandbox session
1035
+ * ends. Each outcome is reached through the real engine (expiry, cancel,
1036
+ * supersession, reviewer decision), never by writing a status, so the
1037
+ * webhooks, the result token and the dashboard rows are the real ones.
1034
1038
  * @public
1035
1039
  */
1036
1040
  interface SimulateSessionInput {
1041
+ /** Where the session ends. */
1042
+ status: "verified" | "not_verified" | "review_pending";
1037
1043
  /**
1038
- * Where the session ends: `verified`, `not_verified` or `review_pending`. The flow must be able
1039
- * to reach it, else `422 simulate_status_unreachable`.
1044
+ * `not_verified` only: why. Defaults to the reason the engine gives for the
1045
+ * path. A pair the outcome model cannot produce answers
1046
+ * `422 simulate_pair_invalid` with the valid pairs in `details.validPairs`.
1040
1047
  */
1041
- status: "verified" | "not_verified" | "review_pending";
1048
+ reason?: SessionReason;
1049
+ /** Who closes the session. Defaults to the value the engine gives for the path. */
1050
+ closedBy?: ClosedBy;
1042
1051
  /**
1043
- * Only with `not_verified`: the code a step on the path fails with, e.g. `spoof_detected`
1044
- * (the session's {@link Session.reasonCode}). No step on the path can fail with it:
1045
- * `422 simulate_reason_invalid`.
1052
+ * `not_verified` closed `automatic` only: the detailed code a step on the
1053
+ * path ends with, e.g. `spoof_detected` ({@link Session.reasonCode}).
1046
1054
  */
1047
1055
  reasonCode?: string;
1056
+ /** The service of the step that decides the outcome, e.g. `liveness`. */
1057
+ step?: ServiceId;
1058
+ /**
1059
+ * What happens once `status` is reached. After `review_pending`:
1060
+ * `decide:approve` and `decide:reject` record a reviewer decision, `retake`
1061
+ * asks the person for a retake (the session goes back to `in_progress` and
1062
+ * `session.retake_requested` is sent). With `verified`: `binding_retake`
1063
+ * stops at the face match whose probe does not bind to the liveness clip,
1064
+ * and the session waits for the person to retake their face.
1065
+ */
1066
+ then?: "retake" | "decide:approve" | "decide:reject" | "binding_retake";
1067
+ }
1068
+ /**
1069
+ * One client protection in a {@link ReadinessReport}: how often it tripped, and what Live's
1070
+ * posture would do.
1071
+ * @public
1072
+ */
1073
+ interface ReadinessProtection {
1074
+ /** The organization's Live posture. */
1075
+ livePosture: "off" | "signal" | "enforce";
1076
+ /** Sessions of the window whose check carried the failing signal. */
1077
+ sessions: number;
1078
+ /** Of those, how many Live would have stopped (the posture is `enforce`). */
1079
+ wouldStopInLive: number;
1080
+ }
1081
+ /**
1082
+ * Result of {@link Sekyro.readiness}: what Live would change for your integration, from the key
1083
+ * environment's sessions of the last 30 days. Counts and ids only, never a person value.
1084
+ * @public
1085
+ */
1086
+ interface ReadinessReport {
1087
+ env: "sandbox" | "live";
1088
+ /** The window counted (ISO 8601). */
1089
+ window: {
1090
+ from: string;
1091
+ to: string;
1092
+ days: number;
1093
+ };
1094
+ /** Sessions created in the window that were counted, newest first; `capped` when older ones were left out. */
1095
+ sessions: {
1096
+ counted: number;
1097
+ capped: boolean;
1098
+ };
1099
+ clientAttestation: {
1100
+ /** Native attestation (App Attest, Play Integrity) that did not pass. */
1101
+ deviceAttestation: ReadinessProtection;
1102
+ /** Uploads without a valid live-camera capture proof. */
1103
+ captureOrigin: ReadinessProtection;
1104
+ /** Automation and emulator signals: recorded in both environments, they never stop a session. */
1105
+ automation: {
1106
+ webdriver: number;
1107
+ headless: number;
1108
+ emulator: number;
1109
+ };
1110
+ };
1111
+ webhooks: {
1112
+ /** Enabled endpoints per environment. */
1113
+ endpoints: {
1114
+ sandbox: number;
1115
+ live: number;
1116
+ };
1117
+ /** Deliveries of this environment that failed or died in the window. */
1118
+ failedDeliveries: number;
1119
+ };
1120
+ registries: {
1121
+ /** The active flows with a registry step, and whether Live has registry access for them. */
1122
+ flows: Array<{
1123
+ flowId: string;
1124
+ name: string;
1125
+ liveAccess: boolean;
1126
+ }>;
1127
+ };
1128
+ limits: Array<{
1129
+ id: "api_requests" | "verifications_started";
1130
+ /** The value in force in Live, per minute. */
1131
+ live: number;
1132
+ /** The busiest minute of this environment in the last 24 hours (`null`: nothing counted). */
1133
+ peakPerMinute: number | null;
1134
+ /** Requests of this environment the limit refused in the last 7 days. */
1135
+ rejected7d: number;
1136
+ }>;
1137
+ /** The SDK versions the sessions used. */
1138
+ sdks: Array<{
1139
+ sdk: string;
1140
+ version: string;
1141
+ /** The lowest version Sekyro AI recommends for this platform (`null`: none). */
1142
+ recommended: string | null;
1143
+ outdated: boolean;
1144
+ }>;
1145
+ /** Whether your server verified result tokens. Not known yet: always `null`. */
1146
+ resultTokenVerification: null;
1147
+ }
1148
+ /**
1149
+ * Input of {@link WebhooksApi.test}.
1150
+ * @public
1151
+ */
1152
+ interface WebhookTestInput {
1153
+ /**
1154
+ * The event to send as a realistic sample payload, with fresh ids and
1155
+ * timestamps. Defaults to `webhook.test`.
1156
+ */
1157
+ event?: WebhookEventType;
1158
+ }
1159
+ /**
1160
+ * Result of {@link WebhooksApi.test}.
1161
+ * @public
1162
+ */
1163
+ interface WebhookTestResult {
1164
+ /** `false` when no enabled endpoint of the key's environment subscribes to the event. */
1165
+ dispatched: boolean;
1166
+ /** The endpoints the event was queued for. */
1167
+ endpoints: number;
1048
1168
  }
1049
1169
  /**
1050
1170
  * The API key in use, from {@link Sekyro.me}. Never carries the secret.
@@ -1179,10 +1299,13 @@ interface CreatedSession {
1179
1299
  subjectUse?: "reference" | "prefill";
1180
1300
  /**
1181
1301
  * With {@link CreateSessionInput.deliver} only: the send of the hosted link.
1182
- * `failed` never fails the create; `simulated` on a simulated Sandbox session.
1302
+ * `failed` never fails the create. `simulated: true` in the Sandbox when the
1303
+ * destination is not an enrolled tester's: the destination passed the same
1304
+ * checks as in Live and nothing is sent.
1183
1305
  */
1184
1306
  delivery?: {
1185
- status: "queued" | "failed" | "simulated";
1307
+ status: "queued" | "failed";
1308
+ simulated?: true;
1186
1309
  };
1187
1310
  }
1188
1311
  /**
@@ -2291,8 +2414,9 @@ type ExtendLinkInput = {
2291
2414
  interface SessionLinkDelivery {
2292
2415
  delivery: {
2293
2416
  channel: "sms" | "whatsapp" | "email";
2294
- /** `simulated` in the Sandbox: nothing is sent. */
2295
- status: "queued" | "sent" | "failed" | "simulated";
2417
+ status: "queued" | "sent" | "failed";
2418
+ /** `true` in the Sandbox when the destination is not an enrolled tester's: nothing is sent. */
2419
+ simulated?: true;
2296
2420
  };
2297
2421
  }
2298
2422
  /** Result of {@link SessionsApi.extendLink}. @public */
@@ -2300,18 +2424,6 @@ interface SessionLinkExpiry {
2300
2424
  /** ISO 8601: the new expiry of the link and its session. */
2301
2425
  expiresAt: string;
2302
2426
  }
2303
- /**
2304
- * `data` of `person.suspicious_activity`: a device already linked to ANOTHER
2305
- * person was used for a session of this person. `count` is the person's running
2306
- * total of such events. Ids only.
2307
- * @public
2308
- */
2309
- interface PersonSuspiciousActivityEventData {
2310
- /** The person (`per_...`). */
2311
- personId: string;
2312
- sessionId: string;
2313
- count: number;
2314
- }
2315
2427
  /**
2316
2428
  * `usage.threshold_reached`: a usage, credit or spend threshold of the organization's
2317
2429
  * plan was reached (sent once per threshold and period). `kind` is `tier` for a monthly
@@ -2364,7 +2476,6 @@ interface WebhookEventDataMap {
2364
2476
  "signal.escalated": SignalEventData;
2365
2477
  "person.enrolled": PersonEnrolledEventData;
2366
2478
  "person.updated": PersonUpdatedEventData;
2367
- "person.suspicious_activity": PersonSuspiciousActivityEventData;
2368
2479
  "person.deleted": PersonDeletedEventData;
2369
2480
  "aml.match_flagged": AmlMatchFlaggedEventData;
2370
2481
  "payment.received": Record<string, unknown>;
@@ -2557,18 +2668,6 @@ declare class SessionsApi {
2557
2668
  * (it has no token). Needs the `sessions:read` scope.
2558
2669
  */
2559
2670
  resultToken(id: string): Promise<ResultTokenResponse>;
2560
- /**
2561
- * `POST /sessions/:id/simulate`: finishes a simulated Sandbox session in one
2562
- * call, for tests and CI. It runs every step of the flow through the real
2563
- * engine, so the status, the webhooks, the result token and the dashboard
2564
- * behave as for a session driven by a person. Never billed. Returns the
2565
- * finished session; pass an `idempotencyKey` to make a retry safe. Errors:
2566
- * `400 sandbox_only` (Live key), `409 session_not_simulated` (bound to a
2567
- * tester), `409 session_already_final`, `422 simulate_status_unreachable`
2568
- * (`details.issues` says why), `422 simulate_reason_invalid`. Needs the
2569
- * `sessions:create` scope.
2570
- */
2571
- simulate(id: string, input: SimulateSessionInput, opts?: RequestOptions): Promise<Session>;
2572
2671
  }
2573
2672
  /**
2574
2673
  * `sekyro.flows`: the flows of the API key's app.
@@ -2761,6 +2860,59 @@ declare class DevicesApi {
2761
2860
  shared: boolean;
2762
2861
  }, opts?: RequestOptions): Promise<Device>;
2763
2862
  }
2863
+ /**
2864
+ * `sekyro.webhooks`: your webhook endpoints. Exported as a TYPE only: obtained
2865
+ * through {@link Sekyro.webhooks}.
2866
+ * @public
2867
+ */
2868
+ declare class WebhooksApi {
2869
+ private readonly t;
2870
+ /** @internal */
2871
+ constructor(t: {
2872
+ call<T>(method: HttpMethod, path: string, body?: unknown, idempotencyKey?: string): Promise<T>;
2873
+ });
2874
+ /**
2875
+ * `POST /webhooks/test`: sends a realistic sample of `event` (default
2876
+ * `webhook.test`) to the endpoints of the key's environment that subscribe
2877
+ * to it, signed like any delivery. Works with Sandbox and Live keys. Needs
2878
+ * the `webhooks:test` scope.
2879
+ */
2880
+ test(input?: WebhookTestInput): Promise<WebhookTestResult>;
2881
+ }
2882
+ /**
2883
+ * `sekyro.test.sessions`: test tools for simulated Sandbox sessions. Keep them
2884
+ * out of your production code path: a Live key is refused. Exported as a TYPE
2885
+ * only: obtained through {@link SekyroTestApi.sessions}.
2886
+ * @public
2887
+ */
2888
+ declare class SessionTestApi {
2889
+ private readonly t;
2890
+ /** @internal */
2891
+ constructor(t: {
2892
+ call<T>(method: HttpMethod, path: string, body?: unknown, idempotencyKey?: string): Promise<T>;
2893
+ });
2894
+ /**
2895
+ * `POST /sessions/:id/simulate`: ends a simulated Sandbox session with the
2896
+ * outcome you name, through the real engine, so the webhooks, the result
2897
+ * token and the dashboard behave as for a session driven by a person. Never
2898
+ * billed. Returns the session; pass an `idempotencyKey` to make a retry
2899
+ * safe. Errors: `400 sandbox_only` (a Live key), `409 session_bound` (a
2900
+ * tester runs real checks in it), `409 session_already_final`,
2901
+ * `422 simulate_pair_invalid` (`details.validPairs` lists the valid pairs),
2902
+ * `422 simulate_status_unreachable` (`details.issues` says why) and
2903
+ * `422 simulate_reason_invalid`. Needs the `sessions:create` scope.
2904
+ */
2905
+ simulate(id: string, input: SimulateSessionInput, opts?: RequestOptions): Promise<Session>;
2906
+ }
2907
+ /**
2908
+ * `sekyro.test`: tools for tests and CI in the Sandbox. Exported as a TYPE only.
2909
+ * @public
2910
+ */
2911
+ declare class SekyroTestApi {
2912
+ readonly sessions: SessionTestApi;
2913
+ /** @internal */
2914
+ constructor(t: ConstructorParameters<typeof SessionTestApi>[0]);
2915
+ }
2764
2916
  /**
2765
2917
  * Sekyro AI partner API client. Server-side only: it carries your API key.
2766
2918
  *
@@ -2783,6 +2935,9 @@ declare class Sekyro {
2783
2935
  readonly signals: SignalsApi;
2784
2936
  readonly devices: DevicesApi;
2785
2937
  readonly flows: FlowsApi;
2938
+ readonly webhooks: WebhooksApi;
2939
+ /** Test tools for the Sandbox: {@link SekyroTestApi}. */
2940
+ readonly test: SekyroTestApi;
2786
2941
  constructor(opts: SekyroOptions);
2787
2942
  /**
2788
2943
  * `GET /me`: which key this is. Tells a Sandbox key from a Live one, and
@@ -2790,6 +2945,14 @@ declare class Sekyro {
2790
2945
  * never returns the secret. An invalid key answers `401 unauthorized`.
2791
2946
  */
2792
2947
  me(): Promise<ApiKeyIdentity>;
2948
+ /**
2949
+ * `GET /readiness`: what Live would change for your integration, from the
2950
+ * key environment's sessions of the last 30 days (counts and ids only). With
2951
+ * a Sandbox key it shows what Live would have stopped, so CI can assert
2952
+ * readiness before go-live; with a Live key it reports on Live. Needs the
2953
+ * `sessions:read` scope.
2954
+ */
2955
+ readiness(): Promise<ReadinessReport>;
2793
2956
  }
2794
2957
 
2795
- export { type FlowSummary as $, type AgeMethod as A, type Block as B, type CreatedSession as C, type ConnectorIdentity as D, type CreateBlockInput as E, type FetchLike as F, type CreateSessionInput as G, DEFAULT_BASE_URL as H, DEFAULT_TIMEOUT_MS as I, type DecisionReason as J, type DeepPartial as K, type Locale as L, type DeletedPerson as M, type DeliverOptions as N, type Device as O, DevicesApi as P, type DocumentSubstitutionSettings as Q, type ReviewReason as R, type SessionReason as S, type EidResult as T, type EligibilityReason as U, type VerificationLevel as V, type WebhookEventType as W, type ExtendLinkInput as X, type FlowOverridableSettings as Y, type FlowOverrides as Z, type FlowServiceSettings as _, Sekyro as a, type SessionFlowRef as a$, FlowsApi as a0, type IdNumberReason as a1, type Identity as a2, type IdentityBirthPlace as a3, type IdentityDocument as a4, type IdentityIdNumber as a5, type IdentityMethod as a6, type IdentityName as a7, type IdentityScalarKey as a8, type IdentitySource as a9, type PersonSuspiciousActivityEventData as aA, type PersonUpdatedEventData as aB, type PortraitReportEntry as aC, type PriorReviewReason as aD, type ProbeBindingReason as aE, type ProbeQuality as aF, type ProfileDocumentType as aG, type RequestOptions as aH, type ResultTokenResponse as aI, type ReviewOutcomeReason as aJ, type RevokePersonInput as aK, type ScreenPersonInput as aL, type Screening as aM, type ScreeningHit as aN, type ScreeningHitSummary as aO, type ScreeningList as aP, type ScreeningStatus as aQ, type ScreeningTrigger as aR, type ScreeningUnavailableReason as aS, type SekyroOptions as aT, type Session as aU, type SessionClosedEventDataBase as aV, type SessionDecidingStep as aW, type SessionDevice as aX, type SessionEventDataBase as aY, type SessionEventStep as aZ, type SessionFailureReason as a_, type IdentitySources as aa, type LevelTarget as ab, type LiftBlockInput as ac, type ListBlocksQuery as ad, type ListPeopleQuery as ae, type ListScreeningsQuery as af, type ListSessionsQuery as ag, type ListSignalsQuery as ah, type MatchReason as ai, type MediaBytes as aj, type MediaBytesOptions as ak, type MediaItem as al, type MediaKind as am, type MediaList as an, type NameForm as ao, type Page as ap, PeopleApi as aq, type Person as ar, type PersonBirthPlaceInput as as, type PersonDeletedEventData as at, type PersonDocumentInput as au, type PersonEnrolledEventData as av, type PersonRef as aw, type PersonSession as ax, type PersonSessionInput as ay, type PersonSessionTarget as az, type ServiceId as b, type SessionHandoff as b0, type SessionHandoffDevice as b1, type SessionLifecycleEventData as b2, type SessionLinkDelivery as b3, type SessionLinkExpiry as b4, type SessionLinkInput as b5, type SessionNetwork as b6, type SessionNetworkEvent as b7, type SessionNotVerifiedEventData as b8, type SessionRetakeRequestedEventData as b9, type SubjectReuseTarget as bA, type SubjectStatus as bB, type UpdateSignalInput as bC, type UsageThresholdReachedEventData as bD, type VerifiedContacts as bE, type WebhookEnvelopeOf as bF, type WebhookEventDataMap as bG, type SessionReviewPendingEventData as ba, type SessionScreening as bb, type SessionStatus as bc, type SessionStep as bd, type SessionStepAttempts as be, type SessionStepBand as bf, type SessionStepDecision as bg, type SessionStepDocument as bh, type SessionStepPortrait as bi, type SessionVerifiedEventData as bj, SessionsApi as bk, type Signal as bl, type SignalEventData as bm, type SignalEvidence as bn, type SignalGrade as bo, type SignalKeyKind as bp, type SignalKind as bq, type SignalSeverity as br, type SignalStatus as bs, SignalsApi as bt, type SimulateSessionInput as bu, type StepResult as bv, type SubjectAssurance as bw, type SubjectIdNumber as bx, type SubjectName as by, type SubjectReferenceSource as bz, type SessionPersonInput as c, type WebhookEnvelope as d, type SekyroEnvironment as e, type VerificationAssurance as f, type VerificationUnit as g, type SubjectReuseMode as h, type ResultCheckProofs as i, type SessionSignal as j, type FailureIdentification as k, type AgeResult as l, type AmlMatchFlaggedEventData as m, type ApiKeyIdentity as n, type BlockCheck as o, type BlockCheckInput as p, type BlockDuration as q, type BlockIdNumber as r, type BlockKind as s, type BlockMatch as t, type BlockReason as u, BlocksApi as v, type CameraUnavailableCause as w, type CheckState as x, type CheckType as y, type ClosedBy as z };
2958
+ export { type FlowSummary as $, type AgeMethod as A, type Block as B, type CreatedSession as C, type ConnectorIdentity as D, type CreateBlockInput as E, type FetchLike as F, type CreateSessionInput as G, DEFAULT_BASE_URL as H, DEFAULT_TIMEOUT_MS as I, type DecisionReason as J, type DeepPartial as K, type Locale as L, type DeletedPerson as M, type DeliverOptions as N, type Device as O, DevicesApi as P, type DocumentSubstitutionSettings as Q, type ReviewReason as R, type SessionReason as S, type EidResult as T, type EligibilityReason as U, type VerificationLevel as V, type WebhookEventType as W, type ExtendLinkInput as X, type FlowOverridableSettings as Y, type FlowOverrides as Z, type FlowServiceSettings as _, Sekyro as a, type SessionEventStep as a$, FlowsApi as a0, type IdNumberReason as a1, type Identity as a2, type IdentityBirthPlace as a3, type IdentityDocument as a4, type IdentityIdNumber as a5, type IdentityMethod as a6, type IdentityName as a7, type IdentityScalarKey as a8, type IdentitySource as a9, type PersonUpdatedEventData as aA, type PortraitReportEntry as aB, type PriorReviewReason as aC, type ProbeBindingReason as aD, type ProbeQuality as aE, type ProfileDocumentType as aF, type ReadinessProtection as aG, type ReadinessReport as aH, type RequestOptions as aI, type ResultTokenResponse as aJ, type ReviewOutcomeReason as aK, type RevokePersonInput as aL, type ScreenPersonInput as aM, type Screening as aN, type ScreeningHit as aO, type ScreeningHitSummary as aP, type ScreeningList as aQ, type ScreeningStatus as aR, type ScreeningTrigger as aS, type ScreeningUnavailableReason as aT, type SekyroOptions as aU, SekyroTestApi as aV, type Session as aW, type SessionClosedEventDataBase as aX, type SessionDecidingStep as aY, type SessionDevice as aZ, type SessionEventDataBase as a_, type IdentitySources as aa, type LevelTarget as ab, type LiftBlockInput as ac, type ListBlocksQuery as ad, type ListPeopleQuery as ae, type ListScreeningsQuery as af, type ListSessionsQuery as ag, type ListSignalsQuery as ah, type MatchReason as ai, type MediaBytes as aj, type MediaBytesOptions as ak, type MediaItem as al, type MediaKind as am, type MediaList as an, type NameForm as ao, type Page as ap, PeopleApi as aq, type Person as ar, type PersonBirthPlaceInput as as, type PersonDeletedEventData as at, type PersonDocumentInput as au, type PersonEnrolledEventData as av, type PersonRef as aw, type PersonSession as ax, type PersonSessionInput as ay, type PersonSessionTarget as az, type ServiceId as b, type SessionFailureReason as b0, type SessionFlowRef as b1, type SessionHandoff as b2, type SessionHandoffDevice as b3, type SessionLifecycleEventData as b4, type SessionLinkDelivery as b5, type SessionLinkExpiry as b6, type SessionLinkInput as b7, type SessionNetwork as b8, type SessionNetworkEvent as b9, type SubjectIdNumber as bA, type SubjectName as bB, type SubjectReferenceSource as bC, type SubjectReuseTarget as bD, type SubjectStatus as bE, type UpdateSignalInput as bF, type UsageThresholdReachedEventData as bG, type VerifiedContacts as bH, type WebhookEnvelopeOf as bI, type WebhookEventDataMap as bJ, type WebhookTestInput as bK, type WebhookTestResult as bL, WebhooksApi as bM, type SessionNotVerifiedEventData as ba, type SessionRetakeRequestedEventData as bb, type SessionReviewPendingEventData as bc, type SessionScreening as bd, type SessionStatus as be, type SessionStep as bf, type SessionStepAttempts as bg, type SessionStepBand as bh, type SessionStepDecision as bi, type SessionStepDocument as bj, type SessionStepPortrait as bk, SessionTestApi as bl, type SessionVerifiedEventData as bm, SessionsApi as bn, type Signal as bo, type SignalEventData as bp, type SignalEvidence as bq, type SignalGrade as br, type SignalKeyKind as bs, type SignalKind as bt, type SignalSeverity as bu, type SignalStatus as bv, SignalsApi as bw, type SimulateSessionInput as bx, type StepResult as by, type SubjectAssurance as bz, type SessionPersonInput as c, type WebhookEnvelope as d, type SekyroEnvironment as e, type VerificationAssurance as f, type VerificationUnit as g, type SubjectReuseMode as h, type ResultCheckProofs as i, type SessionSignal as j, type FailureIdentification as k, type AgeResult as l, type AmlMatchFlaggedEventData as m, type ApiKeyIdentity as n, type BlockCheck as o, type BlockCheckInput as p, type BlockDuration as q, type BlockIdNumber as r, type BlockKind as s, type BlockMatch as t, type BlockReason as u, BlocksApi as v, type CameraUnavailableCause as w, type CheckState as x, type CheckType as y, type ClosedBy as z };