@soliton-id/web-sdk 1.1.2 → 1.3.0

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
@@ -4,6 +4,39 @@ All notable changes to `@soliton-id/web-sdk`. The `soliton-v1` postMessage
4
4
  protocol is frozen: changes are additive only, so older SDK versions keep
5
5
  working against the hosted flow.
6
6
 
7
+ ## 1.3.0 — 2026-11-09
8
+
9
+ Additive only. The default import, its `open()` and the `soliton-v1`
10
+ protocol are unchanged, so existing integrations need no code change.
11
+
12
+ - Add `@soliton-id/web-sdk/white-label` (ESM/CJS + types) for a verification
13
+ page served on your own hostname: the same `open()`, callbacks and error
14
+ codes, with `verificationOrigin` required and no built-in hosts (the URL
15
+ must be on exactly that origin). Nothing it adds to your page names Soliton:
16
+ the iframe title is "Identity verification" (or the optional `title`), and
17
+ its DOM markers, spinner, error messages and messages to the verification
18
+ page use neutral names. Needs the matching hosted verification release.
19
+
20
+ ## 1.2.0 — 2026-11-06
21
+
22
+ Additive only; existing calls are unchanged.
23
+
24
+ - `startVerification()` takes an optional `consent: { givenAt, noticeVersion }`.
25
+ Send it only if you skip the instructions screen (`intro=skip`) and collect
26
+ biometric consent on your own screen. That consent and its record remain
27
+ your responsibility; sending a copy is optional. It goes to Soliton as
28
+ `consent` on session creation, and Soliton then also keeps it for at least
29
+ 5 years. `givenAt` is a `Date` or an RFC 3339 string with `Z` or an offset
30
+ (a string without one is refused rather than read as local time), at most
31
+ 5 minutes in the future; `noticeVersion` is 1–64 printable characters.
32
+ - `onError` can report `consent_required`: your account requires consent, you
33
+ skipped the instructions screen and sent none, and the account is set to
34
+ refuse such checks. (Set to show the consent screen instead, the flow simply
35
+ shows it.)
36
+ - The README's `intro=skip` section matches the integration guide: link the
37
+ biometric privacy notice (live keys) or the testing data policy (sandbox
38
+ keys), and keep or send a record of each consent.
39
+
7
40
  ## 1.1.2 — 2026-10-29
8
41
 
9
42
  Documentation only; no code or API changes. The README explains `intro=skip`,
package/README.md CHANGED
@@ -7,6 +7,47 @@ protocol, completion callbacks and server-side result/webhook contracts are
7
7
  unchanged. See [the appliance guide](../docs/on-premise.md) for runtime origins,
8
8
  local assets, packaging, iframe permissions and top-level mobile WebViews.
9
9
 
10
+ ## White-label import
11
+
12
+ For a verification page served on your own hostname (for example
13
+ `https://verify.example.com`, set up for your account by Soliton), import the
14
+ white-label entry instead of the default one:
15
+
16
+ ```ts
17
+ import { open } from "@soliton-id/web-sdk/white-label";
18
+
19
+ const handle = open({
20
+ url, // the hosted URL from your backend, on your verification hostname
21
+ verificationOrigin: "https://verify.example.com", // required
22
+ onComplete: ({ verificationId }) => {
23
+ // Fetch the result server-side, as with the default import.
24
+ },
25
+ onError: ({ code, message }) => {},
26
+ onClose: () => {},
27
+ // title: "Identity verification", // optional iframe title
28
+ });
29
+ ```
30
+
31
+ It works like the default `open()`, with the same callbacks, error codes and
32
+ `handle.close()`, except:
33
+
34
+ - `verificationOrigin` is required: the exact HTTPS origin of your
35
+ verification hostname, taken from your configuration, never from browser
36
+ input. `open()` throws without it, and the URL must be on exactly that
37
+ origin; there are no built-in hosts. HTTP loopback (for example
38
+ `http://localhost:3000`) is accepted for development.
39
+ - Nothing it adds to your page names Soliton: the iframe title is
40
+ "Identity verification" (or your `title`), and its markup, styles, error
41
+ messages and messages to the verification page use neutral names.
42
+
43
+ Your page's `frame-src` and `Permissions-Policy` then name your verification
44
+ hostname instead of `https://soliton.id`. The default import is unchanged.
45
+
46
+ To keep the package name out of what you ship, build with your bundler's
47
+ production mode and do not publish source maps that include `node_modules`:
48
+ their file paths contain `@soliton-id/web-sdk`. Upload such maps privately to
49
+ your error tracker instead if you need them.
50
+
10
51
  ## Console API v2
