@sparkvault/sdk-js 19.0.1 → 19.1.1

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.
Files changed (133) hide show
  1. package/README.md +26 -4
  2. package/dist/npm/chunks/index-C97091lF.mjs +12959 -0
  3. package/dist/npm/chunks/index-C97091lF.mjs.map +1 -0
  4. package/dist/npm/chunks/index-D_p_8VO7.cjs +13024 -0
  5. package/dist/npm/chunks/index-D_p_8VO7.cjs.map +1 -0
  6. package/dist/npm/identity.cjs +23 -0
  7. package/dist/npm/identity.cjs.map +1 -0
  8. package/dist/npm/identity.mjs +12 -0
  9. package/dist/npm/identity.mjs.map +1 -0
  10. package/dist/{index.cjs → npm/index.cjs} +802 -13759
  11. package/dist/npm/index.cjs.map +1 -0
  12. package/dist/{index.mjs → npm/index.mjs} +203 -13159
  13. package/dist/npm/index.mjs.map +1 -0
  14. package/dist/sparkvault-identity.js +2 -0
  15. package/dist/sparkvault-identity.js.map +1 -0
  16. package/dist/sparkvault.js +1 -1
  17. package/dist/sparkvault.js.map +1 -1
  18. package/dist/types/identity.d.ts +8 -0
  19. package/dist/{index.d.ts → types/index.d.ts} +4 -790
  20. package/dist/types/shared/errors-C-gjmGBs.d.ts +800 -0
  21. package/package.json +20 -9
  22. package/dist/api-base.d.ts +0 -116
  23. package/dist/auto-init.d.ts +0 -32
  24. package/dist/config.d.ts +0 -79
  25. package/dist/entropy/index.d.ts +0 -35
  26. package/dist/entropy/types.d.ts +0 -32
  27. package/dist/errors.d.ts +0 -146
  28. package/dist/folders/index.d.ts +0 -102
  29. package/dist/folders/types.d.ts +0 -91
  30. package/dist/health.d.ts +0 -18
  31. package/dist/http.d.ts +0 -46
  32. package/dist/index.cjs.map +0 -1
  33. package/dist/index.mjs.map +0 -1
  34. package/dist/ingots/fetch-download.d.ts +0 -78
  35. package/dist/ingots/history.d.ts +0 -4
  36. package/dist/ingots/index.d.ts +0 -388
  37. package/dist/ingots/revision.d.ts +0 -4
  38. package/dist/ingots/types.d.ts +0 -556
  39. package/dist/logger.d.ts +0 -32
  40. package/dist/notify/index.d.ts +0 -154
  41. package/dist/notify/types.d.ts +0 -232
  42. package/dist/products/help-desk/client.d.ts +0 -198
  43. package/dist/products/help-desk/desk-id.d.ts +0 -2
  44. package/dist/products/help-desk/form-draft.d.ts +0 -37
  45. package/dist/products/help-desk/form-types.d.ts +0 -123
  46. package/dist/products/help-desk/form.d.ts +0 -83
  47. package/dist/products/help-desk/index.d.ts +0 -47
  48. package/dist/products/help-desk/kb-client.d.ts +0 -48
  49. package/dist/products/help-desk/kb-types.d.ts +0 -59
  50. package/dist/products/help-desk/modal.d.ts +0 -8
  51. package/dist/products/help-desk/styles.d.ts +0 -9
  52. package/dist/products/help-desk/support-analytics-types.d.ts +0 -32
  53. package/dist/products/help-desk/support-analytics.d.ts +0 -3
  54. package/dist/products/help-desk/support-brand.d.ts +0 -49
  55. package/dist/products/help-desk/support-controller.d.ts +0 -4
  56. package/dist/products/help-desk/support-history.d.ts +0 -38
  57. package/dist/products/help-desk/support-launcher.d.ts +0 -12
  58. package/dist/products/help-desk/support-styles.d.ts +0 -14
  59. package/dist/products/help-desk/support-types.d.ts +0 -66
  60. package/dist/products/help-desk/support-view.d.ts +0 -173
  61. package/dist/products/help-desk/types.d.ts +0 -285
  62. package/dist/products/help-desk/widget-identity.d.ts +0 -32
  63. package/dist/products/identity/api.d.ts +0 -237
  64. package/dist/products/identity/container.d.ts +0 -44
  65. package/dist/products/identity/dialog-launcher.d.ts +0 -133
  66. package/dist/products/identity/federation-flow.d.ts +0 -31
  67. package/dist/products/identity/handlers/otp-handler.d.ts +0 -69
  68. package/dist/products/identity/handlers/passkey-handler.d.ts +0 -105
  69. package/dist/products/identity/handlers/sparklink-handler.d.ts +0 -34
  70. package/dist/products/identity/index.d.ts +0 -296
  71. package/dist/products/identity/inline-container.d.ts +0 -53
  72. package/dist/products/identity/methods.d.ts +0 -19
  73. package/dist/products/identity/modal.d.ts +0 -51
  74. package/dist/products/identity/pending-signin.d.ts +0 -102
  75. package/dist/products/identity/popup-launcher.d.ts +0 -73
  76. package/dist/products/identity/renderer.d.ts +0 -525
  77. package/dist/products/identity/state.d.ts +0 -84
  78. package/dist/products/identity/styles.d.ts +0 -31
  79. package/dist/products/identity/types.d.ts +0 -561
  80. package/dist/products/identity/utils/cooldown-timer.d.ts +0 -73
  81. package/dist/products/identity/utils.d.ts +0 -85
  82. package/dist/products/identity/views/backup-verify.d.ts +0 -42
  83. package/dist/products/identity/views/base.d.ts +0 -51
  84. package/dist/products/identity/views/error.d.ts +0 -65
  85. package/dist/products/identity/views/icons.d.ts +0 -41
  86. package/dist/products/identity/views/identity-input.d.ts +0 -80
  87. package/dist/products/identity/views/index.d.ts +0 -20
  88. package/dist/products/identity/views/loading.d.ts +0 -23
  89. package/dist/products/identity/views/method-button.d.ts +0 -14
  90. package/dist/products/identity/views/method-select.d.ts +0 -42
  91. package/dist/products/identity/views/origin-not-allowed.d.ts +0 -25
  92. package/dist/products/identity/views/otp-verify.d.ts +0 -58
  93. package/dist/products/identity/views/passkey-auto.d.ts +0 -22
  94. package/dist/products/identity/views/passkey-prompt.d.ts +0 -25
  95. package/dist/products/identity/views/passkey.d.ts +0 -38
  96. package/dist/products/identity/views/product-not-configured.d.ts +0 -21
  97. package/dist/products/identity/views/service-unavailable.d.ts +0 -21
  98. package/dist/products/identity/views/sms-consent.d.ts +0 -16
  99. package/dist/products/identity/views/sparklink-waiting.d.ts +0 -40
  100. package/dist/products/identity/views/two-factor.d.ts +0 -37
  101. package/dist/products/index.d.ts +0 -51
  102. package/dist/products/messaging/index.d.ts +0 -38
  103. package/dist/products/messaging/types.d.ts +0 -162
  104. package/dist/products/notify/index.d.ts +0 -436
  105. package/dist/products/notify/project-types.d.ts +0 -44
  106. package/dist/products/notify/projects.d.ts +0 -15
  107. package/dist/products/notify/types.d.ts +0 -1327
  108. package/dist/products/structured-ingots/index.d.ts +0 -31
  109. package/dist/products/structured-ingots/types-client.d.ts +0 -19
  110. package/dist/products/structured-ingots/types.d.ts +0 -293
  111. package/dist/products/structured-ingots/validation.d.ts +0 -25
  112. package/dist/request-path.d.ts +0 -44
  113. package/dist/sparks/index.d.ts +0 -91
  114. package/dist/sparks/types.d.ts +0 -304
  115. package/dist/ui/chrome.d.ts +0 -16
  116. package/dist/ui/ds-tokens.d.ts +0 -59
  117. package/dist/ui/inline-shell.d.ts +0 -19
  118. package/dist/ui/live-region.d.ts +0 -15
  119. package/dist/ui/modal-shell.d.ts +0 -67
  120. package/dist/ui/target.d.ts +0 -6
  121. package/dist/utils/dom.d.ts +0 -26
  122. package/dist/vault-session.d.ts +0 -2
  123. package/dist/vaults/index.d.ts +0 -254
  124. package/dist/vaults/types.d.ts +0 -368
  125. package/dist/vaults/upload/api.d.ts +0 -310
  126. package/dist/vaults/upload/chrome.d.ts +0 -21
  127. package/dist/vaults/upload/container.d.ts +0 -37
  128. package/dist/vaults/upload/index.d.ts +0 -76
  129. package/dist/vaults/upload/inline-container.d.ts +0 -41
  130. package/dist/vaults/upload/modal.d.ts +0 -55
  131. package/dist/vaults/upload/renderer.d.ts +0 -150
  132. package/dist/vaults/upload/styles.d.ts +0 -14
  133. package/dist/vaults/upload/types.d.ts +0 -220
