gdc-sdk-front-ts 2.1.0 → 2.1.2

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.
@@ -1,8 +1,9 @@
1
1
  import type { DeviceAppType, DeviceUserClass } from 'gdc-common-utils-ts/constants';
2
2
  import type { LicenseListSearchState } from 'gdc-common-utils-ts/utils/license-list-search';
3
3
  import type { LicenseOfferSearchState, LicenseOrderSearchState } from 'gdc-common-utils-ts/utils/license-commercial-search';
4
+ import type { IndividualOrganizationLifecycleEditor } from 'gdc-common-utils-ts/utils/individual-organization-lifecycle';
4
5
  import type { IndividualOnboardingDraftInput, IndividualOnboardingDraftResult } from 'gdc-common-utils-ts/models/individual-onboarding';
5
- import type { BundleSearchQuery, CommunicationInput, EmployeeSearchValue, HostLifecycleInput, HostRouteContext, HostedTenantLifecycleInput, OrganizationDidBindingInput, LegalOrganizationOrderInput, PollOptions, SubmitAndPollResult, SubmitPayload } from 'gdc-sdk-core-ts';
6
+ import type { BundleSearchQuery, CommunicationInput, EmployeeSearchValue, HostLifecycleInput, HostRouteContext, HostedTenantLifecycleInput, OrganizationDidBindingInput, LegalOrganizationOrderInput, PollOptions, SmartTokenRequestContract, SubmitAndPollResult, SubmitPayload } from 'gdc-sdk-core-ts';
6
7
  export type FrontRouteContext = {
7
8
  providerDid: string;
8
9
  idToken: string;
@@ -72,16 +73,7 @@ export type FrontEmployeeDeviceActivationRequestInput = {
72
73
  activationCode: string;
73
74
  dcrPayload?: Record<string, unknown>;
74
75
  };
75
- export type FrontSmartTokenRequestInput = {
76
- idToken: string;
77
- scopes: string[];
78
- actorDid?: string;
79
- subjectDid?: string;
80
- clientId?: string;
81
- issuer?: string;
82
- audience?: string;
83
- additionalClaims?: Record<string, unknown>;
84
- };
76
+ export type FrontSmartTokenRequestInput = SmartTokenRequestContract;
85
77
  export type FrontSmartTokenExchangeResult = {
86
78
  status: 'fetched' | 'failed';
87
79
  accessToken?: string;
@@ -106,7 +98,13 @@ export type FrontIndividualOrganizationConfirmOrderInput = {
106
98
  };
107
99
  export type FrontIndividualOrganizationLifecycleInput = {
108
100
  organizationClaims?: Record<string, unknown>;
101
+ individualEditor?: IndividualOrganizationLifecycleEditor;
102
+ /**
103
+ * @deprecated Use `individualEditor`.
104
+ */
105
+ organizationEditor?: IndividualOrganizationLifecycleEditor;
109
106
  resourceId?: string;
107
+ dataType?: string;
110
108
  };
111
109
  export type FrontIndividualMemberLifecycleInput = {
112
110
  memberClaims?: Record<string, unknown>;
@@ -1,9 +1,34 @@
1
+ import { type ProfessionalEmployeeCredentialInput, type ProfessionalSmartVpPayloadInput } from 'gdc-common-utils-ts';
1
2
  import type { PollOptions, SubmitAndPollResult, SubmitPayload } from 'gdc-sdk-core-ts';
2
3
  import { type FrontCommunicationIngestionInput, type FrontGrantProfessionalAccessInput, type FrontGrantProfessionalAccessResult, type FrontRouteContext, type FrontRuntimeClient, type FrontSmartTokenExchangeResult, type FrontSmartTokenRequestInput } from './client-port.js';
3
4
  export declare class ProfessionalSdk {
4
5
  private readonly client;
5
6
  constructor(client: FrontRuntimeClient);
6
7
  requestSmartToken(input: FrontSmartTokenRequestInput): Promise<FrontSmartTokenExchangeResult>;
8
+ /**
9
+ * Returns the normalized public continuity aliases that would be embedded in
10
+ * the professional identity VC for SMART/OpenID4VP flows.
11
+ */
12
+ getIdentitySameAs(input: ProfessionalEmployeeCredentialInput): string[];
13
+ /**
14
+ * Builds the canonical professional identity VC used by the shared SMART VP
15
+ * helpers.
16
+ */
17
+ getIdentityVC(input: ProfessionalEmployeeCredentialInput): Record<string, unknown>;
18
+ /**
19
+ * Builds the canonical professional identity VP payload used by the shared
20
+ * SMART/OpenID4VP helpers.
21
+ */
22
+ buildIdentityVpPayload(input: ProfessionalSmartVpPayloadInput): Record<string, unknown>;
23
+ /**
24
+ * Builds one unsigned compact VP JWT for the canonical professional
25
+ * identity payload.
26
+ */
27
+ buildUnsignedIdentityVpJwt(input: ProfessionalSmartVpPayloadInput, options?: Readonly<{
28
+ nowSeconds?: number;
29
+ ttlSeconds?: number;
30
+ nonce?: string;
31
+ }>): string;
7
32
  ingestCommunicationAndUpdateIndex(ctx: FrontRouteContext, input: FrontCommunicationIngestionInput): Promise<SubmitAndPollResult>;
8
33
  grantProfessionalAccess(ctx: FrontRouteContext, input: FrontGrantProfessionalAccessInput): Promise<FrontGrantProfessionalAccessResult>;
9
34
  submitAndPoll(submitPath: string, pollPath: string, payload: SubmitPayload, pollOptions?: PollOptions): Promise<SubmitAndPollResult>;
@@ -1,4 +1,5 @@
1
1
  // Copyright 2026 Antifraud Services Inc. under the Apache License, Version 2.0.
2
+ import { buildProfessionalIdentityVpPayload, buildUnsignedProfessionalIdentityVpJwt, getProfessionalIdentitySameAs, getProfessionalIdentityVC, } from 'gdc-common-utils-ts';
2
3
  import { requireClientMethod } from './client-port.js';
3
4
  export class ProfessionalSdk {
4
5
  constructor(client) {
@@ -7,6 +8,34 @@ export class ProfessionalSdk {
7
8
  requestSmartToken(input) {
8
9
  return requireClientMethod(this.client, 'requestSmartToken')(input);
9
10
  }
11
+ /**
12
+ * Returns the normalized public continuity aliases that would be embedded in
13
+ * the professional identity VC for SMART/OpenID4VP flows.
14
+ */
15
+ getIdentitySameAs(input) {
16
+ return getProfessionalIdentitySameAs(input);
17
+ }
18
+ /**
19
+ * Builds the canonical professional identity VC used by the shared SMART VP
20
+ * helpers.
21
+ */
22
+ getIdentityVC(input) {
23
+ return getProfessionalIdentityVC(input);
24
+ }
25
+ /**
26
+ * Builds the canonical professional identity VP payload used by the shared
27
+ * SMART/OpenID4VP helpers.
28
+ */
29
+ buildIdentityVpPayload(input) {
30
+ return buildProfessionalIdentityVpPayload(input);
31
+ }
32
+ /**
33
+ * Builds one unsigned compact VP JWT for the canonical professional
34
+ * identity payload.
35
+ */
36
+ buildUnsignedIdentityVpJwt(input, options = {}) {
37
+ return buildUnsignedProfessionalIdentityVpJwt(input, options);
38
+ }
10
39
  ingestCommunicationAndUpdateIndex(ctx, input) {
11
40
  return requireClientMethod(this.client, 'ingestCommunicationAndUpdateIndex')(ctx, input);
12
41
  }
@@ -1,7 +1,7 @@
1
1
  import type { DeviceAppType, DeviceUserClass } from 'gdc-common-utils-ts/constants';
2
2
  import type { IndividualOnboardingDraftInput, IndividualOnboardingDraftResult } from 'gdc-common-utils-ts/models/individual-onboarding';
3
3
  import { type HostLifecycleInput, type HostRouteContext, type HostedTenantLifecycleInput, type LegalOrganizationOrderInput, type SubmitAndPollResult } from 'gdc-sdk-core-ts';
4
- import { type FrontLicenseListSearchInput, type FrontLicenseOfferSearchInput, type FrontLicenseOrderSearchInput, type FrontOrganizationEmployeeSearchInput, type FrontGrantProfessionalAccessResult, type FrontSmartTokenExchangeResult, type FrontSmartTokenRequestInput } from './orchestration/client-port.js';
4
+ import { type FrontLicenseListSearchInput, type FrontLicenseOfferSearchInput, type FrontLicenseOrderSearchInput, type FrontIndividualOrganizationLifecycleInput, type FrontOrganizationEmployeeSearchInput, type FrontGrantProfessionalAccessResult, type FrontSmartTokenExchangeResult, type FrontSmartTokenRequestInput } from './orchestration/client-port.js';
5
5
  export declare class CommonAuthService {
6
6
  activateDevice(_licenseCode: string, _providerDid: string, _idToken: string): Promise<{
7
7
  thid: string;
@@ -70,14 +70,8 @@ export declare class FamilyAdminService {
70
70
  offerId: string;
71
71
  orderClaims?: Record<string, unknown>;
72
72
  }): Promise<SubmitAndPollResult>;
73
- disableIndividual(_providerDid: string, _idToken: string, _input: {
74
- organizationClaims?: Record<string, unknown>;
75
- resourceId?: string;
76
- }): Promise<SubmitAndPollResult>;
77
- purgeIndividual(_providerDid: string, _idToken: string, _input: {
78
- organizationClaims?: Record<string, unknown>;
79
- resourceId?: string;
80
- }): Promise<SubmitAndPollResult>;
73
+ disableIndividual(_providerDid: string, _idToken: string, _input: FrontIndividualOrganizationLifecycleInput): Promise<SubmitAndPollResult>;
74
+ purgeIndividual(_providerDid: string, _idToken: string, _input: FrontIndividualOrganizationLifecycleInput): Promise<SubmitAndPollResult>;
81
75
  disableIndividualMember(_providerDid: string, _idToken: string, _input: {
82
76
  memberClaims?: Record<string, unknown>;
83
77
  resourceId?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gdc-sdk-front-ts",
3
- "version": "2.1.0",
3
+ "version": "2.1.2",
4
4
  "description": "Next-generation frontend runtime package for the GDC SDK family",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Antifraud Services Inc.",
@@ -17,8 +17,8 @@
17
17
  },
18
18
  "dependencies": {
19
19
  "@babel/runtime": "^7.28.4",
20
- "gdc-common-utils-ts": "^2.1.0",
21
- "gdc-sdk-core-ts": "^2.1.0"
20
+ "gdc-common-utils-ts": "^2.1.2",
21
+ "gdc-sdk-core-ts": "~2.1.2"
22
22
  },
23
23
  "devDependencies": {
24
24
  "@types/node": "^20.14.10",