11
52
 
12
53
  The SDK opens `https://soliton.id/v/{token}` links from
@@ -201,13 +242,39 @@ const handle = open({ url: directUrl.toString(), onComplete });
201
242
 
202
243
  If you skip the instructions screen, you must:
203
244
 
204
- 1. **Explain the check and collect consent first.** Tell the user what happens
205
- (camera, plus microphone for Medium and High) and collect any consent you
206
- need before opening the flow. For Medium and High, ask users to turn their
207
- speaker volume up, which the instructions screen does. For sandbox links,
208
- include Soliton's
209
- [testing data policy](https://soliton.id/testing-data), which the
210
- instructions screen would otherwise show.
245
+ 1. **Explain the check and collect biometric consent first.** Tell the user
246
+ what happens (camera, plus microphone for Medium and High) and get their
247
+ express consent to the collection and use of their facial biometric data
248
+ before opening the flow. Link Soliton's
249
+ [biometric privacy notice](https://soliton.id/biometric-notice) (live keys)
250
+ or [testing data policy](https://soliton.id/testing-data) (sandbox keys),
251
+ which the instructions screen would otherwise show. Keep a record of each
252
+ consent: the time, the text shown and the user. When you skip the screen,
253
+ you collect this consent, and you are responsible for it and for keeping its
254
+ record on your own systems. Sending Soliton a copy when you create the
255
+ session is optional; Soliton then also keeps it for at least 5 years:
256
+
257
+ ```js
258
+ await soliton.startVerification({
259
+ userReference: user.id,
260
+ tier: 'high',
261
+ idempotencyKey: attempt.id,
262
+ // When the person agreed, and which version of your consent text they saw.
263
+ consent: { givenAt: attempt.consentGivenAt, noticeVersion: 'your-consent-v3' },
264
+ onSessionCreated: async id => { await saveSession(user.id, attempt.id, id); },
265
+ });
266
+ ```
267
+
268
+ Without the helper, add
269
+ `"consent": {"given_at": "2026-11-06T18:02:11Z", "notice_version": "your-consent-v3"}`
270
+ to the `POST /api/v2/sessions` body. If Soliton has set your account to
271
+ require consent (everywhere, or where the person is in places agreed with
272
+ you, judged from their IP address; an unknown location counts) and you skip
273
+ the screen without sending it, the person sees Soliton's
274
+ consent screen instead, or the check cannot start and `onError` reports
275
+ `consent_required`, depending on your account's setting. For Medium and
276
+ High, ask users to turn their speaker volume up, which the instructions
277
+ screen does.
211
278
  2. **Let every iframe pass on camera, microphone and autoplay.** Each iframe
212
279
  between the browser window and the hosted page, including yours, needs
213
280
  `allow="camera; microphone; autoplay; fullscreen"`. The SDK's own iframe
package/dist/core.d.ts ADDED
@@ -0,0 +1,47 @@
1
+ /**
2
+ * Overlay lifecycle shared by every SDK entry point: frame the hosted
3
+ * verification page in a full-viewport overlay and relay its lifecycle through
4
+ * callbacks. The capture engine runs on the verification origin inside the
5
+ * iframe, so its defenses update with each hosted release and the verdict
6
+ * never touches the customer page (only the verification id does).
7
+ *
8
+ * Each entry injects its own names (message protocol and types, DOM markers,
9
+ * error prefix) and its own URL rules. Nothing in this module names an entry,
10
+ * so a bundle carries only the names of the entry it imports.
11
+ */
12
+ import type { OverlayNames } from "./overlay";
13
+ import type { ParsedHostedUrl } from "./urlCheck";
14
+ export interface EntryNames {
15
+ /** Protocol marker on every message, in both directions. */
16
+ protocol: string;
17
+ /** Parent -> child ping that lets the hosted page read our origin. */
18
+ hello: string;
19
+ /** Child -> parent lifecycle message types. */
20
+ ready: string;
21
+ complete: string;
22
+ error: string;
23
+ close: string;
24
+ /** Prefix of every error open() throws. */
25
+ errorPrefix: string;
26
+ overlay: OverlayNames;
27
+ /** Extra query parameters set on the iframe URL. */
28
+ params?: ReadonlyArray<readonly [string, string]>;
29
+ }
30
+ export interface OpenOptions {
31
+ url: string;
32
+ verificationOrigin?: string;
33
+ onComplete: (e: {
34
+ verificationId: string;
35
+ }) => void;
36
+ onError?: (e: {
37
+ code: string;
38
+ message: string;
39
+ }) => void;
40
+ onClose?: () => void;
41
+ locale?: string;
42
+ }
43
+ export interface OpenHandle {
44
+ close(): void;
45
+ }
46
+ export type UrlRules = (raw: string, verificationOrigin?: string) => ParsedHostedUrl;
47
+ export declare function openOverlay(options: OpenOptions, names: EntryNames, parseUrl: UrlRules): OpenHandle;
@@ -1,17 +1,12 @@
1
1
  /**
2
2
  * Validation of the hosted verification URL handed to SolitonVerify.open().
3
3
  *
4
- * The SDK only ever frames URLs that look exactly like the ones minted by
5
- * the v1 verification API or v2 session link API: an approved Soliton origin (http strictly for
6
- * localhost dev) and a bare /v/{32 hex} path. Everything else throws
7
- * synchronously — a bad URL is an integration bug, not a runtime flow event,
8
- * so it must fail loudly at the call site instead of rendering an
9
- * attacker-chosen page in our overlay.
4
+ * The default entry frames URLs from an approved Soliton origin (http strictly
5
+ * for localhost dev) or, when the integrator configures one, exactly its
6
+ * verificationOrigin. The shared shape rules (bare /v/{32 hex} path, no
7
+ * credentials) live in urlCheck.ts; the Soliton allowlist lives only here, so
8
+ * the white-label entry, which never imports this module, cannot carry it.
10
9
  */
11
- export interface ParsedHostedUrl {
12
- /** The validated URL, normalized by the URL parser. */
13
- url: URL;
14
- /** Origin the SDK will trust for postMessage events. */
15
- hostedOrigin: string;
16
- }
10
+ import type { ParsedHostedUrl } from "./urlCheck";
11
+ export type { ParsedHostedUrl };
17
12
  export declare function parseHostedUrl(raw: string, verificationOrigin?: string): ParsedHostedUrl;
package/dist/index.cjs CHANGED
@@ -27,58 +27,14 @@ __export(index_exports, {
27
27
  });
28
28
  module.exports = __toCommonJS(index_exports);
29
29
 
30
- // sdk/src/trustedOrigin.ts
31
- function trustedOrigin(value) {
32
- const url = new URL(value);
33
- const local = ["localhost", "127.0.0.1", "[::1]"].includes(url.hostname);
34
- if (url.origin !== value || url.username || url.password || value.includes("*") || url.protocol !== "https:" && !(url.protocol === "http:" && local)) {
35
- throw new Error("Use an exact HTTPS origin (HTTP loopback is allowed for development)");
36
- }
37
- return url.origin;
38
- }
39
-
40
- // sdk/src/hostedUrl.ts
41
- var HOSTED_PATH_RE = /^\/v\/[0-9a-f]{32}$/;
42
- var ALLOWED_HTTPS_ORIGINS = /* @__PURE__ */ new Set([
43
- "https://soliton.id",
44
- "https://staging.soliton.id"
45
- ]);
46
- function parseHostedUrl(raw, verificationOrigin) {
47
- const configuredOrigin = verificationOrigin === void 0 ? void 0 : trustedOrigin(verificationOrigin);
48
- let url;
49
- try {
50
- url = new URL(raw);
51
- } catch (e) {
52
- throw new Error(`SolitonVerify: "url" is not a valid absolute URL`);
53
- }
54
- const isLocalHttp = url.protocol === "http:" && (url.hostname === "localhost" || url.hostname === "127.0.0.1");
55
- if (configuredOrigin !== void 0 && url.origin !== configuredOrigin) {
56
- throw new Error('SolitonVerify: "url" does not match the configured verificationOrigin');
57
- }
58
- if (configuredOrigin === void 0 && !ALLOWED_HTTPS_ORIGINS.has(url.origin) && !isLocalHttp) {
59
- throw new Error(
60
- 'SolitonVerify: "url" must be hosted on https://soliton.id or https://staging.soliton.id (http is allowed for localhost/127.0.0.1 development only)'
61
- );
62
- }
63
- if (url.username || url.password) {
64
- throw new Error('SolitonVerify: "url" must not embed credentials');
65
- }
66
- if (!HOSTED_PATH_RE.test(url.pathname)) {
67
- throw new Error(
68
- 'SolitonVerify: "url" does not look like a hosted verification URL (/v/{token})'
69
- );
70
- }
71
- return { url, hostedOrigin: url.origin };
72
- }
73
-
74
30
  // sdk/src/overlay.ts
75
31
  var MAX_Z_INDEX = "2147483647";
76
32
  var openOverlayCount = 0;
77
33
  var savedBodyOverflow = "";
78
- function createOverlay(iframeSrc, onCloseClick) {
34
+ function createOverlay(iframeSrc, onCloseClick, names) {
79
35
  const doc = document;
80
36
  const container = doc.createElement("div");
81
- container.setAttribute("data-soliton-sdk", "overlay");
37
+ container.setAttribute(names.marker, "overlay");
82
38
  container.style.cssText = [
83
39
  "position:fixed",
84
40
  "inset:0",
@@ -87,10 +43,10 @@ function createOverlay(iframeSrc, onCloseClick) {
87
43
  "display:block"
88
44
  ].join(";");
89
45
  const style = doc.createElement("style");
90
- style.textContent = "@keyframes soliton-sdk-spin{to{transform:rotate(360deg)}}";
46
+ style.textContent = `@keyframes ${names.animation}{to{transform:rotate(360deg)}}`;
91
47
  container.appendChild(style);
92
48
  const loading = doc.createElement("div");
93
- loading.setAttribute("data-soliton-sdk", "loading");
49
+ loading.setAttribute(names.marker, "loading");
94
50
  loading.style.cssText = [
95
51
  "position:absolute",
96
52
  "inset:0",
@@ -109,7 +65,7 @@ function createOverlay(iframeSrc, onCloseClick) {
109
65
  "border-radius:999px",
110
66
  "border:2px solid rgba(255,255,255,0.25)",
111
67
  "border-top-color:rgba(255,255,255,0.9)",
112
- "animation:soliton-sdk-spin 0.8s linear infinite"
68
+ `animation:${names.animation} 0.8s linear infinite`
113
69
  ].join(";");
114
70
  const loadingText = doc.createElement("div");
115
71
  loadingText.textContent = "Loading secure verification...";
@@ -118,7 +74,7 @@ function createOverlay(iframeSrc, onCloseClick) {
118
74
  container.appendChild(loading);
119
75
  const iframe = doc.createElement("iframe");
120
76
  iframe.setAttribute("allow", "camera; microphone; fullscreen; autoplay");
121
- iframe.setAttribute("title", "Soliton identity verification");
77
+ iframe.setAttribute("title", names.title);
122
78
  iframe.style.cssText = [
123
79
  "position:absolute",
124
80
  "inset:0",
@@ -173,43 +129,42 @@ function createOverlay(iframeSrc, onCloseClick) {
173
129
  };
174
130
  }
175
131
 
176
- // sdk/src/types.ts
177
- var EMBED_PROTOCOL = "soliton-v1";
178
-
179
- // sdk/src/index.ts
132
+ // sdk/src/core.ts
180
133
  var AUTO_CLOSE_DELAY_MS = 250;
181
134
  var HELLO_INTERVAL_MS = 250;
182
135
  var HELLO_MAX_PINGS = 40;
183
136
  var READY_TIMEOUT_MS = 3e4;
184
- function open(options) {
137
+ function openOverlay(options, names, parseUrl) {
138
+ var _a;
185
139
  if (!options || typeof options.url !== "string") {
186
- throw new Error('SolitonVerify: open() requires an options object with a "url"');
140
+ throw new Error(`${names.errorPrefix} open() requires an options object with a "url"`);
187
141
  }
188
142
  if (typeof options.onComplete !== "function") {
189
- throw new Error("SolitonVerify: open() requires an onComplete callback");
143
+ throw new Error(`${names.errorPrefix} open() requires an onComplete callback`);
190
144
  }
191
- const { url, hostedOrigin } = parseHostedUrl(options.url, options.verificationOrigin);
145
+ const { url, hostedOrigin } = parseUrl(options.url, options.verificationOrigin);
192
146
  const src = new URL(url.toString());
193
147
  src.searchParams.set("mode", "embed");
194
148
  src.searchParams.set("sdk", "1");
149
+ for (const [key, value] of (_a = names.params) != null ? _a : []) src.searchParams.set(key, value);
195
150
  if (options.locale) src.searchParams.set("locale", options.locale);
196
151
  let closed = false;
197
152
  let terminalDelivered = false;
198
153
  let loadTimedOut = false;
199
154
  let autoCloseTimer = null;
200
155
  let readyTimer = null;
201
- const overlay = createOverlay(src.toString(), () => close());
156
+ const overlay = createOverlay(src.toString(), () => close(), names.overlay);
202
157
  let helloPings = 0;
203
158
  const postHello = () => {
204
- var _a;
159
+ var _a2;
205
160
  helloPings += 1;
206
161
  if (helloPings > HELLO_MAX_PINGS) {
207
162
  stopHello();
208
163
  return;
209
164
  }
210
165
  try {
211
- (_a = overlay.iframe.contentWindow) == null ? void 0 : _a.postMessage(
212
- { protocol: EMBED_PROTOCOL, type: "soliton:hello" },
166
+ (_a2 = overlay.iframe.contentWindow) == null ? void 0 : _a2.postMessage(
167
+ { protocol: names.protocol, type: names.hello },
213
168
  hostedOrigin
214
169
  );
215
170
  } catch (e) {
@@ -227,23 +182,23 @@ function open(options) {
227
182
  readyTimer = null;
228
183
  }
229
184
  const onMessage = (event) => {
230
- var _a;
185
+ var _a2;
231
186
  if (closed || loadTimedOut || terminalDelivered) return;
232
187
  if (event.origin !== hostedOrigin) return;
233
188
  if (!overlay.iframe.contentWindow || event.source !== overlay.iframe.contentWindow) {
234
189
  return;
235
190
  }
236
191
  const data = event.data;
237
- if (!data || typeof data !== "object" || data.protocol !== EMBED_PROTOCOL) {
192
+ if (!data || typeof data !== "object" || data.protocol !== names.protocol) {
238
193
  return;
239
194
  }
240
195
  stopHello();
241
196
  switch (data.type) {
242
- case "soliton:ready":
197
+ case names.ready:
243
198
  stopReadyWait();
244
199
  overlay.markReady();
245
200
  break;
246
- case "soliton:complete": {
201
+ case names.complete: {
247
202
  if (terminalDelivered) break;
248
203
  stopReadyWait();
249
204
  terminalDelivered = true;
@@ -253,14 +208,14 @@ function open(options) {
253
208
  });
254
209
  break;
255
210
  }
256
- case "soliton:error":
211
+ case names.error:
257
212
  stopReadyWait();
258
- (_a = options.onError) == null ? void 0 : _a.call(options, {
213
+ (_a2 = options.onError) == null ? void 0 : _a2.call(options, {
259
214
  code: typeof data.code === "string" ? data.code : "internal",
260
215
  message: typeof data.message === "string" ? data.message : ""
261
216
  });
262
217
  break;
263
- case "soliton:close":
218
+ case names.close:
264
219
  close();
265
220
  break;
266
221
  default:
@@ -269,11 +224,11 @@ function open(options) {
269
224
  };
270
225
  window.addEventListener("message", onMessage);
271
226
  readyTimer = setTimeout(() => {
272
- var _a;
227
+ var _a2;
273
228
  if (readyTimer === null || closed || terminalDelivered) return;
274
229
  loadTimedOut = true;
275
230
  try {
276
- (_a = options.onError) == null ? void 0 : _a.call(options, {
231
+ (_a2 = options.onError) == null ? void 0 : _a2.call(options, {
277
232
  code: "load_timeout",
278
233
  message: "Verification did not load. Please try again."
279
234
  });
@@ -282,7 +237,7 @@ function open(options) {
282
237
  }
283
238
  }, READY_TIMEOUT_MS);
284
239
  function close() {
285
- var _a;
240
+ var _a2;
286
241
  if (closed) return;
287
242
  closed = true;
288
243
  if (autoCloseTimer !== null) clearTimeout(autoCloseTimer);
@@ -290,9 +245,88 @@ function open(options) {
290
245
  stopHello();
291
246
  window.removeEventListener("message", onMessage);
292
247
  overlay.destroy();
293
- if (!terminalDelivered) (_a = options.onClose) == null ? void 0 : _a.call(options);
248
+ if (!terminalDelivered) (_a2 = options.onClose) == null ? void 0 : _a2.call(options);
294
249
  }
295
250
  return { close };
296
251
  }
252
+
253
+ // sdk/src/trustedOrigin.ts
254
+ function trustedOrigin(value) {
255
+ const url = new URL(value);
256
+ const local = ["localhost", "127.0.0.1", "[::1]"].includes(url.hostname);
257
+ if (url.origin !== value || url.username || url.password || value.includes("*") || url.protocol !== "https:" && !(url.protocol === "http:" && local)) {
258
+ throw new Error("Use an exact HTTPS origin (HTTP loopback is allowed for development)");
259
+ }
260
+ return url.origin;
261
+ }
262
+
263
+ // sdk/src/urlCheck.ts
264
+ var HOSTED_PATH_RE = /^\/v\/[0-9a-f]{32}$/;
265
+ function checkHostedUrl(raw, prefix, configuredOrigin, checkUnconfigured) {
266
+ let url;
267
+ try {
268
+ url = new URL(raw);
269
+ } catch (e) {
270
+ throw new Error(`${prefix} "url" is not a valid absolute URL`);
271
+ }
272
+ if (configuredOrigin !== void 0) {
273
+ if (url.origin !== configuredOrigin) {
274
+ throw new Error(`${prefix} "url" does not match the configured verificationOrigin`);
275
+ }
276
+ } else if (checkUnconfigured) {
277
+ checkUnconfigured(url);
278
+ } else {
279
+ throw new Error(`${prefix} open() requires "verificationOrigin"`);
280
+ }
281
+ if (url.username || url.password) {
282
+ throw new Error(`${prefix} "url" must not embed credentials`);
283
+ }
284
+ if (!HOSTED_PATH_RE.test(url.pathname)) {
285
+ throw new Error(
286
+ `${prefix} "url" does not look like a hosted verification URL (/v/{token})`
287
+ );
288
+ }
289
+ return { url, hostedOrigin: url.origin };
290
+ }
291
+
292
+ // sdk/src/hostedUrl.ts
293
+ var ERROR_PREFIX = "SolitonVerify:";
294
+ var ALLOWED_HTTPS_ORIGINS = /* @__PURE__ */ new Set([
295
+ "https://soliton.id",
296
+ "https://staging.soliton.id"
297
+ ]);
298
+ function parseHostedUrl(raw, verificationOrigin) {
299
+ const configuredOrigin = verificationOrigin === void 0 ? void 0 : trustedOrigin(verificationOrigin);
300
+ return checkHostedUrl(raw, ERROR_PREFIX, configuredOrigin, (url) => {
301
+ const isLocalHttp = url.protocol === "http:" && (url.hostname === "localhost" || url.hostname === "127.0.0.1");
302
+ if (!ALLOWED_HTTPS_ORIGINS.has(url.origin) && !isLocalHttp) {
303
+ throw new Error(
304
+ 'SolitonVerify: "url" must be hosted on https://soliton.id or https://staging.soliton.id (http is allowed for localhost/127.0.0.1 development only)'
305
+ );
306
+ }
307
+ });
308
+ }
309
+
310
+ // sdk/src/types.ts
311
+ var EMBED_PROTOCOL = "soliton-v1";
312
+
313
+ // sdk/src/index.ts
314
+ var SOLITON_NAMES = {
315
+ protocol: EMBED_PROTOCOL,
316
+ hello: "soliton:hello",
317
+ ready: "soliton:ready",
318
+ complete: "soliton:complete",
319
+ error: "soliton:error",
320
+ close: "soliton:close",
321
+ errorPrefix: "SolitonVerify:",
322
+ overlay: {
323
+ marker: "data-soliton-sdk",
324
+ animation: "soliton-sdk-spin",
325
+ title: "Soliton identity verification"
326
+ }
327
+ };
328
+ function open(options) {
329
+ return openOverlay(options, SOLITON_NAMES, parseHostedUrl);
330
+ }
297
331
  var SolitonVerify = { open };
298
332
  var index_default = SolitonVerify;
package/dist/index.d.ts CHANGED
@@ -6,6 +6,10 @@
6
6
  * the iframe, so anti-injection defenses update with each frontend release and the
7
7
  * verdict never touches the customer page (only the verification id does).
8
8
  *
9
+ * The lifecycle itself lives in core.ts; this entry injects the soliton-v1
10
+ * names and the Soliton origin allowlist. The white-label entry
11
+ * (white-label.ts) injects neutral ones instead and never imports this file.
12
+ *
9
13
  * Built artifacts (npm run build:sdk):
10
14
  * public/sdk/v1/soliton-web-sdk.js IIFE, global `SolitonVerify`
11
15
  * public/sdk/v1/soliton-web-sdk.esm.js ESM, `import { open } ...`