@@ -1,78 +1,5 @@
1
- /**
2
- * SparkVault SDK Configuration
3
- */
4
- /** Server-confirmed timing for the exact vault session a request presented. */
5
- interface VaultSessionTiming {
6
- vat: string;
7
- /** Current reseal deadline in server Unix seconds. */
8
- expiresAt: number;
9
- /** Fixed maximum deadline from the original unseal, in server Unix seconds. */
10
- hardExpiresAt: number;
11
- /** Seconds remaining on the server, suitable for a device-local countdown. */
12
- remainingSeconds: number;
13
- hardRemainingSeconds: number;
14
- /** Zero for a fixed session; absent when talking to an older Core version. */
15
- idleTimeoutSeconds?: number;
16
- /** Device clock before the Core request, for conservative local countdowns. */
17
- requestStartedAtMs?: number;
18
- }
19
- interface SparkVaultConfig {
20
- /** Account ID for Identity operations */
21
- accountId: string;
22
- /** Core API origin. Defaults to https://api.sparkvault.com. A trailing /v1 is accepted and normalized. */
23
- apiBaseUrl?: string;
24
- /** Identity Product API base URL. Defaults to https://auth.sparkvault.com. */
25
- identityBaseUrl?: string;
26
- /** auth.sv portal origin for self-service deep links (`portalUrl()`). Defaults to https://auth.sv. */
27
- portalBaseUrl?: string;
28
- /** Static SparkVault Core access token for authenticated API calls. */
29
- accessToken?: string;
30
- /** Dynamic SparkVault Core access token provider for authenticated API calls. */
31
- getAccessToken?: () => string | null | Promise<string | null>;
32
- /** Observe server-confirmed vault-session timing after an authorized Core response. */
33
- onVaultSessionTiming?: (timing: VaultSessionTiming) => void;
34
- /** Optional API key for server-side SDK use. */
35
- apiKey?: string;
36
- /**
37
- * OIDC client id registered for this account. Required only for FedCM
38
- * one-click sign-in (`signInWithFedcm()`), which asserts to a registered RP.
39
- */
40
- clientId?: string;
41
- /** Request timeout in milliseconds (default: 30000) */
42
- timeout?: number;
43
- /**
44
- * Preload Identity configuration on SDK init (default: true in a browser,
45
- * false off-DOM). When enabled, the /config call is made immediately when the
46
- * SDK initializes, so verify() opens instantly without waiting for the config
47
- * fetch. It buys nothing in a server process (there is no dialog to open),
48
- * so a Node host does not pay for a network call it will never use.
49
- * Set explicitly to override in either direction.
50
- */
51
- preloadConfig?: boolean;
52
- /** Enable backdrop blur on dialogs (default: true) */
53
- backdropBlur?: boolean;
54
- /**
55
- * Host allowlist for the backend-issued Forge transfer URLs the SDK sends an
56
- * ingot's ISTK to (downloads and uploads alike). Defaults to the SparkVault
57
- * platform's own hosts; override only when pointing at another deployment.
58
- */
59
- allowedDownloadHostPatterns?: RegExp[];
60
- }
61
- interface ResolvedConfig {
62
- accountId: string;
63
- timeout: number;
64
- apiBaseUrl: string;
65
- identityBaseUrl: string;
66
- portalBaseUrl: string;
67
- accessToken?: string;
68
- getAccessToken?: () => string | null | Promise<string | null>;
69
- onVaultSessionTiming?: (timing: VaultSessionTiming) => void;
70
- apiKey?: string;
71
- clientId?: string;
72
- preloadConfig: boolean;
73
- backdropBlur: boolean;
74
- allowedDownloadHostPatterns: RegExp[];
75
- }
1
+ import { j as ResolvedConfig, I as IdentityModule, m as SparkVaultConfig } from './shared/errors-C-gjmGBs.js';
2
+ export { a as AuthenticationError, b as AuthorizationError, A as IdentityAttachOptions, c as IdentityProviderError, N as NetworkError, P as PlanRequiredError, d as PopupBlockedError, e as PopupSeveredError, Q as QuotaExceededError, h as QuotaResource, S as SignInOptions, k as SignInResult, l as SigninIdentityType, n as SparkVaultError, T as TimeoutError, o as TokenClaims, U as UnauthorizedError, p as UsageCreditFundingReviewError, q as UsageCreditsExhaustedError, r as UserCancelledError, V as ValidationError, s as VaultSessionTiming, t as VerifyOptions, u as VerifyResult } from './shared/errors-C-gjmGBs.js';
76
3
 
