gdc-sdk-node-ts 2.9.2 → 2.9.3
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/README.md +19 -15
- package/dist/family-organization-registration.js +2 -2
- package/dist/individual-controller-backend-runtime.d.ts +9 -5
- package/dist/individual-controller-backend-runtime.js +10 -4
- package/dist/individual-start.d.ts +16 -5
- package/dist/individual-start.js +14 -5
- package/dist/node-runtime-client.d.ts +12 -5
- package/dist/node-runtime-client.js +14 -5
- package/dist/orchestration/client-port.d.ts +4 -2
- package/dist/orchestration/individual-controller-sdk.d.ts +10 -4
- package/dist/orchestration/individual-controller-sdk.js +12 -4
- package/dist/orchestration/personal-sdk.d.ts +5 -3
- package/dist/orchestration/personal-sdk.js +6 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -69,46 +69,50 @@ If you are integrating this package for the first time, open these in order:
|
|
|
69
69
|
2. [docs/101-SDK_END_TO_END.md](./docs/101-SDK_END_TO_END.md)
|
|
70
70
|
Ordered onboarding guide with end-to-end journeys, copy/paste snippets, and
|
|
71
71
|
the recommended reading path for new backend integrators.
|
|
72
|
-
3. [docs/101-
|
|
72
|
+
3. [docs/101-HIGH_LEVEL_CLINICAL_PROFILE_WRITES.md](./docs/101-HIGH_LEVEL_CLINICAL_PROFILE_WRITES.md)
|
|
73
|
+
Focused subset of the end-to-end guide: load a professional or individual
|
|
74
|
+
member/controller profile, create or import clinical data in the selected
|
|
75
|
+
index provider, and verify it through an authoritative summary readback.
|
|
76
|
+
4. [docs/101-PROFESSIONAL-CONSENT-SMART.md](./docs/101-PROFESSIONAL-CONSENT-SMART.md)
|
|
73
77
|
Canonical professional DID, consent, VP and SMART flow without literal
|
|
74
78
|
sections or caller-built audience URLs.
|
|
75
|
-
|
|
79
|
+
5. [docs/101-AUTHORIZED_SUBJECT_DIRECTORY.md](./docs/101-AUTHORIZED_SUBJECT_DIRECTORY.md)
|
|
76
80
|
Signed OpenID account discovery of already-authorized subjects without
|
|
77
81
|
treating the account token as VP, SMART or wallet proof.
|
|
78
|
-
|
|
82
|
+
6. [docs/101-SDK_INTEGRATION.md](./docs/101-SDK_INTEGRATION.md)
|
|
79
83
|
Real backend setup plus the public runtime entrypoints:
|
|
80
84
|
`HostOnboardingSdk`, `OrganizationControllerSdk`,
|
|
81
85
|
`IndividualControllerSdk`, `ProfessionalSdk`, route-context usage, and the
|
|
82
86
|
canonical `ProfileRuntime -> loadProfile(...) -> workspace/session -> actor facade -> submit/poll` shape.
|
|
83
|
-
|
|
87
|
+
7. [tests/101-live-full-cycle-bff-runtime.e2e.test.mjs](./tests/101-live-full-cycle-bff-runtime.e2e.test.mjs)
|
|
84
88
|
Canonical live backend/BFF walkthrough on a fresh local GW lifecycle:
|
|
85
89
|
host/tenant activation, employee provisioning, individual bootstrap,
|
|
86
90
|
consent grant, professional SMART token, clinical read, and final cleanup.
|
|
87
|
-
|
|
91
|
+
8. [docs/101-LIVE_GW_LOCAL.md](./docs/101-LIVE_GW_LOCAL.md)
|
|
88
92
|
Exact TTY/local/Docker commands for running the SDK against a real local GW
|
|
89
93
|
CORE, including tenant bootstrap and employee-seat setup.
|
|
90
|
-
|
|
94
|
+
9. [docs/101-DISCOVERY.md](./docs/101-DISCOVERY.md)
|
|
91
95
|
Node/BFF dataspace discovery, hosting-operator resolution, provider
|
|
92
96
|
resolution, and the correct integration boundary for fallback and cache.
|
|
93
|
-
|
|
97
|
+
10. [gdc-sdk-core-ts/docs/101-SDK_FLOWS.md](https://github.com/Global-DataCare/gdc-sdk-core-ts/blob/main/docs/101-SDK_FLOWS.md)
|
|
94
98
|
Actor split and business-flow map across organization, individual,
|
|
95
99
|
permissions, invitation, import, and SMART flows.
|
|
96
|
-
|
|
100
|
+
11. [gwtemplate-node-ts/docs/PORTAL_API_TO_GW_CORE.md](https://github.com/Global-DataCare/gwtemplate-node-ts/blob/main/docs/PORTAL_API_TO_GW_CORE.md)
|
|
97
101
|
Canonical portal/BFF functional map over GW CORE, including the domain
|
|
98
102
|
split between `employees`, `related persons`, `members`, and `consents`.
|
|
99
|
-
|
|
103
|
+
12. [gdc-common-utils-ts/src/examples/](https://github.com/Global-DataCare/gdc-common-utils-ts/tree/main/src/examples)
|
|
100
104
|
Shared payload values used by the docs and tests.
|
|
101
|
-
|
|
105
|
+
13. [gdc-common-utils-ts/docs/101-LIFECYCLE.md](https://github.com/Global-DataCare/gdc-common-utils-ts/blob/main/docs/101-LIFECYCLE.md)
|
|
102
106
|
Canonical `enable/disable/delete` semantics and copy/paste placeholders.
|
|
103
|
-
|
|
107
|
+
14. [tests/101-backend-profile-runtime.test.mjs](./tests/101-backend-profile-runtime.test.mjs)
|
|
104
108
|
Technical runtime slice for profile/device/session orchestration internals.
|
|
105
109
|
Read this after the public actor SDK guides, not before them.
|
|
106
|
-
|
|
110
|
+
15. [tests/101-individual-controller-backend-runtime.test.mjs](./tests/101-individual-controller-backend-runtime.test.mjs)
|
|
107
111
|
Technical wrapper slice around the generic profile runtime. This is not the
|
|
108
112
|
main onboarding path for new integrators.
|
|
109
|
-
|
|
113
|
+
16. [docs/V2_INDIVIDUAL_REGISTRATION_RECONCILIATION.md](./docs/V2_INDIVIDUAL_REGISTRATION_RECONCILIATION.md)
|
|
110
114
|
Historical reconciliation note for the current CORE registration baseline.
|
|
111
|
-
|
|
115
|
+
17. [docs/NEXT_STEPS.md](./docs/NEXT_STEPS.md)
|
|
112
116
|
Follow-up scope after GW CORE live validation, including the future user job
|
|
113
117
|
manager boundary.
|
|
114
118
|
|
|
@@ -674,7 +678,7 @@ modules below.
|
|
|
674
678
|
- function: `confirmLegalOrganizationOrderWithDeps(...)`
|
|
675
679
|
- [`src/individual-start.ts`](src/individual-start.ts)
|
|
676
680
|
- types: `IndividualOrganizationBootstrapInput`, `OfferPreview`, `IndividualOrganizationStartResult`
|
|
677
|
-
- function: `
|
|
681
|
+
- function: `registerIndividualOrganizationWithDeps(...)`
|
|
678
682
|
- [`src/individual-onboarding.ts`](src/individual-onboarding.ts)
|
|
679
683
|
- types: `RouteContext`, `IndividualOrganizationConfirmOrderInput`
|
|
680
684
|
- function: `confirmIndividualOrganizationOrderWithDeps(...)`
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// Copyright 2026 Antifraud Services Inc. under the Apache License, Version 2.0.
|
|
2
|
-
import {
|
|
2
|
+
import { registerIndividualOrganizationWithDeps, } from './individual-start.js';
|
|
3
3
|
import { searchFamilyOrganizationWithDeps, } from './family-organization-search.js';
|
|
4
4
|
import { extractOfferIdFromResponseBody, extractOfferPreviewFromResponseBody } from './order-offer-summary.js';
|
|
5
5
|
/**
|
|
@@ -24,7 +24,7 @@ export async function ensureFamilyOrganizationRegistrationWithDeps(deps) {
|
|
|
24
24
|
summary,
|
|
25
25
|
};
|
|
26
26
|
}
|
|
27
|
-
const started = await
|
|
27
|
+
const started = await registerIndividualOrganizationWithDeps({
|
|
28
28
|
input: {
|
|
29
29
|
serviceProviderDid: deps.input.serviceProviderDid,
|
|
30
30
|
tenantId: deps.input.tenantId,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { SubmitAndPollResult } from 'gdc-sdk-core-ts';
|
|
2
2
|
import type { FamilyOrganizationSummary } from 'gdc-common-utils-ts/utils/family-organization-summary';
|
|
3
3
|
import type { IndividualOrganizationConfirmOrderInput, IndividualOrganizationOrderResult, RouteContext } from './individual-onboarding.js';
|
|
4
|
-
import type {
|
|
4
|
+
import type { IndividualOrganizationRegistrationInput, IndividualOrganizationRegistrationResult } from './individual-start.js';
|
|
5
5
|
import type { EnsureFamilyOrganizationRegistrationInput, EnsureFamilyOrganizationRegistrationResult } from './family-organization-registration.js';
|
|
6
6
|
import type { FamilyOrganizationSearchInput } from './family-organization-search.js';
|
|
7
7
|
import type { BlockchainArtifactRegistrationInput, ClinicalBundleSearchInput, ClinicalSectionUpdateInput, ClinicalSummaryReadResult, ClinicalSummaryRequestInput, ClinicalSummaryUpdateInput, CommunicationIngestionInput, IpsOrFhirImportInput } from './resource-operations.js';
|
|
@@ -15,7 +15,7 @@ import type { ProfileLoadRequest } from 'gdc-sdk-core-ts';
|
|
|
15
15
|
* consumers need first:
|
|
16
16
|
*
|
|
17
17
|
* - load an individual-controller profile
|
|
18
|
-
* -
|
|
18
|
+
* - register an individual organization/subject index
|
|
19
19
|
* - confirm the returned order/offer
|
|
20
20
|
* - request the available subject clinical summary through Communication
|
|
21
21
|
* - use direct index searches only for compatibility/specialized queries
|
|
@@ -29,9 +29,12 @@ export declare class IndividualControllerBackendRuntime {
|
|
|
29
29
|
*/
|
|
30
30
|
loadProfile(input: ProfileLoadRequest): Promise<BackendIndividualControllerProfile>;
|
|
31
31
|
/**
|
|
32
|
-
*
|
|
32
|
+
* Registers the personal organization/subject index and returns its Offer.
|
|
33
|
+
* This does not enroll a wallet or a DCR device.
|
|
33
34
|
*/
|
|
34
|
-
|
|
35
|
+
registerIndividualOrganization(profile: BackendIndividualControllerProfile, input: IndividualOrganizationRegistrationInput): Promise<IndividualOrganizationRegistrationResult>;
|
|
36
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
37
|
+
startIndividualOrganization(profile: BackendIndividualControllerProfile, input: IndividualOrganizationRegistrationInput): Promise<IndividualOrganizationRegistrationResult>;
|
|
35
38
|
/**
|
|
36
39
|
* Searches one existing family/individual registration before deciding
|
|
37
40
|
* whether the backend should create or resume it.
|
|
@@ -43,7 +46,8 @@ export declare class IndividualControllerBackendRuntime {
|
|
|
43
46
|
*/
|
|
44
47
|
ensureFamilyOrganizationRegistration(profile: BackendIndividualControllerProfile, ctx: RouteContext, input: EnsureFamilyOrganizationRegistrationInput): Promise<EnsureFamilyOrganizationRegistrationResult>;
|
|
45
48
|
/**
|
|
46
|
-
* Confirms the
|
|
49
|
+
* Confirms the Offer returned by the individual registration and returns the
|
|
50
|
+
* opaque controller activation code for managed profile enrollment.
|
|
47
51
|
*/
|
|
48
52
|
confirmIndividualOrganizationOrder(profile: BackendIndividualControllerProfile, input: IndividualOrganizationConfirmOrderInput): Promise<IndividualOrganizationOrderResult>;
|
|
49
53
|
/**
|
|
@@ -8,7 +8,7 @@ import { loadBackendIndividualControllerProfile, } from './backend-profile-runti
|
|
|
8
8
|
* consumers need first:
|
|
9
9
|
*
|
|
10
10
|
* - load an individual-controller profile
|
|
11
|
-
* -
|
|
11
|
+
* - register an individual organization/subject index
|
|
12
12
|
* - confirm the returned order/offer
|
|
13
13
|
* - request the available subject clinical summary through Communication
|
|
14
14
|
* - use direct index searches only for compatibility/specialized queries
|
|
@@ -25,10 +25,15 @@ export class IndividualControllerBackendRuntime {
|
|
|
25
25
|
return loadBackendIndividualControllerProfile(this.profileRuntime, input);
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
28
|
-
*
|
|
28
|
+
* Registers the personal organization/subject index and returns its Offer.
|
|
29
|
+
* This does not enroll a wallet or a DCR device.
|
|
29
30
|
*/
|
|
31
|
+
registerIndividualOrganization(profile, input) {
|
|
32
|
+
return profile.sdk.registerIndividualOrganization(input);
|
|
33
|
+
}
|
|
34
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
30
35
|
startIndividualOrganization(profile, input) {
|
|
31
|
-
return
|
|
36
|
+
return this.registerIndividualOrganization(profile, input);
|
|
32
37
|
}
|
|
33
38
|
/**
|
|
34
39
|
* Searches one existing family/individual registration before deciding
|
|
@@ -45,7 +50,8 @@ export class IndividualControllerBackendRuntime {
|
|
|
45
50
|
return profile.sdk.ensureFamilyOrganizationRegistration(ctx, input);
|
|
46
51
|
}
|
|
47
52
|
/**
|
|
48
|
-
* Confirms the
|
|
53
|
+
* Confirms the Offer returned by the individual registration and returns the
|
|
54
|
+
* opaque controller activation code for managed profile enrollment.
|
|
49
55
|
*/
|
|
50
56
|
confirmIndividualOrganizationOrder(profile, input) {
|
|
51
57
|
return profile.sdk.confirmIndividualOrganizationOrder(input);
|
|
@@ -4,7 +4,7 @@ import type { FamilyRegistrationStatus } from 'gdc-common-utils-ts/utils/family-
|
|
|
4
4
|
import type { PollOptions, SubmitAndPollResult } from './orchestration/client-port.js';
|
|
5
5
|
import type { RouteContext } from './individual-onboarding.js';
|
|
6
6
|
import type { OfferPreview } from './order-offer-summary.js';
|
|
7
|
-
export type
|
|
7
|
+
export type IndividualOrganizationRegistrationInput = {
|
|
8
8
|
/**
|
|
9
9
|
* Preferred route identifier for the selected personal indexing service provider.
|
|
10
10
|
*
|
|
@@ -58,7 +58,9 @@ export type IndividualOrganizationBootstrapInput = {
|
|
|
58
58
|
timeoutSeconds?: number;
|
|
59
59
|
intervalSeconds?: number;
|
|
60
60
|
};
|
|
61
|
-
|
|
61
|
+
/** @deprecated Use `IndividualOrganizationRegistrationInput`. */
|
|
62
|
+
export type IndividualOrganizationBootstrapInput = IndividualOrganizationRegistrationInput;
|
|
63
|
+
export type IndividualOrganizationRegistrationResult = {
|
|
62
64
|
registration: SubmitAndPollResult;
|
|
63
65
|
offerId: string;
|
|
64
66
|
offerPreview: OfferPreview;
|
|
@@ -76,6 +78,8 @@ export type IndividualOrganizationStartResult = {
|
|
|
76
78
|
*/
|
|
77
79
|
identity?: IndividualOrganizationBootstrapIdentity;
|
|
78
80
|
};
|
|
81
|
+
/** @deprecated Use `IndividualOrganizationRegistrationResult`. */
|
|
82
|
+
export type IndividualOrganizationStartResult = IndividualOrganizationRegistrationResult;
|
|
79
83
|
export type IndividualOrganizationBootstrapIdentity = {
|
|
80
84
|
/** Technical UUID returned as `Bundle.data[0].resource.id`. */
|
|
81
85
|
resourceId: string;
|
|
@@ -88,8 +92,8 @@ export type IndividualOrganizationBootstrapIdentity = {
|
|
|
88
92
|
/** Canonical child DID built beneath the exact provider DID returned by GW. */
|
|
89
93
|
subjectDid: string;
|
|
90
94
|
};
|
|
91
|
-
type
|
|
92
|
-
input:
|
|
95
|
+
type RegisterIndividualOrganizationDeps = {
|
|
96
|
+
input: IndividualOrganizationRegistrationInput;
|
|
93
97
|
routeCtx: RouteContext;
|
|
94
98
|
defaultTimeoutMs?: number;
|
|
95
99
|
defaultIntervalMs?: number;
|
|
@@ -102,7 +106,14 @@ type StartIndividualOrganizationDeps = {
|
|
|
102
106
|
getOfferIdFromResponse: (result: SubmitAndPollResult) => string | undefined;
|
|
103
107
|
getOfferPreviewFromResponse: (result: SubmitAndPollResult) => OfferPreview;
|
|
104
108
|
};
|
|
105
|
-
|
|
109
|
+
/**
|
|
110
|
+
* Registers the hosted personal organization/subject index and returns its
|
|
111
|
+
* commercial Offer. This phase does not create a managed wallet, exchange an
|
|
112
|
+
* activation code, register DCR keys, or open a profile session.
|
|
113
|
+
*/
|
|
114
|
+
export declare function registerIndividualOrganizationWithDeps(deps: RegisterIndividualOrganizationDeps): Promise<IndividualOrganizationRegistrationResult>;
|
|
115
|
+
/** @deprecated Use `registerIndividualOrganizationWithDeps`. */
|
|
116
|
+
export declare function startIndividualOrganizationWithDeps(deps: RegisterIndividualOrganizationDeps): Promise<IndividualOrganizationRegistrationResult>;
|
|
106
117
|
/**
|
|
107
118
|
* Projects the reusable subject identity from an individual bootstrap receipt.
|
|
108
119
|
*
|
package/dist/individual-start.js
CHANGED
|
@@ -4,7 +4,12 @@ import { buildIndividualDidWeb, buildSecureIdValueIndividual, extractPrimaryClai
|
|
|
4
4
|
export { buildIndividualMemberDidWebFromPrivateIdentifiers } from 'gdc-common-utils-ts';
|
|
5
5
|
import { GwCoreLifecycleRequestType } from './constants/lifecycle.js';
|
|
6
6
|
import { resolvePollOptionsFromSeconds } from './poll-options.js';
|
|
7
|
-
|
|
7
|
+
/**
|
|
8
|
+
* Registers the hosted personal organization/subject index and returns its
|
|
9
|
+
* commercial Offer. This phase does not create a managed wallet, exchange an
|
|
10
|
+
* activation code, register DCR keys, or open a profile session.
|
|
11
|
+
*/
|
|
12
|
+
export async function registerIndividualOrganizationWithDeps(deps) {
|
|
8
13
|
/**
|
|
9
14
|
* Important semantic split:
|
|
10
15
|
*
|
|
@@ -19,12 +24,12 @@ export async function startIndividualOrganizationWithDeps(deps) {
|
|
|
19
24
|
*/
|
|
20
25
|
const alternateName = String(deps.input.alternateName || '').trim();
|
|
21
26
|
if (!alternateName) {
|
|
22
|
-
throw new Error('
|
|
27
|
+
throw new Error('registerIndividualOrganization requires alternateName.');
|
|
23
28
|
}
|
|
24
29
|
const controllerEmail = String(deps.input.controllerEmail || '').trim();
|
|
25
30
|
const controllerTelephone = String(deps.input.controllerTelephone || '').trim();
|
|
26
31
|
if (!controllerEmail && !controllerTelephone) {
|
|
27
|
-
throw new Error('
|
|
32
|
+
throw new Error('registerIndividualOrganization requires controllerEmail, or controllerTelephone only for compatibility/extension flows.');
|
|
28
33
|
}
|
|
29
34
|
const controllerRole = String(deps.input.controllerRole || 'RESPRSN').trim();
|
|
30
35
|
const claims = {
|
|
@@ -64,7 +69,7 @@ export async function startIndividualOrganizationWithDeps(deps) {
|
|
|
64
69
|
intervalMs: deps.defaultIntervalMs,
|
|
65
70
|
});
|
|
66
71
|
const registration = await deps.submitAndPoll(deps.individualFamilyOrganizationBatchPath(deps.routeCtx), deps.individualFamilyOrganizationPollPath(deps.routeCtx), registrationPayload, pollOptions);
|
|
67
|
-
deps.assertFirstDidcommEntrySuccess?.(registration, '
|
|
72
|
+
deps.assertFirstDidcommEntrySuccess?.(registration, 'registerIndividualOrganization.registration');
|
|
68
73
|
/**
|
|
69
74
|
* Commercial contract for this SDK path:
|
|
70
75
|
* - this helper targets the family/individual commercial bootstrap flow
|
|
@@ -76,7 +81,7 @@ export async function startIndividualOrganizationWithDeps(deps) {
|
|
|
76
81
|
*/
|
|
77
82
|
const offerId = deps.getOfferIdFromResponse(registration);
|
|
78
83
|
if (!offerId) {
|
|
79
|
-
throw new Error('
|
|
84
|
+
throw new Error('registerIndividualOrganization failed: missing offerId in registration response.');
|
|
80
85
|
}
|
|
81
86
|
const registrationSummary = readFamilyOrganizationSummaryFromResponseBody(registration.poll.body);
|
|
82
87
|
return {
|
|
@@ -88,6 +93,10 @@ export async function startIndividualOrganizationWithDeps(deps) {
|
|
|
88
93
|
identity: readIndividualOrganizationBootstrapIdentity(registration.poll.body),
|
|
89
94
|
};
|
|
90
95
|
}
|
|
96
|
+
/** @deprecated Use `registerIndividualOrganizationWithDeps`. */
|
|
97
|
+
export async function startIndividualOrganizationWithDeps(deps) {
|
|
98
|
+
return registerIndividualOrganizationWithDeps(deps);
|
|
99
|
+
}
|
|
91
100
|
/**
|
|
92
101
|
* Projects the reusable subject identity from an individual bootstrap receipt.
|
|
93
102
|
*
|
|
@@ -11,7 +11,7 @@ import { type FamilyOrganizationSearchInput } from './family-organization-search
|
|
|
11
11
|
import { type SmartTokenRequestInput } from './smart-token.js';
|
|
12
12
|
import { type EmployeeDeviceActivationRequestInput, type EmployeeDeviceActivationResult, type EmployeeDeviceOtpRecoveryInput, type EmployeeDeviceOtpRecoveryResult, type EmployeeDeviceRevocationInput } from './device-activation.js';
|
|
13
13
|
import { type OrganizationLicenseOrderConfirmInput } from './organization-license-order.js';
|
|
14
|
-
import { type
|
|
14
|
+
import { type IndividualOrganizationRegistrationInput, type IndividualOrganizationRegistrationResult } from './individual-start.js';
|
|
15
15
|
import { type CommunicationIngestionInput, type BlockchainArtifactRegistrationInput, type VitalSignBatchCommunicationFromSearchResponseInput, type CommunicationParticipantRuntimeSearchInput, type ClinicalBundleSearchInput, type ClinicalSectionUpdateInput, type ClinicalSummaryReadResult, type ClinicalSummaryRequestInput, type ClinicalSummaryUpdateInput, type GrantProfessionalAccessInput, type GrantProfessionalAccessResult, type DigitalTwinSecondaryUseConsentInput, type DigitalTwinSecondaryUseConsentResult, type DigitalTwinSubjectLinkPurgeInput, type DigitalTwinSubjectLinkPurgeResult, type SubjectConsentSearchInput, type IndividualMemberLifecycleInput, type IndividualMemberLicenseAddInput, type IndividualMemberLicenseInvitationInput, type IndividualMemberLicenseTransitionInput, type LicenseListRuntimeSearchInput, type LicenseOfferRuntimeSearchInput, type LicenseOrderRuntimeSearchInput, type OrganizationEmployeeCreationInput, type OrganizationEmployeeLicenseAddInput, type OrganizationEmployeeLicenseOfferInput, type OrganizationEmployeeLicenseInvitationInput, type OrganizationEmployeeLifecycleInput, type OrganizationEmployeeSearchInput, type ProfessionalAccessRequestInput, type ProfessionalAccessRequestResult, type RevokeProfessionalAccessInput, type RevokeProfessionalAccessResult, type RelatedPersonUpsertInput } from './resource-operations.js';
|
|
16
16
|
import type { LegalOrganizationOrderInput } from './host-onboarding.js';
|
|
17
17
|
import type { SmartTokenExchangeResult } from './smart-token.js';
|
|
@@ -349,18 +349,21 @@ export declare class HttpRuntimeClient implements NodeRuntimeClient {
|
|
|
349
349
|
*/
|
|
350
350
|
confirmOrganizationLicenseOrder(ctx: RouteContext, input: OrganizationLicenseOrderConfirmInput, pollOptions?: PollOptions): Promise<SubmitAndPollResult>;
|
|
351
351
|
/**
|
|
352
|
-
*
|
|
352
|
+
* Registers an individual-oriented personal organization/subject index.
|
|
353
353
|
*
|
|
354
354
|
* Commercial contract:
|
|
355
355
|
* - this SDK method targets the family/individual commercial bootstrap flow
|
|
356
356
|
* - the registration poll response is expected to return one Offer id
|
|
357
357
|
* - callers should then confirm it through
|
|
358
358
|
* `confirmIndividualOrganizationOrder(...)`
|
|
359
|
+
* - this phase does not create a wallet, perform DCR, or open a profile
|
|
359
360
|
*
|
|
360
361
|
* This is distinct from embedded legacy individual registration helpers in
|
|
361
362
|
* GW CORE that may persist an individual record without minting an Offer.
|
|
362
363
|
*/
|
|
363
|
-
|
|
364
|
+
registerIndividualOrganization(input: IndividualOrganizationRegistrationInput): Promise<IndividualOrganizationRegistrationResult>;
|
|
365
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
366
|
+
startIndividualOrganization(input: IndividualOrganizationRegistrationInput): Promise<IndividualOrganizationRegistrationResult>;
|
|
364
367
|
/**
|
|
365
368
|
* Searches one existing family/individual registration by controller phone +
|
|
366
369
|
* usualname, with optional birth-date disambiguation.
|
|
@@ -380,10 +383,14 @@ export declare class HttpRuntimeClient implements NodeRuntimeClient {
|
|
|
380
383
|
ensureFamilyOrganizationRegistration(ctx: RouteContext, input: EnsureFamilyOrganizationRegistrationInput): Promise<Readonly<{
|
|
381
384
|
status: "already_exists" | "resume_required" | "new_created";
|
|
382
385
|
summary?: import("gdc-common-utils-ts").FamilyOrganizationSummary;
|
|
383
|
-
started?: IndividualOrganizationStartResult;
|
|
386
|
+
started?: import("./individual-start.js").IndividualOrganizationStartResult;
|
|
384
387
|
}>>;
|
|
385
388
|
/**
|
|
386
|
-
* Confirms the
|
|
389
|
+
* Confirms the Offer returned by `registerIndividualOrganization(...)`, waits
|
|
390
|
+
* for the terminal Order, and exposes its controller `activationCode`.
|
|
391
|
+
* The caller passes that opaque value directly to
|
|
392
|
+
* `ServerProfileSessionManager.enroll(...)`; it does not traverse claims or
|
|
393
|
+
* call a separate licence reader.
|
|
387
394
|
*/
|
|
388
395
|
confirmIndividualOrganizationOrder(input: IndividualOrganizationConfirmOrderInput): Promise<IndividualOrganizationOrderResult>;
|
|
389
396
|
/**
|
|
@@ -9,7 +9,7 @@ import { requestSmartTokenWithDeps } from './smart-token.js';
|
|
|
9
9
|
import { activateEmployeeDeviceWithActivationCodeWithDeps, activateEmployeeDeviceWithActivationRequestWithDeps, recoverEmployeeDeviceWithOtpWithDeps, revokeEmployeeDeviceWithDeps, } from './device-activation.js';
|
|
10
10
|
import { extractOfferIdFromResponseBody, extractOfferPreviewFromResponseBody, } from './order-offer-summary.js';
|
|
11
11
|
import { confirmOrganizationLicenseOrderWithDeps } from './organization-license-order.js';
|
|
12
|
-
import {
|
|
12
|
+
import { registerIndividualOrganizationWithDeps } from './individual-start.js';
|
|
13
13
|
import { createOrganizationEmployeeWithDeps, issueOrganizationEmployeeLicenseWithDeps, disableIndividualMemberWithDeps, disableIndividualOrganizationWithDeps, disableOrganizationEmployeeWithDeps, listIndividualLicenseOffersWithDeps, listIndividualLicenseOrdersWithDeps, listIndividualLicensesWithDeps, addFreeIndividualMemberLicensesWithDeps, issueIndividualMemberLicenseWithDeps, transitionIndividualMemberLicenseWithDeps, listOrganizationLicenseOffersWithDeps, listOrganizationLicenseOrdersWithDeps, listOrganizationLicensesWithDeps, grantProfessionalAccessWithDeps, setDigitalTwinSecondaryUseConsentWithDeps, purgeDigitalTwinSubjectLinkWithDeps, searchSubjectConsentsWithDeps, buildClinicalSectionUpdateIngestion, buildClinicalSummaryUpdateIngestion, ingestCommunicationAndUpdateIndexWithDeps, requestProfessionalAccessWithDeps, buildVitalSignBatchCommunicationFromSearchResponse, registerBlockchainArtifactAndUpdateIndexWithDeps, requestClinicalSummaryWithDeps, revokeProfessionalAccessWithDeps, searchCommunicationParticipantsWithDeps, purgeIndividualMemberWithDeps, purgeIndividualOrganizationWithDeps, purgeOrganizationEmployeeWithDeps, prepareEmployeeLifecycleMessageForTransport, searchIndividualLicensesWithDeps, searchIndividualLicenseOffersWithDeps, searchIndividualLicenseOrdersWithDeps, searchOrganizationLicensesWithDeps, searchOrganizationLicenseOffersWithDeps, searchOrganizationLicenseOrdersWithDeps, searchOrganizationEmployeesWithDeps, searchClinicalBundleWithDeps, searchLatestIpsWithDeps, upsertRelatedPersonAndPollWithDeps, normalizeCommunicationPathFormatSegment, addFreeOrganizationEmployeeLicensesWithDeps, requestOrganizationEmployeeLicenseOfferWithDeps, } from './resource-operations.js';
|
|
14
14
|
import { listOrganizationEmployeeLifecycleWithDeps, provisionOrganizationEmployeeWithDeps, } from './organization-employee-lifecycle.js';
|
|
15
15
|
import { buildRuntimeHeaders, fetchWithTimeout, parseResponseBody, postRenderedWithRuntimeConfig, } from './runtime-transport.js';
|
|
@@ -620,20 +620,21 @@ export class HttpRuntimeClient {
|
|
|
620
620
|
});
|
|
621
621
|
}
|
|
622
622
|
/**
|
|
623
|
-
*
|
|
623
|
+
* Registers an individual-oriented personal organization/subject index.
|
|
624
624
|
*
|
|
625
625
|
* Commercial contract:
|
|
626
626
|
* - this SDK method targets the family/individual commercial bootstrap flow
|
|
627
627
|
* - the registration poll response is expected to return one Offer id
|
|
628
628
|
* - callers should then confirm it through
|
|
629
629
|
* `confirmIndividualOrganizationOrder(...)`
|
|
630
|
+
* - this phase does not create a wallet, perform DCR, or open a profile
|
|
630
631
|
*
|
|
631
632
|
* This is distinct from embedded legacy individual registration helpers in
|
|
632
633
|
* GW CORE that may persist an individual record without minting an Offer.
|
|
633
634
|
*/
|
|
634
|
-
async
|
|
635
|
+
async registerIndividualOrganization(input) {
|
|
635
636
|
const routeCtx = this.paths.routeCtxFromInput(input);
|
|
636
|
-
return
|
|
637
|
+
return registerIndividualOrganizationWithDeps({
|
|
637
638
|
input,
|
|
638
639
|
routeCtx,
|
|
639
640
|
individualFamilyOrganizationBatchPath: this.paths.individualFamilyOrganizationTransactionPath.bind(this.paths),
|
|
@@ -643,6 +644,10 @@ export class HttpRuntimeClient {
|
|
|
643
644
|
getOfferPreviewFromResponse: (result) => extractOfferPreviewFromResponseBody(result.poll.body),
|
|
644
645
|
});
|
|
645
646
|
}
|
|
647
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
648
|
+
async startIndividualOrganization(input) {
|
|
649
|
+
return this.registerIndividualOrganization(input);
|
|
650
|
+
}
|
|
646
651
|
/**
|
|
647
652
|
* Searches one existing family/individual registration by controller phone +
|
|
648
653
|
* usualname, with optional birth-date disambiguation.
|
|
@@ -676,7 +681,11 @@ export class HttpRuntimeClient {
|
|
|
676
681
|
});
|
|
677
682
|
}
|
|
678
683
|
/**
|
|
679
|
-
* Confirms the
|
|
684
|
+
* Confirms the Offer returned by `registerIndividualOrganization(...)`, waits
|
|
685
|
+
* for the terminal Order, and exposes its controller `activationCode`.
|
|
686
|
+
* The caller passes that opaque value directly to
|
|
687
|
+
* `ServerProfileSessionManager.enroll(...)`; it does not traverse claims or
|
|
688
|
+
* call a separate licence reader.
|
|
680
689
|
*/
|
|
681
690
|
async confirmIndividualOrganizationOrder(input) {
|
|
682
691
|
const routeCtx = this.paths.routeCtxFromInput(input);
|
|
@@ -10,7 +10,7 @@ import type { OrganizationEmployeeProvisioningInput, OrganizationEmployeeProvisi
|
|
|
10
10
|
import type { OrganizationEmployeeLifecycleRecord } from 'gdc-common-utils-ts/models/organization-employee-lifecycle';
|
|
11
11
|
import type { HostRouteContext, HostedTenantLifecycleInput, LegalOrganizationOrderInput } from '../host-onboarding.js';
|
|
12
12
|
import type { IndividualOrganizationConfirmOrderInput, IndividualOrganizationOrderResult, RouteContext } from '../individual-onboarding.js';
|
|
13
|
-
import type { IndividualOrganizationBootstrapInput, IndividualOrganizationStartResult } from '../individual-start.js';
|
|
13
|
+
import type { IndividualOrganizationBootstrapInput, IndividualOrganizationRegistrationInput, IndividualOrganizationRegistrationResult, IndividualOrganizationStartResult } from '../individual-start.js';
|
|
14
14
|
import type { FamilyOrganizationSearchInput } from '../family-organization-search.js';
|
|
15
15
|
import type { FhirR5SubscriptionTopic } from 'gdc-common-utils-ts/models/fhir-r5-subscription';
|
|
16
16
|
import type { FhirR5SubscriptionBatchInput } from '../fhir-r5-subscription-runtime.js';
|
|
@@ -104,7 +104,9 @@ export type RuntimeClient = {
|
|
|
104
104
|
activateEmployeeDeviceWithActivationRequest?: (input: EmployeeDeviceActivationRequestInput) => Promise<EmployeeDeviceActivationResult>;
|
|
105
105
|
revokeEmployeeDevice?: (ctx: RouteContext, input: EmployeeDeviceRevocationInput) => Promise<SubmitAndPollResult>;
|
|
106
106
|
requestSmartToken?: (input: SmartTokenRequestInput) => Promise<SmartTokenExchangeResult>;
|
|
107
|
-
|
|
107
|
+
registerIndividualOrganization?: (input: IndividualOrganizationRegistrationInput) => Promise<IndividualOrganizationRegistrationResult>;
|
|
108
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
109
|
+
startIndividualOrganization?: (input: IndividualOrganizationRegistrationInput) => Promise<IndividualOrganizationRegistrationResult>;
|
|
108
110
|
searchFamilyOrganization?: (ctx: RouteContext, input: FamilyOrganizationSearchInput) => Promise<FamilyOrganizationSummary | null>;
|
|
109
111
|
ensureFamilyOrganizationRegistration?: (ctx: RouteContext, input: EnsureFamilyOrganizationRegistrationInput) => Promise<EnsureFamilyOrganizationRegistrationResult>;
|
|
110
112
|
confirmIndividualOrganizationOrder?: (input: IndividualOrganizationConfirmOrderInput) => Promise<IndividualOrganizationOrderResult>;
|
|
@@ -4,7 +4,7 @@ import type { FamilyOrganizationSummary } from 'gdc-common-utils-ts/utils/family
|
|
|
4
4
|
import type { EnsureFamilyOrganizationRegistrationInput, EnsureFamilyOrganizationRegistrationResult } from '../family-organization-registration.js';
|
|
5
5
|
import type { FamilyOrganizationSearchInput } from '../family-organization-search.js';
|
|
6
6
|
import type { IndividualOrganizationConfirmOrderInput, IndividualOrganizationOrderResult, RouteContext } from '../individual-onboarding.js';
|
|
7
|
-
import type {
|
|
7
|
+
import type { IndividualOrganizationRegistrationInput, IndividualOrganizationRegistrationResult } from '../individual-start.js';
|
|
8
8
|
import type { NodeCapability } from '../session.js';
|
|
9
9
|
import type { IndividualOrganizationLifecycleInput } from 'gdc-sdk-core-ts';
|
|
10
10
|
import type { BlockchainArtifactRegistrationInput, ClinicalBundleSearchInput, ClinicalSectionUpdateInput, ClinicalSummaryReadResult, ClinicalSummaryRequestInput, ClinicalSummaryUpdateInput, CommunicationIngestionInput, CommunicationParticipantRuntimeSearchInput, DigitalTwinGenerationInput, DigitalTwinSecondaryUseConsentInput, DigitalTwinSecondaryUseConsentResult, DigitalTwinSubjectLinkPurgeInput, DigitalTwinSubjectLinkPurgeResult, GrantProfessionalAccessInput, GrantProfessionalAccessResult, IndividualMemberLifecycleInput, IndividualMemberLicenseAddInput, IndividualMemberLicenseInvitationInput, IndividualMemberLicenseTransitionInput, IpsOrFhirImportInput, LicenseListRuntimeSearchInput, LicenseOfferRuntimeSearchInput, LicenseOrderRuntimeSearchInput, RevokeProfessionalAccessInput, RevokeProfessionalAccessResult, ProfessionalAccessRequestDecisionInput, ProfessionalAccessRequestSearchInput, RelatedPersonUpsertInput } from '../resource-operations.js';
|
|
@@ -23,9 +23,13 @@ export declare class IndividualControllerSdk {
|
|
|
23
23
|
*/
|
|
24
24
|
constructor(client: NodeRuntimeClient, capabilities?: readonly NodeCapability[] | undefined);
|
|
25
25
|
/**
|
|
26
|
-
*
|
|
26
|
+
* Registers the personal organization/subject index and returns its Offer.
|
|
27
|
+
* Wallet creation, activation exchange, DCR, and session opening are later
|
|
28
|
+
* `ServerProfileSessionManager` phases.
|
|
27
29
|
*/
|
|
28
|
-
|
|
30
|
+
registerIndividualOrganization(input: IndividualOrganizationRegistrationInput): Promise<IndividualOrganizationRegistrationResult>;
|
|
31
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
32
|
+
startIndividualOrganization(input: IndividualOrganizationRegistrationInput): Promise<IndividualOrganizationRegistrationResult>;
|
|
29
33
|
/**
|
|
30
34
|
* Searches one existing family/individual registration by the phone-first
|
|
31
35
|
* business key used by channel apps.
|
|
@@ -37,7 +41,9 @@ export declare class IndividualControllerSdk {
|
|
|
37
41
|
*/
|
|
38
42
|
ensureFamilyOrganizationRegistration(ctx: RouteContext, input: EnsureFamilyOrganizationRegistrationInput): Promise<EnsureFamilyOrganizationRegistrationResult>;
|
|
39
43
|
/**
|
|
40
|
-
* Confirms the
|
|
44
|
+
* Confirms the Offer returned by `registerIndividualOrganization(...)` and
|
|
45
|
+
* returns the opaque controller `activationCode` required by profile
|
|
46
|
+
* enrollment.
|
|
41
47
|
*/
|
|
42
48
|
confirmIndividualOrganizationOrder(input: IndividualOrganizationConfirmOrderInput): Promise<IndividualOrganizationOrderResult>;
|
|
43
49
|
/**
|
|
@@ -23,11 +23,17 @@ export class IndividualControllerSdk {
|
|
|
23
23
|
this.capabilities = capabilities;
|
|
24
24
|
}
|
|
25
25
|
/**
|
|
26
|
-
*
|
|
26
|
+
* Registers the personal organization/subject index and returns its Offer.
|
|
27
|
+
* Wallet creation, activation exchange, DCR, and session opening are later
|
|
28
|
+
* `ServerProfileSessionManager` phases.
|
|
27
29
|
*/
|
|
30
|
+
registerIndividualOrganization(input) {
|
|
31
|
+
assertFacadeCapability(this.capabilities, ActorCapabilities.IndividualBootstrap, ActorKinds.IndividualController, 'registerIndividualOrganization');
|
|
32
|
+
return requireClientMethod(this.client, 'registerIndividualOrganization')(input);
|
|
33
|
+
}
|
|
34
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
28
35
|
startIndividualOrganization(input) {
|
|
29
|
-
|
|
30
|
-
return requireClientMethod(this.client, 'startIndividualOrganization')(input);
|
|
36
|
+
return this.registerIndividualOrganization(input);
|
|
31
37
|
}
|
|
32
38
|
/**
|
|
33
39
|
* Searches one existing family/individual registration by the phone-first
|
|
@@ -44,7 +50,9 @@ export class IndividualControllerSdk {
|
|
|
44
50
|
return requireClientMethod(this.client, 'ensureFamilyOrganizationRegistration')(ctx, input);
|
|
45
51
|
}
|
|
46
52
|
/**
|
|
47
|
-
* Confirms the
|
|
53
|
+
* Confirms the Offer returned by `registerIndividualOrganization(...)` and
|
|
54
|
+
* returns the opaque controller `activationCode` required by profile
|
|
55
|
+
* enrollment.
|
|
48
56
|
*/
|
|
49
57
|
confirmIndividualOrganizationOrder(input) {
|
|
50
58
|
assertFacadeCapability(this.capabilities, ActorCapabilities.IndividualBootstrap, ActorKinds.IndividualController, 'confirmIndividualOrganizationOrder');
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
import { type NodeRuntimeClient, type PollOptions, type SubmitAndPollResult, type SubmitPayload } from './client-port.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { IndividualOrganizationRegistrationInput, IndividualOrganizationRegistrationResult } from '../individual-start.js';
|
|
3
3
|
import type { RouteContext } from '../individual-onboarding.js';
|
|
4
4
|
import type { BlockchainArtifactRegistrationInput, ClinicalBundleSearchInput, ClinicalSectionUpdateInput, ClinicalSummaryReadResult, ClinicalSummaryRequestInput, ClinicalSummaryUpdateInput, CommunicationIngestionInput, CommunicationParticipantRuntimeSearchInput, DigitalTwinGenerationInput, GrantProfessionalAccessInput, GrantProfessionalAccessResult, ProfessionalAccessRequestDecisionInput, ProfessionalAccessRequestSearchInput, IpsOrFhirImportInput, LicenseListRuntimeSearchInput, LicenseOfferRuntimeSearchInput, LicenseOrderRuntimeSearchInput } from '../resource-operations.js';
|
|
5
5
|
import type { SmartTokenExchangeResult, SmartTokenRequestInput } from '../smart-token.js';
|
|
6
6
|
export declare class PersonalSdk {
|
|
7
7
|
private readonly client;
|
|
8
8
|
constructor(client: NodeRuntimeClient);
|
|
9
|
-
/**
|
|
10
|
-
|
|
9
|
+
/** Registers the personal organization/subject index and returns its Offer. */
|
|
10
|
+
registerIndividualOrganization(input: IndividualOrganizationRegistrationInput): Promise<IndividualOrganizationRegistrationResult>;
|
|
11
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
12
|
+
startIndividualOrganization(input: IndividualOrganizationRegistrationInput): Promise<IndividualOrganizationRegistrationResult>;
|
|
11
13
|
/** Grants professional access via Consent for a subject. */
|
|
12
14
|
grantProfessionalAccess(ctx: RouteContext, input: GrantProfessionalAccessInput): Promise<GrantProfessionalAccessResult>;
|
|
13
15
|
/** Approves or denies a permission request while retaining its correlation. */
|
|
@@ -6,9 +6,13 @@ export class PersonalSdk {
|
|
|
6
6
|
constructor(client) {
|
|
7
7
|
this.client = client;
|
|
8
8
|
}
|
|
9
|
-
/**
|
|
9
|
+
/** Registers the personal organization/subject index and returns its Offer. */
|
|
10
|
+
registerIndividualOrganization(input) {
|
|
11
|
+
return requireClientMethod(this.client, 'registerIndividualOrganization')(input);
|
|
12
|
+
}
|
|
13
|
+
/** @deprecated Use `registerIndividualOrganization`. */
|
|
10
14
|
startIndividualOrganization(input) {
|
|
11
|
-
return
|
|
15
|
+
return this.registerIndividualOrganization(input);
|
|
12
16
|
}
|
|
13
17
|
/** Grants professional access via Consent for a subject. */
|
|
14
18
|
grantProfessionalAccess(ctx, input) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gdc-sdk-node-ts",
|
|
3
|
-
"version": "2.9.
|
|
3
|
+
"version": "2.9.3",
|
|
4
4
|
"description": "Next-generation Node runtime package for the GDC SDK family",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "Antifraud Services Inc.",
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"scripts": {
|
|
14
14
|
"build": "tsc -p tsconfig.json",
|
|
15
15
|
"prepare": "npm run build",
|
|
16
|
-
"type-check": "tsc -p tsconfig.json --noEmit",
|
|
16
|
+
"type-check": "tsc -p tsconfig.json --noEmit && tsc -p docs/snippets/tsconfig.json",
|
|
17
17
|
"check:product-neutrality": "node scripts/check-product-neutrality.mjs",
|
|
18
18
|
"prepublishOnly": "npm run check:product-neutrality && npm run type-check && npm test",
|
|
19
19
|
"local:close": "PORTS=3000 bash ./scripts/local-close.sh",
|