@sparkvault/sdk-js 15.3.3 → 15.4.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.
@@ -0,0 +1,2 @@
1
+ /** The original desk uses its account ID; additional desks have their own ID. */
2
+ export declare function validHelpDeskId(value: unknown): value is string;
@@ -23,6 +23,8 @@ export interface HelpDeskExternalIdentity {
23
23
  export interface HelpDeskConnectOptions {
24
24
  /** The configured help desk hostname, for example support.example.com. */
25
25
  host: string;
26
+ /** Optionally pin the expected desk within this company (hdd_ for a named desk, acc_ for its original desk). */
27
+ deskId?: string;
26
28
  /** A help desk hdt_ bearer provider. Core access tokens and API keys are never used. */
27
29
  getSessionToken?: () => string | null | Promise<string | null>;
28
30
  /** Obtain a purpose-specific JWT from the signed-in company's backend. No customer consent is shown. */
@@ -33,9 +35,13 @@ export interface HelpDeskConnectOptions {
33
35
  export interface HelpDeskDesk {
34
36
  kind: 'desk';
35
37
  desk_id: string;
38
+ /** Owning company. Required in named-desk discovery; legacy desks may omit it. */
39
+ account_id?: string;
36
40
  handle: string;
37
41
  canonical_host: string;
38
42
  sending_host: string;
43
+ /** Configured contact/PIN sender, independent of the portal's custom domain. */
44
+ contact_email?: string;
39
45
  organization_name: string | null;
40
46
  branding: {
41
47
  color: string | null;
@@ -24,4 +24,4 @@ export interface HelpDeskWidgetIdentitySession extends HelpDeskSession {
24
24
  };
25
25
  }
26
26
  /** Open synchronously inside the user's gesture, before preparing the server challenge. */
27
- export declare function openWidgetIdentity(options: HelpDeskWidgetIdentityOptions, prepare: () => Promise<HelpDeskWidgetIdentityChallenge>, ready: (challenge: HelpDeskWidgetIdentityChallenge) => Promise<boolean>, redeem: (challenge: HelpDeskWidgetIdentityChallenge, code?: string) => Promise<HelpDeskWidgetIdentitySession>): Promise<HelpDeskWidgetIdentitySession>;
27
+ export declare function openWidgetIdentity(options: HelpDeskWidgetIdentityOptions, prepare: () => Promise<HelpDeskWidgetIdentityChallenge>, ready: (challenge: HelpDeskWidgetIdentityChallenge) => Promise<boolean>, redeem: (challenge: HelpDeskWidgetIdentityChallenge, code?: string) => Promise<HelpDeskWidgetIdentitySession>, deskId: string): Promise<HelpDeskWidgetIdentitySession>;