77
4
  interface HealthCheckOptions {
78
5
  timeout?: number;
@@ -164,595 +91,6 @@ declare class HttpClient {
164
91
  delete<T = unknown>(path: ApiPath, options?: Omit<RequestOptions, 'method' | 'body'>): Promise<ApiResponse<T>>;
165
92
  }
166
93
 
167
- /**
168
- * Identity Module Types
169
- */
170
- /**
171
- * The kind of identifier a sign-in verified. `federated` is a person the
172
- * account's own identity provider signed in: one person of that account's
173
- * directory alone, never a global identity.
174
- */
175
- type VerifiedIdentityType = 'email' | 'phone' | 'social' | 'federated';
176
- /**
177
- * An identity type a sign-in may be restricted to (`SignInOptions.identityTypes`):
178
- * the kinds a token's `identity_type` carries, as the sign-in contract
179
- * (app-sdk identity-signin-contract SIGNIN_IDENTITY_TYPES) names them.
180
- */
181
- type SigninIdentityType = VerifiedIdentityType;
182
- /**
183
- * Auth context for OIDC or simple redirect flows.
184
- * Used by hosted login pages to complete authorization flows.
185
- */
186
- interface AuthContext {
187
- /** OIDC auth request ID for authorization code flow */
188
- authRequestId?: string;
189
- /**
190
- * A verification against a verify session, as the SparkVault-hosted page
191
- * that serves it describes it. Every request of the verification names the
192
- * session, and the server reads its destination, state and purpose from it.
193
- * `methods` and `allowedIdentityTypes` are what the session admits, decided
194
- * by the server from the session, and the page offers them in place of the
195
- * account's sign-in methods: a Notify recipient's proof of address admits a
196
- * code emailed to the address it was sent to and a passkey, whatever the
197
- * account's sign-in switches on, and the passkey alone for a request its
198
- * sender held to a passkey; no verify session admits a SparkLink or a social
199
- * sign-in, neither of which can complete one.
200
- */
201
- simpleMode?: {
202
- /** Opaque server-side verify session the verification completes against */
203
- sessionId: string;
204
- /** The methods the session admits */
205
- methods: MethodId[];
206
- /** The identifier types the session's methods deliver to */
207
- allowedIdentityTypes: ('email' | 'phone')[];
208
- /**
209
- * True when the session proves a request its sender held to a passkey: it
210
- * admits the passkey alone, so a person who holds no passkey registered
211
- * with SparkVault is told that only the sender can resend the request at a
212
- * level they can clear, never offered a way that cannot complete it.
213
- * Absent reads as false.
214
- */
215
- passkeyRequired?: boolean;
216
- };
217
- }
218
- interface VerifyOptions {
219
- /** Pre-fill email address (mutually exclusive with phone) */
220
- email?: string;
221
- /**
222
- * Pre-fill phone number in E.164 format, e.g. "+14155551234" (mutually
223
- * exclusive with email). The sign-in texts or calls it only once the person
224
- * picks a text or call method, under the SMS and voice consent.
225
- */
226
- phone?: string;
227
- /**
228
- * Target element for inline rendering. Can be:
229
- * - A CSS selector string (e.g., "#auth-container")
230
- * - An HTMLElement reference
231
- * - Omitted for dialog mode (default)
232
- */
233
- target?: string | HTMLElement;
234
- /** Override backdrop blur for this dialog (uses global config if omitted) */
235
- backdropBlur?: boolean;
236
- /**
237
- * Container chrome for inline (`target`) rendering. `'card'` (default) wraps
238
- * the flow in a bordered, rounded surface with the SparkVault footer. `'bare'`
239
- * drops the surface and footer so a host page (e.g. the SparkVault sign-in
240
- * page) can supply its own full-window chrome: logo, background, footer.
241
- * Ignored in dialog mode.
242
- */
243
- chrome?: 'card' | 'bare';
244
- /** Auth context for OIDC/simple mode flows (used by hosted login) */
245
- authContext?: AuthContext;
246
- /**
247
- * How sign-in leaves this page. `'auto'` (default) and `'popup'` open the
248
- * first-party popup; `'redirect'` navigates this tab to the sign-in page
249
- * instead (its return leg is `handleRedirectResult()`), the opt-out for
250
- * hosts that prefer a full-page redirect over a popup on mobile.
251
- */
252
- flow?: 'auto' | 'popup' | 'redirect';
253
- /**
254
- * `'select_account'` always shows the sign-in page's account chooser instead
255
- * of silently continuing as the current account, even when only one saved
256
- * account exists. Any other value is dropped at URL serialization.
257
- */
258
- prompt?: 'select_account';
259
- /**
260
- * `'federation'` starts sign-in with the account's own identity provider
261
- * at once: the sign-in page skips its account chooser and the method list
262
- * and leaves for the provider. Honoured only while the account has its
263
- * identity provider switched on; otherwise the page starts as usual,
264
- * account chooser included. Any other value is dropped at URL
265
- * serialization.
266
- */
267
- method?: 'federation';
268
- /**
269
- * The identity types this sign-in may produce (the token's `identity_type`),
270
- * for a caller that accepts only some: the sign-in page offers only the ways
271
- * in that can produce one, and Identity refuses a sign-in of any other type
272
- * before it is counted, billed or minted. At least one type; a value that
273
- * names none, or a type outside `SigninIdentityType`, is a ValidationError
274
- * before anything opens. Omitted: any type, as without it. The caller's own
275
- * check of the token's `identity_type` stays its final gate.
276
- */
277
- identityTypes?: SigninIdentityType[];
278
- /**
279
- * Rendering strategy (internal). `'local'` renders the flow directly in this
280
- * document: used inside the popup that runs the flow, and forced for inline
281
- * (`target`) rendering. Dialog mode (omitted) renders a thin launcher and
282
- * opens the popup.
283
- */
284
- renderMode?: 'local';
285
- /**
286
- * The sign-in's reference (internal): set by the SparkVault sign-in page
287
- * that runs the flow, never by a site. Every call that completes the
288
- * sign-in from the page carries the reference the flow holds at that
289
- * moment, and so does a start through the account's own identity
290
- * provider, so Identity records it on the hub session the sign-in creates
291
- * or chooses (or, for the provider, which opens none, releases it from the
292
- * browser's hub sessions), and a lost popup result recovers that sign-in
293
- * only. The flow offers the provider only on an explicit signal: a
294
- * reference held, or `completesInWindow`. The reference never holds up the
295
- * sign-in: a call made before it arrives carries none.
296
- * - A reference: held from the start. The provider is offered. A value
297
- * that is no reference is `null`.
298
- * - A function: the reference arrives after the flow renders. The flow
299
- * calls it once as it starts, and again only on the person's Try Again;
300
- * each call asks afresh, and resolves to a reference, or to null when
301
- * none could be had for now (a rejection, or a value that is no
302
- * reference, is null too). The provider is offered once a reference
303
- * arrives. Until then an account with other methods shows those; one
304
- * whose only way in is the provider waits for it, and is told to try
305
- * again when none could be had.
306
- * - `null`: the page can never hold one (an SDK that predates the
307
- * reference opened it), so the provider is never offered: such a
308
- * sign-in opens no hub session, and its lost result could recover
309
- * another person's.
310
- * - Omitted: the provider is offered only when the page says it completes
311
- * in its own window (`completesInWindow`); never for a page that predates
312
- * the reference, whatever its window.
313
- */
314
- signinRef?: string | null | (() => Promise<string | null>);
315
- /**
316
- * The sign-in completes in this window (internal): set by the SparkVault
317
- * hosted sign-in page, which finishes an authorization request where it
318
- * runs (an authorization code to the relying party, or a simple-mode
319
- * redirect) and never hands its result to an opener. No recovery ever
320
- * stands in for that result, so the page offers the account's own identity
321
- * provider without a reference, in a popup too. Ignored when `signinRef`
322
- * is given.
323
- */
324
- completesInWindow?: boolean;
325
- /** Called when user cancels (if omitted, uses server-configured redirect) */
326
- onCancel?: () => void;
327
- /** Called when verification completes (if omitted, uses server-configured redirect) */
328
- onSuccess?: (result: VerifyResult) => void;
329
- /** Called on error (if omitted, uses server-configured redirect) */
330
- onError?: (error: Error) => void;
331
- }
332
- /** Options for attach() - binds verification to element clicks */
333
- interface AttachOptions {
334
- /** Pre-fill email address */
335
- email?: string;
336
- /** Pre-fill phone number in E.164 format (see `VerifyOptions.phone`) */
337
- phone?: string;
338
- /** Auth context for OIDC/simple mode flows */
339
- authContext?: AuthContext;
340
- /** `'select_account'` always shows the account chooser (see `VerifyOptions.prompt`) */
341
- prompt?: 'select_account';
342
- /** `'federation'` starts with the account's own identity provider (see `VerifyOptions.method`) */
343
- method?: 'federation';
344
- /** The identity types the sign-in may produce (see `VerifyOptions.identityTypes`) */
345
- identityTypes?: SigninIdentityType[];
346
- /** Called when user cancels */
347
- onCancel?: () => void;
348
- /** Called when verification completes */
349
- onSuccess?: (result: VerifyResult) => void;
350
- /** Called on error */
351
- onError?: (error: Error) => void;
352
- }
353
- /**
354
- * A server-decided post-login nudge. Computed once per login (default mode);
355
- * clients render the steps they support, in order, before completing.
356
- */
357
- type Recommendation = {
358
- type: 'passkey';
359
- } | {
360
- type: 'backup_identifier';
361
- missingType: 'email' | 'phone';
362
- };
363
- /** A self-service screen in the auth.sv Identity portal. */
364
- type PortalSection = 'home' | 'identity' | 'security' | 'sessions' | 'sites';
365
- /** Options for building an auth.sv portal deep link (`portalUrl()`). */
366
- interface PortalUrlOptions {
367
- /** Which portal screen to open. Defaults to `'home'`. */
368
- section?: PortalSection;
369
- /**
370
- * Focus a specific connected site on the Sites screen (an `acc_…` account ID).
371
- * When `section` is `'sites'` and `site` is omitted, defaults to this SDK's
372
- * own `accountId` (i.e. "manage this site"). Ignored for other sections.
373
- */
374
- site?: string;
375
- }
376
- interface VerifyResult {
377
- /** Signed JWT token */
378
- token: string;
379
- /** Verified identifier used for audit and user-facing attribution; passkey credentials route by SVID. */
380
- identity: string;
381
- /** Type of identifier returned with the verification result. */
382
- identityType: VerifiedIdentityType;
383
- /** Canonical SparkVault ID */
384
- svid?: string;
385
- /** Managed SparkVault Identity session ID */
386
- sessionId?: string;
387
- /** Managed-session refresh token, when the flow returns one */
388
- refreshToken?: string;
389
- /** Redirect URL (only present for OIDC/simple mode flows) */
390
- redirect?: string;
391
- /** Ordered post-login nudges (default-mode logins only). */
392
- recommendations?: Recommendation[];
393
- }
394
- /**
395
- * Options for `signIn()`: the customer-facing popup sign-in. The popup owns its
396
- * rendering, so there is no inline `target`/`renderMode`/`chrome`/`signinRef`/
397
- * `completesInWindow` here; those are internal to the SparkVault-hosted
398
- * sign-in surfaces.
399
- */
400
- type SignInOptions = Omit<VerifyOptions, 'target' | 'renderMode' | 'chrome' | 'signinRef' | 'completesInWindow'>;
401
- /**
402
- * Options for the SparkVault sign-in page's own render (internal): the flow's
403
- * options, with the page's restriction as its URL's `identity_types` spells
404
- * it, unread. The flow reads it (app-sdk readSigninIdentityTypes): absent is
405
- * no restriction, and a spelling it cannot read shows as an error, never as
406
- * no restriction.
407
- */
408
- type RenderOptions = Omit<VerifyOptions, 'identityTypes'> & {
409
- target: string | HTMLElement;
410
- identityTypes?: string | null;
411
- };
412
- /** The verified identity returned by `signIn()`. */
413
- type SignInResult = VerifyResult;
414
- /**
415
- * Options for `handleRedirectResult()`. Call once on every page load. It
416
- * redeems a returned sign-in code (from `flow: 'redirect'` or the silent SSO
417
- * self-heal) and, when a popup result was lost, triggers that self-heal. It
418
- * no-ops otherwise.
419
- */
420
- interface RedirectResultOptions {
421
- /** Called with the verified result when a returned sign-in code is redeemed */
422
- onSuccess?: (result: VerifyResult) => void;
423
- /** Called when redeeming a returned sign-in code failed */
424
- onError?: (error: Error) => void;
425
- /** Called when the person cancelled sign-in on the hosted page */
426
- onCancel?: () => void;
427
- }
428
- interface TokenClaims {
429
- /** Issuer */
430
- iss: string;
431
- /** Subject. Managed Identity tokens use the SVID. */
432
- sub: string;
433
- /** Audience (account ID for simple tokens, client ID for OIDC) */
434
- aud: string;
435
- /** Expiry (Unix seconds) */
436
- exp: number;
437
- /** Issued at (Unix seconds) */
438
- iat: number;
439
- /** Unique token ID for replay protection */
440
- jti?: string;
441
- /** Verified identifier used for audit and user-facing attribution; passkey credentials route by SVID. */
442
- identity: string;
443
- /** Identifier type */
444
- identity_type: VerifiedIdentityType;
445
- /** Canonical SparkVault ID */
446
- svid?: string;
447
- /** Managed SparkVault Identity session ID */
448
- session_id?: string;
449
- /** Verification timestamp (Unix seconds) */
450
- verified_at: number;
451
- /** Authentication method used */
452
- method: string;
453
- /**
454
- * Only on a `federated` sign-in whose provider asserted an email: the
455
- * address as the provider sent it. The provider may assert an address it
456
- * never verified, so it is no identifier: key people by `sub`.
457
- */
458
- email?: string;
459
- /** Only beside `email`: true only when the provider said it verified the address. */
460
- email_verified?: boolean;
461
- /**
462
- * The person's public avatar URL (my.auth.sv), present only when they have a visible
463
- * avatar. The URL always renders an image: their photo, or a neutral placeholder.
464
- */
465
- picture?: string;
466
- }
467
- /** Method ID returned by config endpoint */
468
- type MethodId = 'otp_email' | 'otp_sms' | 'otp_voice' | 'passkey' | 'sparklink' | 'social_google' | 'social_apple' | 'social_microsoft' | 'social_github' | 'social_facebook' | 'social_linkedin' | 'federation';
469
-
470
- /**
471
- * Identity Module
472
- *
473
- * Passwordless sign-in through the first-party SparkVault popup.
474
- * Supports passkey, OTP, SparkLink, social authentication, and the account's
475
- * own identity provider.
476
- *
477
- * @example Programmatic
478
- * const result = await sv.products.identity.signIn();
479
- *
480
- * @example Attached to clicks
481
- * sv.products.identity.attach('.login-btn');
482
- */
483
-
484
- declare class IdentityModule {
485
- private readonly config;
486
- private readonly api;
487
- private renderer;
488
- private launcher;
489
- private pendingSignIn;
490
- constructor(config: ResolvedConfig);
491
- /**
492
- * Build a deep link into the person's auth.sv Identity portal, where they
493
- * manage their verified identity, passkeys, sessions, and connected sites
494
- * across every SparkVault-integrated site. Send a signed-in user here to
495
- * self-serve;
496
- * the portal authenticates them with their own SparkVault Identity.
497
- *
498
- * @example Manage this site (block/notifications/etc.)
499
- * window.location.href = sv.products.identity.portalUrl({ section: 'sites' });
500
- *
501
- * @example Open the security screen
502
- * sv.products.identity.portalUrl({ section: 'security' });
503
- *
504
- * @returns An absolute URL on the configured `portalBaseUrl` (default https://auth.sv).
505
- */
506
- portalUrl(options?: PortalUrlOptions): string;
507
- /**
508
- * One-click sign-in through the browser's native FedCM account chooser.
509
- *
510
- * When the person is already signed into SparkVault Identity (carrying the
511
- * SSO hub session on the Identity origin),
512
- * the browser surfaces a "Continue as …" prompt with no popup, redirect, or
513
- * typing. Requires a registered `clientId` in the SDK config and a browser
514
- * with FedCM support: callers should feature-detect with
515
- * `IdentityModule.isFedcmAvailable()` and fall back to `signIn()` otherwise.
516
- *
517
- * @returns the verified result, or `null` when the browser has no FedCM
518
- * support (so the caller can fall back). Throws `UserCancelledError` when
519
- * the browser ends the request without a credential: the person dismissed
520
- * the chooser, or the browser had no SparkVault account to offer (the
521
- * browser reports both alike). Throws `IdentityProviderError`, carrying
522
- * SparkVault's own error code, when SparkVault answered the sign-in with an
523
- * error (`IDENTITY_TYPE_NOT_ALLOWED` for an account of a type
524
- * `identityTypes` does not name).
525
- *
526
- * `identityTypes` restricts the sign-in as `SignInOptions.identityTypes`
527
- * does; a bad value is a ValidationError before anything is asked.
528
- *
529
- * @example
530
- * const result = IdentityModule.isFedcmAvailable()
531
- * ? await sv.products.identity.signInWithFedcm().catch(() => sv.products.identity.signIn())
532
- * : await sv.products.identity.signIn();
533
- */
534
- signInWithFedcm(options?: {
535
- mediation?: 'optional' | 'required' | 'silent';
536
- nonce?: string;
537
- identityTypes?: SigninIdentityType[];
538
- }): Promise<VerifyResult | null>;
539
- /** Whether this browser exposes the FedCM API (`navigator.credentials` + IdentityCredential). */
540
- static isFedcmAvailable(): boolean;
541
- /**
542
- * Sign in through the first-party SparkVault sign-in popup.
543
- *
544
- * This is the single programmatic entry point; `attach()` binds it to element
545
- * clicks. The popup runs the flow top-level on the Identity origin (so
546
- * login's `__Host-` hub cookie is a first-party write and cross-domain SSO
547
- * works) and posts the result back; the promise resolves with it.
548
- *
549
- * Resilience: pair this with `handleRedirectResult()` on page load. If the
550
- * popup's result is ever lost (a mobile browser discards the backgrounded
551
- * opener tab), the next load silently self-heals from the SSO session the
552
- * popup signed in or chose; a sign-in that opened none (the account's own
553
- * identity provider) comes back signed out, to sign in again. `flow:
554
- * 'redirect'` opts a caller out of the popup into a same-tab navigation
555
- * instead.
556
- *
557
- * @example
558
- * const result = await sv.products.identity.signIn();
559
- * // Your backend verifies the token before it grants access; never log it.
560
- * await fetch('/api/auth/login', {
561
- * method: 'POST',
562
- * headers: { 'Content-Type': 'application/json' },
563
- * body: JSON.stringify({ token: result.token }),
564
- * });
565
- */
566
- signIn(options?: SignInOptions): Promise<SignInResult>;
567
- /**
568
- * Core flow runner. Default mode (no `target`) opens the popup; `flow:
569
- * 'redirect'` navigates the tab instead; local mode (`renderMode: 'local'` /
570
- * `target`) renders into the current document and powers the
571
- * SparkVault-hosted sign-in surfaces (see the internal `render`), which
572
- * hands it its restriction as its page's URL spelled it (`identityTypes`)
573
- * and what a round trip to the account's own identity provider returned
574
- * (`federationReturn`). The popup and the redirect carry the restriction
575
- * `options.identityTypes` names, which signIn() validated.
576
- */
577
- private runFlow;
578
- /**
579
- * Attach identity verification to element clicks.
580
- * When any matching element is clicked, opens the verification dialog.
581
- *
582
- * @param selector - CSS selector for elements to attach to
583
- * @param options - Verification options and callbacks
584
- * @returns Cleanup function to remove event listeners
585
- *
586
- * @example
587
- * const cleanup = sv.products.identity.attach('.login-btn', {
588
- * onSuccess: (result) => console.log('Verified:', result.identity)
589
- * });
590
- *
591
- * // Later, remove listeners
592
- * cleanup();
593
- */
594
- attach(selector: string, options?: AttachOptions): () => void;
595
- /**
596
- * Decode an identity token's claims WITHOUT verifying its signature.
597
- *
598
- * This is an UNVERIFIED, client-side decode: it parses the JWT payload and
599
- * sanity-checks structure, `exp`, `iss`, `aud`, and the header `alg` (accepting
600
- * only the algorithms the Identity server signs with, so an unsigned or
601
- * algorithm-confused token cannot masquerade as valid). It does NOT verify the
602
- * signature, so its result MUST NOT be trusted for any authorization decision.
603
- *
604
- * To trust a token (e.g. before keying records by `claims.svid`), verify the
605
- * signature server-side against the Identity JWKS endpoint
606
- * (`https://auth.sparkvault.com/{account_id}/.well-known/jwks.json`), which
607
- * publishes the EdDSA and RS256 keys and selects the verifying key by `kid`.
608
- * See docs/SDK.md.
609
- */
610
- decodeToken(token: string): TokenClaims;
611
- /**
612
- * Complete a sign-in on page load: the return leg of `signIn()`. Call once
613
- * on every page load; it resolves `null` when there is nothing to do.
614
- *
615
- * It handles two cases:
616
- * 1. A one-time code is in the URL fragment (`#sv_code=…`): the popup's
617
- * result was lost and self-heal navigated here, or `flow: 'redirect'`
618
- * returned. Redeem it server-side and hand the full result to
619
- * `onSuccess` (and resolve with it).
620
- * 2. A sign-in was in flight but never delivered (a mobile browser
621
- * discarded the backgrounded opener tab, killing the popup's
622
- * postMessage): silently re-mint from the SSO session the popup signed
623
- * in or chose, by navigating this tab through the silent SSO endpoint
624
- * and straight back with a code (case 1 on return). The bounce names
625
- * the sign-in's reference, and the endpoint mints only when the
626
- * session it would mint from carries it. Nothing is shown; with no
627
- * such session (a sign-in that opened none, such as one through the
628
- * account's own identity provider) it comes back logged-out, no oracle.
629
- *
630
- * The code is one-time, PKCE-bound, and origin-locked, never the token. The
631
- * host must still verify `result.token` server-side via the Identity JWKS.
632
- *
633
- * @example Call on page load; sign-in clicks stay unchanged.
634
- * sv.products.identity.handleRedirectResult({
635
- * onSuccess: (result) => createSession(result.token),
636
- * }).catch((error) => showError(error));
637
- */
638
- handleRedirectResult(options?: RedirectResultOptions): Promise<SignInResult | null>;
639
- /** Redeem a returned `#sv_code` (or surface a returned `#sv_error`). */
640
- private consumeHandoffFragment;
641
- /**
642
- * Silently re-mint the sign-in result from the SSO session the popup signed
643
- * in or chose. Navigates this tab through the silent SSO endpoint
644
- * (a top-level GET, so the `SameSite=Lax` hub cookie rides along) which,
645
- * PKCE-bound, returns a one-time code in the fragment, handled by case 1 on
646
- * return. No-op (stays put) if session storage or WebCrypto is unavailable,
647
- * so a degraded environment simply never recovers rather than erroring. The
648
- * bounce's PKCE verifier and state are a draw from the Identity origin
649
- * (`drawAuthorizationValues`): a draw that fails (the origin unreachable, a
650
- * malformed answer) rejects `handleRedirectResult()` with that error, and the
651
- * page stays put.
652
- */
653
- private startRecoveryBounce;
654
- /**
655
- * Navigate this tab to the interactive sign-in page: explicit `flow:
656
- * 'redirect'`, or a popup whose handle COOP severed. Plain sign-in carries
657
- * redirect_uri + state + PKCE challenge and returns via the fragment code;
658
- * OIDC/simple modes navigate without them (their server-rendered pages drive
659
- * the server-validated redirect back). Either carries the severed popup's
660
- * reference; a redirect draws none of its own.
661
- *
662
- * The return leg is armed first: the check that the sign-in still runs and
663
- * the pending marker's removal then share one turn with the navigation, so
664
- * no sign-in can start or end between them.
665
- *
666
- * @param severed - The popup sign-in whose severed popup this continues,
667
- * with the reference its marker holds for that popup (null for none), or
668
- * null for an explicit redirect, which carries none
669
- * @returns false when the return leg cannot be armed (no session storage or
670
- * WebCrypto), so the caller surfaces an actionable error instead of a
671
- * silent dead-end, or when the severed popup's sign-in ended meanwhile.
672
- */
673
- private startRedirectFlow;
674
- /**
675
- * Arm the PKCE + state return leg of a handoff navigation and return what
676
- * the navigation carries for it (redirect_uri = this page, per
677
- * `currentPageReturnUrl`). Returns null when session storage or WebCrypto is
678
- * unavailable so callers can degrade.
679
- */
680
- private armHandoffReturn;
681
- /**
682
- * Consume the pending marker: the marker once (then cleared) while a recent
683
- * sign-in is still awaiting its result, else null. Its `hint` is the
684
- * identifier that sign-in carried, for the recovery bounce's `login_hint`,
685
- * and its `ref` the sign-in's reference, when the marker holds one.
686
- */
687
- private consumeSignInPending;
688
- /** Close the popup sign-in's launcher, ending the sign-in it ran. */
689
- private closeLauncher;
690
- /** Remove the result fragment from the URL bar (and history entry). */
691
- private clearUrlFragment;
692
- /** Drop the one-shot PKCE state/verifier a bounce staged. */
693
- private clearOneShotAuthState;
694
- /**
695
- * Complete a social round trip, or one through the account's own identity
696
- * provider, that returned to the sign-in page as `#token=…&state=…`. Only
697
- * `render()`, the Identity-origin sign-in page,
698
- * reads it: no SDK flow returns a `#token` to a site (a site's results arrive
699
- * by the popup's postMessage, FedCM, or a PKCE-bound `#sv_code`), so on a site
700
- * it could only be someone else's token, or the site's own direct
701
- * token-redirect result.
702
- */
703
- private consumeRedirectResult;
704
- /**
705
- * Read a refusal a round trip through the account's own identity provider
706
- * returned to the sign-in page (`#error=…&state=…`, see federation-flow.ts).
707
- * Such a fragment is consumed exactly once, with the state it answers,
708
- * whatever it holds. Null for any other fragment, and for a refusal whose
709
- * state is not the one this browser stored before it left: an answer to no
710
- * sign-in this browser started, which the page ignores.
711
- */
712
- private consumeFederationReturn;
713
- /**
714
- * Close the identity dialog/inline UI if open.
715
- *
716
- * Tears down whichever surface is active: the dialog launcher (default dialog
717
- * mode) or the local renderer (inline / local mode).
718
- */
719
- close(): void;
720
- /**
721
- * Whether the preloaded config has already settled as a *permanent* failure
722
- * the popup can't surface (origin not allowed, or product not configured).
723
- * Used to skip the launcher and show the error dialog in-page immediately.
724
- * Returns false (proceed to the launcher) when config is not preloaded,
725
- * still in flight (raced against a short timeout so the common path is never
726
- * delayed), resolved, or failed only transiently (the launcher surfaces a
727
- * transient failure in its own dialog).
728
- */
729
- private preloadedConfigPermanentlyFailed;
730
- /**
731
- * The inline container for an embedded render. Bare chrome: the host page
732
- * owns logo + footer + background, so the container drops its own surface
733
- * and the SparkVault footer.
734
- */
735
- private createInlineContainer;
736
- /**
737
- * Render the flow into a page element instead of a popup.
738
- *
739
- * A social login, or one through the account's own identity provider,
740
- * started here returns to this same page with its result in the fragment,
741
- * so a returned `#token` is completed first (see `consumeRedirectResult`)
742
- * instead of starting the flow again, and a returned refusal of the
743
- * account's own identity provider is handed to the flow it starts (see
744
- * `consumeFederationReturn`).
745
- *
746
- * The page hands its restriction as its URL spelled it (`identityTypes`),
747
- * which the flow reads here: a spelling it cannot read shows as an error.
748
- *
749
- * @internal Used only by the SparkVault-hosted sign-in popup and hosted login
750
- * page (which own their chrome and pass `renderMode: 'local'`). Customer
751
- * integrations have no inline mode; use `signIn()` / `attach()`.
752
- */
753
- render(options: RenderOptions): Promise<VerifyResult>;
754
- }
755
-
756
94
  /** Named Notify projects owned by one company and funded by its shared wallet. */
757
95
  type NotifyProjectStatus = 'active' | 'archived';
758
96
  interface NotifyProjectBilling {
@@ -5339,130 +4677,6 @@ interface FetchedDownload {
5339
4677
  */
5340
4678
  declare function fetchDownload(url: string, options?: FetchDownloadOptions): Promise<FetchedDownload>;
5341
4679
 
5342
- /**
5343
- * SparkVault SDK Error Types
5344
- */
5345
- declare class SparkVaultError extends Error {
5346
- readonly code: string;
5347
- readonly statusCode?: number;
5348
- readonly details?: Record<string, unknown>;
5349
- /**
5350
- * The answer's `Retry-After`, in ms from the answer, read by the platform's
5351
- * one parser (`parseRetryAfterMs`; RFC 9110 §10.2.3: delay-seconds or an
5352
- * HTTP-date): the earliest a next attempt can expect another answer, which
5353
- * every retry the SDK makes waits out as a floor. Null when the answer
5354
- * carried none the parser could read, or no answer arrived.
5355
- */
5356
- readonly retryAfterMs: number | null;
5357
- /**
5358
- * The machine-readable code the API answered with (`INVALID_CURSOR`,
5359
- * `LICENSE_REQUIRED`), on every error the SDK's API client builds from a
5360
- * refused call of a data-plane module (`vaults`, `ingots`, `folders`,
5361
- * `sparks`, `entropy`, `notify`, `products.notify`); `api_error` when the
5362
- * answer named none (a gateway's HTML). A typed refusal's `code` names its
5363
- * class of failure: one per 400 (`validation_error`), two per 401
5364
- * (`authentication_error`, `UNAUTHORIZED`), 402 (`PLAN_REQUIRED`,
5365
- * `QUOTA_EXCEEDED`, `USAGE_CREDITS_EXHAUSTED`) and 403 (`authorization_error`;
5366
- * http.ts createErrorFromResponse), so this is what tells apart two
5367
- * refusals that share a code.
5368
- * Undefined on an error the SDK raised itself, on the Identity product's
5369
- * errors (`products.identity`, whose `code` is the service's own), and on the
5370
- * errors of an upload's transfer (`UploadApiError`, which names Core's code in
5371
- * its `code` or `details.coreCode`, a staging call Core refused for good among
5372
- * them) and of a download (`download_failed`, its status alone).
5373
- */
5374
- readonly serviceCode?: string;
5375
- constructor(message: string, code: string, statusCode?: number, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5376
- }
5377
- declare class AuthenticationError extends SparkVaultError {
5378
- constructor(message: string, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5379
- }
5380
- /**
5381
- * A key the request presents was refused (401 UNAUTHORIZED): the DVAK an
5382
- * unseal names is invalid or revoked. The caller's own credential stood, so
5383
- * this is no ended session, and signing in again changes nothing: present a
5384
- * live key. Every other 401 is an {@link AuthenticationError}.
5385
- */
5386
- declare class UnauthorizedError extends SparkVaultError {
5387
- constructor(message: string, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5388
- }
5389
- declare class AuthorizationError extends SparkVaultError {
5390
- constructor(message: string, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5391
- }
5392
- declare class ValidationError extends SparkVaultError {
5393
- constructor(message: string, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5394
- }
5395
- /**
5396
- * The pooled-capacity resource a quota gate refers to. Only the byte pools
5397
- * hard-gate: licenses are assigned per member, never drawn from a pool
5398
- * (inviting and licensing are never quota-gated), and Identity soft-gates
5399
- * through its own path.
5400
- */
5401
- type QuotaResource = 'storage' | 'bandwidth';
5402
- /**
5403
- * Plan required gate (402 PLAN_REQUIRED): the account has no active
5404
- * subscription and attempted a billable/create action. Surface a subscribe CTA
5405
- * to admins, or "ask your account admin" to members.
5406
- */
5407
- declare class PlanRequiredError extends SparkVaultError {
5408
- constructor(message: string, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5409
- }
5410
- /**
5411
- * Prepaid usage is exhausted (402 USAGE_CREDITS_EXHAUSTED). The subscription
5412
- * can still be active: an admin replenishes the shared usage-credit wallet.
5413
- */
5414
- declare class UsageCreditsExhaustedError extends SparkVaultError {
5415
- constructor(message: string, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5416
- }
5417
- /** A payment reversal requires billing review; buying more credits cannot clear it. */
5418
- declare class UsageCreditFundingReviewError extends SparkVaultError {
5419
- constructor(message: string, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5420
- }
5421
- /**
5422
- * Quota exceeded gate (402 QUOTA_EXCEEDED): a pooled-capacity limit is
5423
- * exhausted. `resource` identifies which pool so callers can point the CTA at
5424
- * the right capacity block.
5425
- */
5426
- declare class QuotaExceededError extends SparkVaultError {
5427
- readonly resource?: QuotaResource;
5428
- constructor(message: string, details?: Record<string, unknown>, retryAfterMs?: number | null, serviceCode?: string);
5429
- }
5430
- declare class NetworkError extends SparkVaultError {
5431
- constructor(message: string, details?: Record<string, unknown>);
5432
- }
5433
- declare class TimeoutError extends SparkVaultError {
5434
- constructor(message?: string);
5435
- }
5436
- declare class UserCancelledError extends SparkVaultError {
5437
- constructor(message?: string);
5438
- }
5439
- /**
5440
- * The identity provider answered a FedCM sign-in with an error of its own
5441
- * (the browser's `IdentityCredentialError`), after the browser showed the
5442
- * person its error dialog: the request reached the provider, which refused or
5443
- * failed it, so it is no cancel. `code` is the provider's answer
5444
- * (`server_error`, `access_denied`, ...).
5445
- */
5446
- declare class IdentityProviderError extends SparkVaultError {
5447
- constructor(code: string);
5448
- }
5449
- declare class PopupBlockedError extends SparkVaultError {
5450
- constructor();
5451
- }
5452
- /**
5453
- * The popup opened but its window handle went dead before the page ever
5454
- * pinged back: the host page's Cross-Origin-Opener-Policy severed it (a host
5455
- * page serving `COOP: same-origin` detaches any cross-origin popup: the popup
5456
- * loses `window.opener`, the opener's handle reports `closed`). postMessage
5457
- * can never work in this state, so retrying the popup is futile. Identity
5458
- * sign-in falls back to the redirect flow (popup-launcher.ts); the help desk
5459
- * widget's sign-in, which has none, passes a message that tells the person
5460
- * what to do (help-desk/widget-identity.ts).
5461
- */
5462
- declare class PopupSeveredError extends SparkVaultError {
5463
- constructor(message?: string);
5464
- }
5465
-
5466
4680
  /**
5467
4681
  * Upload API
5468
4682
  *
@@ -6628,5 +5842,5 @@ declare global {
6628
5842
  }
6629
5843
  }
6630
5844
 
6631
- export { AuthenticationError, AuthorizationError, EntropyModule, FoldersModule, HelpDeskClient, HelpDeskModule, IdentityModule, IdentityProviderError, IngotsModule, MessagingModule, NAME_CONFLICT_POLICIES, NOTIFY_PRESETS, NetworkError, NotifyModule, NotifyProductModule, NotifyProjectsModule, PlanRequiredError, PopupBlockedError, PopupSeveredError, ProductsModule, QuotaExceededError, SparkVault, SparkVaultError, SparksModule, StructuredIngotTypesModule, StructuredIngotsModule, TimeoutError, UnauthorizedError, UsageCreditFundingReviewError, UsageCreditsExhaustedError, UserCancelledError, ValidationError, VaultsModule, buildNotifyPresetSend, SparkVault as default, fetchDownload, isReceivedUploadFailure, logger, setDebugMode };
6632
- export type { AccessLogRetention, AccessLogsOptions, BatchGetStructuredIngotsOptions, CreateFolderOptions, CreateMessagingConversationOptions, CreateNotifyProjectOptions, CreateNotifySendOptions, CreateSparkOptions, CreateStructuredIngotOptions, CreateStructuredTypeOptions, CreateUploadOptions, CreateVaultOptions, CreatedIngot, CreatedSpark, DeleteIngotOptions, DeleteStructuredIngotOptions, DownloadIngotOptions, EntropyFormat, EntropyResult, FetchDownloadOptions, FetchedDownload, Folder, FolderBreadcrumbItem, FolderContents, FolderPage, GenerateEntropyOptions, GetStructuredIngotOptions, HealthCheckOptions, HealthCheckResult, HelpDeskAttachmentDownload, HelpDeskAttachmentInput, HelpDeskAttachmentUpload, HelpDeskCarriedComposition, HelpDeskConnectOptions, HelpDeskCreateTicketOptions, HelpDeskCustomer, HelpDeskCustomerPatch, HelpDeskDesk, HelpDeskDraft, HelpDeskEvent, HelpDeskExternalChallenge, HelpDeskExternalIdentity, HelpDeskFormArrival, HelpDeskFormHandle, HelpDeskFormOptions, HelpDeskFormState, HelpDeskIdentityRequest, HelpDeskListTicketsOptions, HelpDeskMountFormOptions, HelpDeskOAuthIdentity, HelpDeskOpenFormOptions, HelpDeskPinChallenge, HelpDeskReplyCreated, HelpDeskReplyOptions, HelpDeskRequestContext, HelpDeskSession, HelpDeskSessionChange, HelpDeskSupportHandle, HelpDeskSupportLauncherOptions, HelpDeskSupportOpenOptions, HelpDeskSupportOptions, HelpDeskSupportStage, HelpDeskSupportState, HelpDeskTicket, HelpDeskTicketCreated, HelpDeskTicketDetail, HelpDeskTicketList, HelpDeskTimeline, HelpDeskVerifyPinOptions, HelpDeskWebsiteAccountReturn, HelpDeskWidgetFormIdentity, HelpDeskWidgetIdentityChallenge, HelpDeskWidgetIdentityOptions, HelpDeskWidgetIdentitySession, AttachOptions as IdentityAttachOptions, ImportStructuredIngotsOptions, Ingot, IngotAccessLog, IngotAccessLogPage, IngotDownload, IngotDownloadLink, IngotHistory, IngotInvitation, IngotInvite, IngotPage, IngotSharingConfig, IngotUpload, IngotVersion, IngotVersionDownloadLink, InitiateMessagingAttachmentOptions, ListContentsOptions, ListFoldersOptions, ListIngotsOptions, ListMessagingInboxOptions, ListNotificationsOptions, ListNotificationsResponse, ListNotifyInboxOptions, ListNotifyInboxResponse, ListNotifyProjectsResponse, ListNotifyReceiptsOptions, ListNotifyReceiptsResponse, ListNotifySendsOptions, ListNotifySendsResponse, ListSparksOptions, MarkAllNotificationsStateOptions, MarkAllNotificationsStateResponse, MarkAllReadResult, MarkNotificationStateOptions, MarkNotificationStateResponse, MarkNotifyInboxAllOptions, MarkNotifyInboxAllResponse, MarkNotifyInboxStateOptions, MarkNotifyInboxStateResponse, MessagingAttachment, MessagingAttachmentDownload, MessagingAttachmentUpload, MessagingContentMessage, MessagingConversation, MessagingConversationCreated, MessagingConversationSettings, MessagingIdentity, MessagingInboxCursor, MessagingInboxEntry, MessagingInboxPage, MessagingInviteResult, MessagingMessage, MessagingMessageReceipt, MessagingParticipant, MessagingParticipantInput, MessagingReadResult, MessagingRecalledMessage, MessagingReceiptToken, MessagingRecipientIdentity, MessagingSendResult, MessagingUnavailableMessage, NameConflictPolicy, NotificationBulkMarkState, NotificationInboxState, NotificationMarkState, NotificationRow, NotificationSender, NotifyCategory, NotifyChannel, NotifyConfig, NotifyConfigCategory, NotifyConfigDelivery, NotifyConfigDeliveryPatch, NotifyConfigDestinations, NotifyConfigDestinationsPatch, NotifyConfigEvents, NotifyConfigEventsRead, NotifyConfigHistory, NotifyConfigOverrides, NotifyConfigPatch, NotifyConfigRealtimeFallbackDelay, NotifyConfigRefusalReason, NotifyConfigReliability, NotifyConfigResponse, NotifyConfigSecurity, NotifyDeliveryMode, NotifyDestinationFailureReason, NotifyDestinationKind, NotifyDestinationReason, NotifyDestinationSkipReason, NotifyDestinationState, NotifyDestinationTestReason, NotifyDestinationTestResult, NotifyDestinationTransportReason, NotifyEscalation, NotifyInboxBulkMarkState, NotifyInboxMarkState, NotifyInboxRow, NotifyInboxView, NotifyIngotRef, NotifyInteraction, NotifyPreset, NotifyPresetCategory, NotifyPresetName, NotifyPresetSendOptions, NotifyProject, NotifyProjectBilling, NotifyProjectStatus, NotifyProjectUsage, NotifyRecallMode, NotifyReceipt, NotifyReceiptEventType, NotifyRecipient, NotifyRecipientRef, NotifyRecipientState, NotifyReportableVerificationLevel, NotifySendContent, NotifySendPolicy, NotifySendReceipt, NotifySendReceiptsResponse, NotifySendResult, NotifySendState, NotifySendStatus, NotifySendStatusCounts, NotifySendStatusDestination, NotifySendStatusRecipient, NotifySendSummary, NotifySendSummaryDestination, NotifySlackDestination, NotifySlackDestinationRead, NotifySuppressionReason, NotifyTeamsDestination, NotifyTeamsDestinationRead, NotifyVerificationLevel, NotifyWebhookDestination, NotifyWebhookDestinationRead, PatchStructuredIngotOptions, PortableStructuredIngot, PortableStructuredType, PublishStructuredTypeOptions, QuotaResource, ReadMessagingConversationOptions, RecallNotifySendOptions, RecallNotifySendResponse, RegisterWebPushResponse, ReplaceIngotOptions, RestoreStructuredIngotOptions, ResumeUploadOptions, ScheduledVaultDeletion, SearchIngotsOptions, SendMessagingMessageOptions, SendUploadOptions, ShareSparkOptions, SignInOptions, SignInResult, SigninIdentityType, Spark, SparkInviteResend, SparkLinkActionOptions, SparkPage, SparkShare, SparkSummary, SparkVaultConfig, SparkVisibility, StartedVaultDeletion, StructuredAccountActivity, StructuredActivity, StructuredActivityOptions, StructuredActivityPeriod, StructuredActivityTotals, StructuredActivityTotalsWire, StructuredActivityWire, StructuredBinaryPath, StructuredExportOutcome, StructuredImportOutcome, StructuredIngot, StructuredIngotHistory, StructuredIngotMutation, StructuredIngotPrecondition, StructuredIngotSummary, StructuredIngotSummaryWire, StructuredIngotVersion, StructuredIngotWire, StructuredIterateOptions, StructuredJsonValue, StructuredMutationWire, StructuredOutcome, StructuredPage, StructuredPageOptions, StructuredPageWire, StructuredReadOutcome, StructuredTypeCreation, StructuredTypeDefinition, StructuredTypeDefinitionWire, StructuredTypePin, StructuredTypePinWire, StructuredTypeSummary, StructuredTypeSummaryWire, StructuredTypeTransform, StructuredValues, StructuredVaultActivity, SubscribeWebPushOptions, SubscribeWebPushResult, SubscribeWebPushStatus, TokenClaims, UnreachedAdmin, UnreadCountResponse, UnsealVaultOptions, UnsealedVault, UnsubscribeWebPushResponse, UpdateFolderOptions, UpdateIngotSharingOptions, UpdateNotifyProjectOptions, UpdateVaultUploadOptions, UpdatedVault, UploadAttachOptions, UploadBranding, UploadEnd, UploadIngotOptions, UploadOptions, UploadProgress, UploadResult, UploadSession, Vault, VaultDetail, VaultLifecycle, VaultResealDefaults, VaultResealSettings, VaultResealSettingsResult, VaultSessionExtension, VaultSessionTiming, VaultSharingConfig, VaultSharingOptions, VaultSummary, VaultUploadConfig, VaultUploadSettings, VerifyOptions, VerifyResult, WebPushKeyResponse, WebPushStatus, WebPushStatusOptions, WebPushStatusResult, WebPushSubscriptionInput };
5845
+ export { EntropyModule, FoldersModule, HelpDeskClient, HelpDeskModule, IdentityModule, IngotsModule, MessagingModule, NAME_CONFLICT_POLICIES, NOTIFY_PRESETS, NotifyModule, NotifyProductModule, NotifyProjectsModule, ProductsModule, SparkVault, SparkVaultConfig, SparksModule, StructuredIngotTypesModule, StructuredIngotsModule, VaultsModule, buildNotifyPresetSend, SparkVault as default, fetchDownload, isReceivedUploadFailure, logger, setDebugMode };
5846
+ export type { AccessLogRetention, AccessLogsOptions, BatchGetStructuredIngotsOptions, CreateFolderOptions, CreateMessagingConversationOptions, CreateNotifyProjectOptions, CreateNotifySendOptions, CreateSparkOptions, CreateStructuredIngotOptions, CreateStructuredTypeOptions, CreateUploadOptions, CreateVaultOptions, CreatedIngot, CreatedSpark, DeleteIngotOptions, DeleteStructuredIngotOptions, DownloadIngotOptions, EntropyFormat, EntropyResult, FetchDownloadOptions, FetchedDownload, Folder, FolderBreadcrumbItem, FolderContents, FolderPage, GenerateEntropyOptions, GetStructuredIngotOptions, HealthCheckOptions, HealthCheckResult, HelpDeskAttachmentDownload, HelpDeskAttachmentInput, HelpDeskAttachmentUpload, HelpDeskCarriedComposition, HelpDeskConnectOptions, HelpDeskCreateTicketOptions, HelpDeskCustomer, HelpDeskCustomerPatch, HelpDeskDesk, HelpDeskDraft, HelpDeskEvent, HelpDeskExternalChallenge, HelpDeskExternalIdentity, HelpDeskFormArrival, HelpDeskFormHandle, HelpDeskFormOptions, HelpDeskFormState, HelpDeskIdentityRequest, HelpDeskListTicketsOptions, HelpDeskMountFormOptions, HelpDeskOAuthIdentity, HelpDeskOpenFormOptions, HelpDeskPinChallenge, HelpDeskReplyCreated, HelpDeskReplyOptions, HelpDeskRequestContext, HelpDeskSession, HelpDeskSessionChange, HelpDeskSupportHandle, HelpDeskSupportLauncherOptions, HelpDeskSupportOpenOptions, HelpDeskSupportOptions, HelpDeskSupportStage, HelpDeskSupportState, HelpDeskTicket, HelpDeskTicketCreated, HelpDeskTicketDetail, HelpDeskTicketList, HelpDeskTimeline, HelpDeskVerifyPinOptions, HelpDeskWebsiteAccountReturn, HelpDeskWidgetFormIdentity, HelpDeskWidgetIdentityChallenge, HelpDeskWidgetIdentityOptions, HelpDeskWidgetIdentitySession, ImportStructuredIngotsOptions, Ingot, IngotAccessLog, IngotAccessLogPage, IngotDownload, IngotDownloadLink, IngotHistory, IngotInvitation, IngotInvite, IngotPage, IngotSharingConfig, IngotUpload, IngotVersion, IngotVersionDownloadLink, InitiateMessagingAttachmentOptions, ListContentsOptions, ListFoldersOptions, ListIngotsOptions, ListMessagingInboxOptions, ListNotificationsOptions, ListNotificationsResponse, ListNotifyInboxOptions, ListNotifyInboxResponse, ListNotifyProjectsResponse, ListNotifyReceiptsOptions, ListNotifyReceiptsResponse, ListNotifySendsOptions, ListNotifySendsResponse, ListSparksOptions, MarkAllNotificationsStateOptions, MarkAllNotificationsStateResponse, MarkAllReadResult, MarkNotificationStateOptions, MarkNotificationStateResponse, MarkNotifyInboxAllOptions, MarkNotifyInboxAllResponse, MarkNotifyInboxStateOptions, MarkNotifyInboxStateResponse, MessagingAttachment, MessagingAttachmentDownload, MessagingAttachmentUpload, MessagingContentMessage, MessagingConversation, MessagingConversationCreated, MessagingConversationSettings, MessagingIdentity, MessagingInboxCursor, MessagingInboxEntry, MessagingInboxPage, MessagingInviteResult, MessagingMessage, MessagingMessageReceipt, MessagingParticipant, MessagingParticipantInput, MessagingReadResult, MessagingRecalledMessage, MessagingReceiptToken, MessagingRecipientIdentity, MessagingSendResult, MessagingUnavailableMessage, NameConflictPolicy, NotificationBulkMarkState, NotificationInboxState, NotificationMarkState, NotificationRow, NotificationSender, NotifyCategory, NotifyChannel, NotifyConfig, NotifyConfigCategory, NotifyConfigDelivery, NotifyConfigDeliveryPatch, NotifyConfigDestinations, NotifyConfigDestinationsPatch, NotifyConfigEvents, NotifyConfigEventsRead, NotifyConfigHistory, NotifyConfigOverrides, NotifyConfigPatch, NotifyConfigRealtimeFallbackDelay, NotifyConfigRefusalReason, NotifyConfigReliability, NotifyConfigResponse, NotifyConfigSecurity, NotifyDeliveryMode, NotifyDestinationFailureReason, NotifyDestinationKind, NotifyDestinationReason, NotifyDestinationSkipReason, NotifyDestinationState, NotifyDestinationTestReason, NotifyDestinationTestResult, NotifyDestinationTransportReason, NotifyEscalation, NotifyInboxBulkMarkState, NotifyInboxMarkState, NotifyInboxRow, NotifyInboxView, NotifyIngotRef, NotifyInteraction, NotifyPreset, NotifyPresetCategory, NotifyPresetName, NotifyPresetSendOptions, NotifyProject, NotifyProjectBilling, NotifyProjectStatus, NotifyProjectUsage, NotifyRecallMode, NotifyReceipt, NotifyReceiptEventType, NotifyRecipient, NotifyRecipientRef, NotifyRecipientState, NotifyReportableVerificationLevel, NotifySendContent, NotifySendPolicy, NotifySendReceipt, NotifySendReceiptsResponse, NotifySendResult, NotifySendState, NotifySendStatus, NotifySendStatusCounts, NotifySendStatusDestination, NotifySendStatusRecipient, NotifySendSummary, NotifySendSummaryDestination, NotifySlackDestination, NotifySlackDestinationRead, NotifySuppressionReason, NotifyTeamsDestination, NotifyTeamsDestinationRead, NotifyVerificationLevel, NotifyWebhookDestination, NotifyWebhookDestinationRead, PatchStructuredIngotOptions, PortableStructuredIngot, PortableStructuredType, PublishStructuredTypeOptions, ReadMessagingConversationOptions, RecallNotifySendOptions, RecallNotifySendResponse, RegisterWebPushResponse, ReplaceIngotOptions, RestoreStructuredIngotOptions, ResumeUploadOptions, ScheduledVaultDeletion, SearchIngotsOptions, SendMessagingMessageOptions, SendUploadOptions, ShareSparkOptions, Spark, SparkInviteResend, SparkLinkActionOptions, SparkPage, SparkShare, SparkSummary, SparkVisibility, StartedVaultDeletion, StructuredAccountActivity, StructuredActivity, StructuredActivityOptions, StructuredActivityPeriod, StructuredActivityTotals, StructuredActivityTotalsWire, StructuredActivityWire, StructuredBinaryPath, StructuredExportOutcome, StructuredImportOutcome, StructuredIngot, StructuredIngotHistory, StructuredIngotMutation, StructuredIngotPrecondition, StructuredIngotSummary, StructuredIngotSummaryWire, StructuredIngotVersion, StructuredIngotWire, StructuredIterateOptions, StructuredJsonValue, StructuredMutationWire, StructuredOutcome, StructuredPage, StructuredPageOptions, StructuredPageWire, StructuredReadOutcome, StructuredTypeCreation, StructuredTypeDefinition, StructuredTypeDefinitionWire, StructuredTypePin, StructuredTypePinWire, StructuredTypeSummary, StructuredTypeSummaryWire, StructuredTypeTransform, StructuredValues, StructuredVaultActivity, SubscribeWebPushOptions, SubscribeWebPushResult, SubscribeWebPushStatus, UnreachedAdmin, UnreadCountResponse, UnsealVaultOptions, UnsealedVault, UnsubscribeWebPushResponse, UpdateFolderOptions, UpdateIngotSharingOptions, UpdateNotifyProjectOptions, UpdateVaultUploadOptions, UpdatedVault, UploadAttachOptions, UploadBranding, UploadEnd, UploadIngotOptions, UploadOptions, UploadProgress, UploadResult, UploadSession, Vault, VaultDetail, VaultLifecycle, VaultResealDefaults, VaultResealSettings, VaultResealSettingsResult, VaultSessionExtension, VaultSharingConfig, VaultSharingOptions, VaultSummary, VaultUploadConfig, VaultUploadSettings, WebPushKeyResponse, WebPushStatus, WebPushStatusOptions, WebPushStatusResult, WebPushSubscriptionInput };