@frankieone/one-sdk 1.9.20-rc.4 → 1.9.21-rc
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 +279 -371
- package/dist/cli/darwin-amd64/onesdk-cli +0 -0
- package/dist/cli/darwin-arm64/onesdk-cli +0 -0
- package/dist/cli/linux-amd64/onesdk-cli +0 -0
- package/dist/cli/linux-arm64/onesdk-cli +0 -0
- package/dist/cli/windows-amd64/onesdk-cli.exe +0 -0
- package/dist/commit.txt +1 -1
- package/dist/esm/modules/common/shared/models/F2/Individual.d.ts.map +1 -1
- package/dist/esm/modules/common/shared/models/F2/Individual.js +33 -15
- package/dist/esm/modules/common/shared/models/F2/Individual.js.map +1 -1
- package/dist/esm/modules/common/shared/models/F2/Name.d.ts +1 -1
- package/dist/esm/modules/common/shared/models/F2/Name.d.ts.map +1 -1
- package/dist/esm/modules/common/shared/models/F2/Name.js +2 -2
- package/dist/esm/modules/common/shared/models/F2/Name.js.map +1 -1
- package/dist/esm/modules/form/vendors/react/features/PersonalDetails/PersonalDetails.d.ts.map +1 -1
- package/dist/esm/modules/form/vendors/react/features/PersonalDetails/PersonalDetails.js +8 -1
- package/dist/esm/modules/form/vendors/react/features/PersonalDetails/PersonalDetails.js.map +1 -1
- package/dist/esm/modules/form/vendors/react/features/PersonalDetails/personalDetails.config.d.ts.map +1 -1
- package/dist/esm/modules/form/vendors/react/features/PersonalDetails/personalDetails.config.js +14 -0
- package/dist/esm/modules/form/vendors/react/features/PersonalDetails/personalDetails.config.js.map +1 -1
- package/dist/esm/modules/form/vendors/react/features/Review/review.const.d.ts.map +1 -1
- package/dist/esm/modules/form/vendors/react/features/Review/review.const.js +14 -0
- package/dist/esm/modules/form/vendors/react/features/Review/review.const.js.map +1 -1
- package/dist/esm/modules/form/vendors/react/hooks/useManualConfigFactory.hook.d.ts.map +1 -1
- package/dist/esm/modules/form/vendors/react/hooks/useManualConfigFactory.hook.js +8 -7
- package/dist/esm/modules/form/vendors/react/hooks/useManualConfigFactory.hook.js.map +1 -1
- package/dist/esm/modules/form/vendors/react/hooks/usePersonalDetailsUpdateFactory.hook.d.ts.map +1 -1
- package/dist/esm/modules/form/vendors/react/hooks/usePersonalDetailsUpdateFactory.hook.js +6 -2
- package/dist/esm/modules/form/vendors/react/hooks/usePersonalDetailsUpdateFactory.hook.js.map +1 -1
- package/dist/esm/modules/form/vendors/react/hooks/useReviewUpdateFactory.hook.d.ts +3 -1
- package/dist/esm/modules/form/vendors/react/hooks/useReviewUpdateFactory.hook.d.ts.map +1 -1
- package/dist/esm/modules/form/vendors/react/hooks/useReviewUpdateFactory.hook.js +12 -6
- package/dist/esm/modules/form/vendors/react/hooks/useReviewUpdateFactory.hook.js.map +1 -1
- package/dist/esm/modules/idv/vendors/common/iframeUtils/daonErrorMapping.d.ts +13 -0
- package/dist/esm/modules/idv/vendors/common/iframeUtils/daonErrorMapping.d.ts.map +1 -0
- package/dist/esm/modules/idv/vendors/common/iframeUtils/daonErrorMapping.js +43 -0
- package/dist/esm/modules/idv/vendors/common/iframeUtils/daonErrorMapping.js.map +1 -0
- package/dist/esm/modules/idv/vendors/common/iframeUtils/defineIframeIDVWrapper.d.ts.map +1 -1
- package/dist/esm/modules/idv/vendors/common/iframeUtils/defineIframeIDVWrapper.js +14 -2
- package/dist/esm/modules/idv/vendors/common/iframeUtils/defineIframeIDVWrapper.js.map +1 -1
- package/dist/esm/modules/idv/vendors/common/iframeUtils/getInitProcessResults.d.ts +5 -4
- package/dist/esm/modules/idv/vendors/common/iframeUtils/getInitProcessResults.d.ts.map +1 -1
- package/dist/esm/modules/idv/vendors/common/iframeUtils/getInitProcessResults.js.map +1 -1
- package/dist/esm/modules/idv/vendors/common/iframeUtils/getOCRProcessResults.d.ts +22 -0
- package/dist/esm/modules/idv/vendors/common/iframeUtils/getOCRProcessResults.d.ts.map +1 -0
- package/dist/esm/modules/idv/vendors/common/iframeUtils/getOCRProcessResults.js +36 -0
- package/dist/esm/modules/idv/vendors/common/iframeUtils/getOCRProcessResults.js.map +1 -0
- package/dist/esm/modules/meta.json +1 -1
- package/dist/release.txt +1 -1
- package/dist/version.txt +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -10,19 +10,19 @@ FrankieOne OneSDK - A comprehensive frontend SDK library for identity verificati
|
|
|
10
10
|
|
|
11
11
|
## Table of Contents
|
|
12
12
|
|
|
13
|
-
-
|
|
14
|
-
-
|
|
15
|
-
-
|
|
16
|
-
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
-
|
|
24
|
-
-
|
|
25
|
-
-
|
|
13
|
+
- [Overview](#overview)
|
|
14
|
+
- [Architecture](#architecture)
|
|
15
|
+
- [Module Overview](#module-overview)
|
|
16
|
+
- [Vendor Integrations](#vendor-integrations)
|
|
17
|
+
- [IDV (Identity Verification)](#idv-identity-verification)
|
|
18
|
+
- [OCR (Document Recognition)](#ocr-document-recognition)
|
|
19
|
+
- [Biometrics](#biometrics)
|
|
20
|
+
- [Device Fingerprinting](#device-fingerprinting)
|
|
21
|
+
- [Federation](#federation)
|
|
22
|
+
- [Form](#form)
|
|
23
|
+
- [Integration Method Reference](#integration-method-reference)
|
|
24
|
+
- [Build & Development](#build--development)
|
|
25
|
+
- [Deployment](#deployment)
|
|
26
26
|
|
|
27
27
|
---
|
|
28
28
|
|
|
@@ -35,13 +35,13 @@ This is a **hybrid monorepo** containing:
|
|
|
35
35
|
|
|
36
36
|
### Key Technologies
|
|
37
37
|
|
|
38
|
-
| Category
|
|
39
|
-
|
|
38
|
+
| Category | Technologies |
|
|
39
|
+
|----------|-------------|
|
|
40
40
|
| **Frontend** | React 18.2, Redux Toolkit 2.2.1, TypeScript 5.7, Webpack 5, Vite 7.2 |
|
|
41
|
-
| **Styling**
|
|
42
|
-
| **Testing**
|
|
43
|
-
| **Reactive** | RxJS 7.5, Zod 3.19
|
|
44
|
-
| **CLI**
|
|
41
|
+
| **Styling** | TailwindCSS 3.4, Sass, PostCSS |
|
|
42
|
+
| **Testing** | Jest 28, ts-jest |
|
|
43
|
+
| **Reactive** | RxJS 7.5, Zod 3.19 |
|
|
44
|
+
| **CLI** | Go 1.21.5, Charmbracelet (huh, lipgloss, bubbles) |
|
|
45
45
|
|
|
46
46
|
---
|
|
47
47
|
|
|
@@ -71,14 +71,14 @@ OneSDK (index.ts)
|
|
|
71
71
|
|
|
72
72
|
## Module Overview
|
|
73
73
|
|
|
74
|
-
| Module
|
|
75
|
-
|
|
76
|
-
| **IDV**
|
|
77
|
-
| **OCR**
|
|
78
|
-
| **Biometrics** | Face capture & liveness detection
|
|
79
|
-
| **Device**
|
|
80
|
-
| **Federation** | Federated identity (OAuth)
|
|
81
|
-
| **Form**
|
|
74
|
+
| Module | Purpose | Vendors |
|
|
75
|
+
|--------|---------|---------|
|
|
76
|
+
| **IDV** | Full identity verification flow | Onfido, Sumsub, Incode, Daon, Mastercard, Truuth, OcrLabs, IDVerse |
|
|
77
|
+
| **OCR** | Document scanning & data extraction | Onfido, Sumsub, Incode, Daon, IDVerse |
|
|
78
|
+
| **Biometrics** | Face capture & liveness detection | Onfido, Sumsub, Incode, Daon, OcrLabs, IDVerse |
|
|
79
|
+
| **Device** | Device fingerprinting | Sardine, ThreatMetrix |
|
|
80
|
+
| **Federation** | Federated identity (OAuth) | Singpass |
|
|
81
|
+
| **Form** | Data entry & review forms | Formio, React, Legacy |
|
|
82
82
|
|
|
83
83
|
---
|
|
84
84
|
|
|
@@ -88,95 +88,85 @@ OneSDK (index.ts)
|
|
|
88
88
|
|
|
89
89
|
#### Onfido
|
|
90
90
|
|
|
91
|
-
| Aspect
|
|
92
|
-
|
|
93
|
-
| **Integration Method** | Native SDK loaded from CDN
|
|
94
|
-
| **SDK Source**
|
|
95
|
-
| **UI Type**
|
|
96
|
-
| **Version Support**
|
|
91
|
+
| Aspect | Details |
|
|
92
|
+
|--------|---------|
|
|
93
|
+
| **Integration Method** | Native SDK loaded from CDN |
|
|
94
|
+
| **SDK Source** | `https://sdk.onfido.com/v{version}` |
|
|
95
|
+
| **UI Type** | Vendor-provided UI with theme customization |
|
|
96
|
+
| **Version Support** | v14+ (modern) and <v14 (legacy modal-based) |
|
|
97
97
|
|
|
98
98
|
**Modes:**
|
|
99
|
-
|
|
100
|
-
-
|
|
101
|
-
- **Dual Component Mode**: Separate OCR → Biometrics chain
|
|
99
|
+
- **OneStep Mode** (`useOneStep: true`): Combined document + face capture in single SDK instance
|
|
100
|
+
- **Dual Component Mode**: Separate OCR → Biometrics chain
|
|
102
101
|
|
|
103
102
|
**Key Features:**
|
|
104
|
-
|
|
105
|
-
-
|
|
106
|
-
-
|
|
107
|
-
-
|
|
108
|
-
-
|
|
109
|
-
- Document type configuration: Passport, Drivers License, Medicare
|
|
103
|
+
- Theme support: `'light'` or `'dark'` with full `customUI` configuration
|
|
104
|
+
- Cross-device linking: QR code, copy link, SMS options
|
|
105
|
+
- Exit button support
|
|
106
|
+
- Analytics disabled by default
|
|
107
|
+
- Document type configuration: Passport, Drivers License, Medicare
|
|
110
108
|
|
|
111
109
|
**Events Emitted:**
|
|
112
|
-
|
|
113
|
-
-
|
|
114
|
-
- `results`, `session_closed`, `session_interrupted`, `vendor_event`
|
|
110
|
+
- `ready`, `loading`, `error`, `detection_complete`, `detection_failed`
|
|
111
|
+
- `results`, `session_closed`, `session_interrupted`, `vendor_event`
|
|
115
112
|
|
|
116
113
|
**Files:**
|
|
117
|
-
|
|
118
|
-
-
|
|
119
|
-
-
|
|
120
|
-
-
|
|
121
|
-
- `modules/common/vendors/onfido/`
|
|
114
|
+
- `modules/idv/vendors/Onfido/index.ts`
|
|
115
|
+
- `modules/ocr/vendors/Onfido/` (onfido.init.ts, onfidoLegacy.init.ts)
|
|
116
|
+
- `modules/biometrics/vendors/Onfido/`
|
|
117
|
+
- `modules/common/vendors/onfido/`
|
|
122
118
|
|
|
123
119
|
---
|
|
124
120
|
|
|
125
121
|
#### Sumsub
|
|
126
122
|
|
|
127
|
-
| Aspect
|
|
128
|
-
|
|
129
|
-
| **Integration Method** | SDK Library with iframe UI
|
|
130
|
-
| **SDK Source**
|
|
131
|
-
| **UI Type**
|
|
132
|
-
| **Products**
|
|
123
|
+
| Aspect | Details |
|
|
124
|
+
|--------|---------|
|
|
125
|
+
| **Integration Method** | SDK Library with iframe UI |
|
|
126
|
+
| **SDK Source** | `https://static.sumsub.com/idensic/static/sns-websdk-builder.js` |
|
|
127
|
+
| **UI Type** | Vendor-provided iframe |
|
|
128
|
+
| **Products** | `'idv'`, `'ocr'`, `'poa'` |
|
|
133
129
|
|
|
134
130
|
**Initialization Flow:**
|
|
135
|
-
|
|
136
131
|
```javascript
|
|
137
|
-
snsWebSdk
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
.launch(mountElement);
|
|
132
|
+
snsWebSdk.init(token, refreshTokenCallback)
|
|
133
|
+
.withConf({ theme: 'light' })
|
|
134
|
+
.withOptions({ addViewportTag: false, adaptIframeHeight: true })
|
|
135
|
+
.on('idCheck.onError', errorHandler)
|
|
136
|
+
.onMessage(messageHandler)
|
|
137
|
+
.build()
|
|
138
|
+
.launch(mountElement)
|
|
145
139
|
```
|
|
146
140
|
|
|
147
141
|
**Message Types:**
|
|
148
|
-
|
|
149
|
-
-
|
|
150
|
-
-
|
|
151
|
-
-
|
|
152
|
-
- `idCheck.onUploadError` - Upload failures
|
|
142
|
+
- `idCheck.onReady` - SDK loading
|
|
143
|
+
- `idCheck.onInitialized` - UI ready
|
|
144
|
+
- `idCheck.onApplicantStatusChanged` - Review status changes (pending → completed)
|
|
145
|
+
- `idCheck.onUploadError` - Upload failures
|
|
153
146
|
|
|
154
147
|
**Files:**
|
|
155
|
-
|
|
156
|
-
-
|
|
157
|
-
-
|
|
158
|
-
-
|
|
159
|
-
- `modules/common/vendors/sumsub/`
|
|
148
|
+
- `modules/idv/vendors/Sumsub/index.ts`
|
|
149
|
+
- `modules/ocr/vendors/Sumsub/index.ts`
|
|
150
|
+
- `modules/biometrics/vendors/Sumsub/index.ts`
|
|
151
|
+
- `modules/common/vendors/sumsub/`
|
|
160
152
|
|
|
161
153
|
---
|
|
162
154
|
|
|
163
155
|
#### Incode
|
|
164
156
|
|
|
165
|
-
| Aspect
|
|
166
|
-
|
|
157
|
+
| Aspect | Details |
|
|
158
|
+
|--------|---------|
|
|
167
159
|
| **Integration Method** | Native SDK + Camera (OCR/Biometrics) or Iframe (IDV) |
|
|
168
|
-
| **SDK Source**
|
|
169
|
-
| **Default Version**
|
|
170
|
-
| **UI Type**
|
|
160
|
+
| **SDK Source** | `https://sdk.incode.com/sdk/onBoarding-{version}.js` |
|
|
161
|
+
| **Default Version** | 1.75.2 |
|
|
162
|
+
| **UI Type** | Custom camera UI with document selector |
|
|
171
163
|
|
|
172
164
|
**Camera Types:**
|
|
173
|
-
|
|
174
|
-
-
|
|
175
|
-
-
|
|
176
|
-
- `'selfie'` - Face capture
|
|
165
|
+
- `'front'` - Document front side
|
|
166
|
+
- `'back'` - Document back side
|
|
167
|
+
- `'selfie'` - Face capture
|
|
177
168
|
|
|
178
169
|
**Document Type Mapping:**
|
|
179
|
-
|
|
180
170
|
```javascript
|
|
181
171
|
Passport → 'PASSPORT'
|
|
182
172
|
DriversLicense → 'DRIVERS_LICENCE'
|
|
@@ -184,79 +174,67 @@ MedicalCard → 'NATIONAL_HEALTH_ID'
|
|
|
184
174
|
```
|
|
185
175
|
|
|
186
176
|
**IDV Iframe Mode:**
|
|
187
|
-
|
|
188
|
-
-
|
|
189
|
-
-
|
|
190
|
-
-
|
|
191
|
-
- Session key: `interviewId`
|
|
177
|
+
- PostMessage protocol with workflow messages
|
|
178
|
+
- Success: `{ workflow: 'INCODE_COMPLETE' }`
|
|
179
|
+
- Error: `{ workflow: 'INCODE_ERROR' }`
|
|
180
|
+
- Session key: `interviewId`
|
|
192
181
|
|
|
193
182
|
**Special Handling:**
|
|
194
|
-
|
|
195
|
-
-
|
|
196
|
-
-
|
|
197
|
-
- Consent reflow fix for iOS WebKit
|
|
183
|
+
- Memory out of bounds error detection via console.error override
|
|
184
|
+
- Country/region document validation
|
|
185
|
+
- Consent reflow fix for iOS WebKit
|
|
198
186
|
|
|
199
187
|
**Files:**
|
|
200
|
-
|
|
201
|
-
-
|
|
202
|
-
-
|
|
203
|
-
-
|
|
204
|
-
- `modules/common/vendors/incode/`
|
|
188
|
+
- `modules/idv/vendors/Incode/index.ts`
|
|
189
|
+
- `modules/ocr/vendors/Incode/index.ts`
|
|
190
|
+
- `modules/biometrics/vendors/Incode/index.ts`
|
|
191
|
+
- `modules/common/vendors/incode/`
|
|
205
192
|
|
|
206
193
|
---
|
|
207
194
|
|
|
208
195
|
#### Daon
|
|
209
196
|
|
|
210
|
-
| Aspect
|
|
211
|
-
|
|
197
|
+
| Aspect | Details |
|
|
198
|
+
|--------|---------|
|
|
212
199
|
| **Integration Method** | Iframe + PostMessage protocol |
|
|
213
|
-
| **UI Type**
|
|
214
|
-
| **Modules**
|
|
200
|
+
| **UI Type** | Vendor-provided iframe |
|
|
201
|
+
| **Modules** | IDV, OCR, Biometrics |
|
|
215
202
|
|
|
216
203
|
**Message Format:**
|
|
217
|
-
|
|
218
204
|
```javascript
|
|
219
205
|
// Success
|
|
220
|
-
{
|
|
221
|
-
workflow: 'DAON_COMPLETE';
|
|
222
|
-
}
|
|
206
|
+
{ workflow: 'DAON_COMPLETE' }
|
|
223
207
|
|
|
224
208
|
// Error
|
|
225
|
-
{
|
|
226
|
-
workflow: 'DAON_ERROR';
|
|
227
|
-
}
|
|
209
|
+
{ workflow: 'DAON_ERROR' }
|
|
228
210
|
```
|
|
229
211
|
|
|
230
212
|
**Post-Iframe Actions:**
|
|
231
|
-
|
|
232
|
-
-
|
|
233
|
-
-
|
|
234
|
-
- Biometrics: `initProcessBiometrics` (with window event listener)
|
|
213
|
+
- IDV: `initProcess` (default)
|
|
214
|
+
- OCR: `initProcessAndEvaluateResults`
|
|
215
|
+
- Biometrics: `initProcessBiometrics` (with window event listener)
|
|
235
216
|
|
|
236
217
|
**Check Processing Pool:**
|
|
237
|
-
|
|
238
|
-
-
|
|
239
|
-
-
|
|
240
|
-
- `max_attempts: 3`
|
|
218
|
+
- Enabled by default for Daon
|
|
219
|
+
- `wait_time: 5` seconds
|
|
220
|
+
- `max_attempts: 3`
|
|
241
221
|
|
|
242
222
|
**Files:**
|
|
243
|
-
|
|
244
|
-
-
|
|
245
|
-
-
|
|
246
|
-
- `modules/biometrics/vendors/Daon/index.ts`
|
|
223
|
+
- `modules/idv/vendors/Daon/index.ts`
|
|
224
|
+
- `modules/ocr/vendors/Daon/index.ts`
|
|
225
|
+
- `modules/biometrics/vendors/Daon/index.ts`
|
|
247
226
|
|
|
248
227
|
---
|
|
249
228
|
|
|
250
229
|
#### Mastercard
|
|
251
230
|
|
|
252
|
-
| Aspect
|
|
253
|
-
|
|
231
|
+
| Aspect | Details |
|
|
232
|
+
|--------|---------|
|
|
254
233
|
| **Integration Method** | Iframe + JSON PostMessage |
|
|
255
|
-
| **UI Type**
|
|
256
|
-
| **Session Key**
|
|
234
|
+
| **UI Type** | Vendor-provided iframe |
|
|
235
|
+
| **Session Key** | `workflowExecutionId` |
|
|
257
236
|
|
|
258
237
|
**Message Format (Stringified JSON):**
|
|
259
|
-
|
|
260
238
|
```javascript
|
|
261
239
|
// Loaded
|
|
262
240
|
{ "payload": { "value": "loaded" } }
|
|
@@ -271,56 +249,50 @@ MedicalCard → 'NATIONAL_HEALTH_ID'
|
|
|
271
249
|
**Key Difference:** Mastercard emits its own 'loaded' message (`emitOnLoad: false`)
|
|
272
250
|
|
|
273
251
|
**Files:**
|
|
274
|
-
|
|
275
|
-
- `modules/idv/vendors/Mastercard/index.ts`
|
|
252
|
+
- `modules/idv/vendors/Mastercard/index.ts`
|
|
276
253
|
|
|
277
254
|
---
|
|
278
255
|
|
|
279
256
|
#### Truuth
|
|
280
257
|
|
|
281
|
-
| Aspect
|
|
282
|
-
|
|
283
|
-
| **Integration Method** | Web Component SDK (NOT iframe)
|
|
284
|
-
| **SDK Source**
|
|
285
|
-
| **UI Type**
|
|
258
|
+
| Aspect | Details |
|
|
259
|
+
|--------|---------|
|
|
260
|
+
| **Integration Method** | Web Component SDK (NOT iframe) |
|
|
261
|
+
| **SDK Source** | `https://cdn.truuth.id/kyc/websdk/{version}/truuth-kyc-websdk.js` |
|
|
262
|
+
| **UI Type** | `<truuth-kyc>` custom element |
|
|
286
263
|
|
|
287
264
|
**Event Handling:**
|
|
288
|
-
|
|
289
265
|
```javascript
|
|
290
|
-
window.addEventListener('forwardedTruuthEventForOneSDK', eventListener)
|
|
266
|
+
window.addEventListener('forwardedTruuthEventForOneSDK', eventListener)
|
|
291
267
|
```
|
|
292
268
|
|
|
293
269
|
**Event Types:**
|
|
294
|
-
|
|
295
|
-
-
|
|
296
|
-
-
|
|
297
|
-
-
|
|
298
|
-
-
|
|
299
|
-
-
|
|
300
|
-
- `ERROR` → detection_failed + error
|
|
270
|
+
- `VERIFICATION_PROCESSING_STARTED` → loading + detection_complete + polling
|
|
271
|
+
- `VERIFICATION_COMPLETED` → initProcess + results
|
|
272
|
+
- `TERMS_AND_CONDITION_DECLINED` → input_required
|
|
273
|
+
- `VERIFICATION_SUBMISSION_ABORTED` → input_required
|
|
274
|
+
- `VERIFICATION_PROCESSING_TIMEOUT` → error
|
|
275
|
+
- `ERROR` → detection_failed + error
|
|
301
276
|
|
|
302
277
|
**Files:**
|
|
303
|
-
|
|
304
|
-
- `modules/idv/vendors/Truuth/index.ts`
|
|
278
|
+
- `modules/idv/vendors/Truuth/index.ts`
|
|
305
279
|
|
|
306
280
|
---
|
|
307
281
|
|
|
308
282
|
#### OcrLabs
|
|
309
283
|
|
|
310
|
-
| Aspect
|
|
311
|
-
|
|
312
|
-
| **IDV Integration**
|
|
313
|
-
| **Biometrics Integration** | WebSocket + WebRTC (liveness detection)
|
|
314
|
-
| **WebSocket URL**
|
|
284
|
+
| Aspect | Details |
|
|
285
|
+
|--------|---------|
|
|
286
|
+
| **IDV Integration** | Server-side action workflow with persistent storage |
|
|
287
|
+
| **Biometrics Integration** | WebSocket + WebRTC (liveness detection) |
|
|
288
|
+
| **WebSocket URL** | `wss://engine.au.v3.liveness.idkit.io` |
|
|
315
289
|
|
|
316
290
|
**IDV Flow:**
|
|
317
|
-
|
|
318
291
|
1. Check StorageClient for stored action details
|
|
319
292
|
2. Workflow states: `IDV_SUCCESS` or `IDV_ERROR`
|
|
320
293
|
3. Redirect to OcrLabs or start dummy flow
|
|
321
294
|
|
|
322
295
|
**Biometrics Liveness Detection:**
|
|
323
|
-
|
|
324
296
|
```
|
|
325
297
|
Face Detection → "Position your face within the frame"
|
|
326
298
|
↓
|
|
@@ -330,71 +302,63 @@ detection_complete → initProcess
|
|
|
330
302
|
```
|
|
331
303
|
|
|
332
304
|
**UI Elements Created:**
|
|
333
|
-
|
|
334
|
-
-
|
|
335
|
-
-
|
|
336
|
-
-
|
|
337
|
-
-
|
|
338
|
-
- `onesdk_idv_instructions` - Dynamic instructions
|
|
305
|
+
- `onesdk_idv_container` - Main container
|
|
306
|
+
- `onesdk_idv_video` - Live video feed (mirrored)
|
|
307
|
+
- `onesdk_idv_overlay` - Overlay container
|
|
308
|
+
- `onesdk_idv_mask` - Oval face frame with shadow
|
|
309
|
+
- `onesdk_idv_instructions` - Dynamic instructions
|
|
339
310
|
|
|
340
311
|
**Detection Timeout:** 7.5 seconds per action
|
|
341
312
|
|
|
342
313
|
**Files:**
|
|
343
|
-
|
|
344
|
-
-
|
|
345
|
-
- `modules/biometrics/vendors/OcrLabs/`
|
|
314
|
+
- `modules/idv/vendors/OcrLabs/`
|
|
315
|
+
- `modules/biometrics/vendors/OcrLabs/`
|
|
346
316
|
|
|
347
317
|
---
|
|
348
318
|
|
|
349
319
|
#### IDVerse
|
|
350
320
|
|
|
351
|
-
| Aspect
|
|
352
|
-
|
|
353
|
-
| **Integration Method** | Web Component + Web Worker
|
|
354
|
-
| **SDK Source**
|
|
355
|
-
| **UI Type**
|
|
356
|
-
| **Build ID**
|
|
321
|
+
| Aspect | Details |
|
|
322
|
+
|--------|---------|
|
|
323
|
+
| **Integration Method** | Web Component + Web Worker |
|
|
324
|
+
| **SDK Source** | ESM module from CDN |
|
|
325
|
+
| **UI Type** | `<idverse-sdk-ui>` custom element |
|
|
326
|
+
| **Build ID** | `build_01K7RRTN6RTH4S3MGHEBDDJ3FV` |
|
|
357
327
|
|
|
358
328
|
**Recognizer Types:**
|
|
359
|
-
|
|
360
|
-
-
|
|
361
|
-
- `'face-scan'` - Biometric face capture with liveness
|
|
329
|
+
- `'id-scan'` - Document scanning with front/back capture
|
|
330
|
+
- `'face-scan'` - Biometric face capture with liveness
|
|
362
331
|
|
|
363
332
|
**Web Worker:**
|
|
364
|
-
|
|
365
|
-
-
|
|
366
|
-
-
|
|
367
|
-
- Manually terminated on SDK destroy
|
|
333
|
+
- Cross-origin blob worker for image processing
|
|
334
|
+
- Created via `URL.createObjectURL(blob)`
|
|
335
|
+
- Manually terminated on SDK destroy
|
|
368
336
|
|
|
369
337
|
**Event Types:**
|
|
370
|
-
|
|
371
|
-
-
|
|
372
|
-
-
|
|
373
|
-
-
|
|
374
|
-
-
|
|
375
|
-
-
|
|
376
|
-
-
|
|
377
|
-
- `faceScanClosed` - Face scan modal closed
|
|
338
|
+
- `authenticated` - SDK initialized
|
|
339
|
+
- `ready` - Web component ready
|
|
340
|
+
- `scanSuccess` - Scan completed successfully
|
|
341
|
+
- `scanFail` - Scan failed (with error codes)
|
|
342
|
+
- `validDocumentConfirmed` - User confirmed document
|
|
343
|
+
- `fatalError` - Unrecoverable error
|
|
344
|
+
- `faceScanClosed` - Face scan modal closed
|
|
378
345
|
|
|
379
346
|
**Retry Logic:**
|
|
380
|
-
|
|
381
|
-
-
|
|
382
|
-
-
|
|
383
|
-
- SDK destroyed when max retries exceeded
|
|
347
|
+
- Default max retries: 3 (configurable via recipe)
|
|
348
|
+
- `scanFail` increments counter
|
|
349
|
+
- SDK destroyed when max retries exceeded
|
|
384
350
|
|
|
385
351
|
**Asset Bundle (~2.2 MB):**
|
|
386
|
-
|
|
387
|
-
-
|
|
388
|
-
-
|
|
389
|
-
-
|
|
390
|
-
-
|
|
391
|
-
- WorkSans font: 354 KB
|
|
352
|
+
- Main bundle: 935 KB
|
|
353
|
+
- CSS: 113 KB
|
|
354
|
+
- Lottie animations: 700+ KB (20 animations)
|
|
355
|
+
- Audio feedback: 75+ KB
|
|
356
|
+
- WorkSans font: 354 KB
|
|
392
357
|
|
|
393
358
|
**Files:**
|
|
394
|
-
|
|
395
|
-
-
|
|
396
|
-
-
|
|
397
|
-
- `modules/biometrics/vendors/IDVerse/index.ts`
|
|
359
|
+
- `modules/common/vendors/idverse/index.ts`
|
|
360
|
+
- `modules/ocr/vendors/IDVerse/index.ts`
|
|
361
|
+
- `modules/biometrics/vendors/IDVerse/index.ts`
|
|
398
362
|
|
|
399
363
|
---
|
|
400
364
|
|
|
@@ -402,26 +366,26 @@ detection_complete → initProcess
|
|
|
402
366
|
|
|
403
367
|
OCR vendors share implementations with IDV where applicable. Key differences:
|
|
404
368
|
|
|
405
|
-
| Vendor
|
|
406
|
-
|
|
407
|
-
| Onfido
|
|
408
|
-
| Sumsub
|
|
409
|
-
| Incode
|
|
410
|
-
| Daon
|
|
411
|
-
| IDVerse | `initProcessAndEvaluateResults` | Feature flag controlled
|
|
369
|
+
| Vendor | Post-Process Action | Review Screen |
|
|
370
|
+
|--------|---------------------|---------------|
|
|
371
|
+
| Onfido | `initProcessAndEvaluateResults` | Feature flag controlled |
|
|
372
|
+
| Sumsub | `initProcess` (product='ocr') | Built-in |
|
|
373
|
+
| Incode | Native camera capture | Validation callback |
|
|
374
|
+
| Daon | `initProcessAndEvaluateResults` | Optional form attachment |
|
|
375
|
+
| IDVerse | `initProcessAndEvaluateResults` | Feature flag controlled |
|
|
412
376
|
|
|
413
377
|
---
|
|
414
378
|
|
|
415
379
|
### Biometrics
|
|
416
380
|
|
|
417
|
-
| Vendor
|
|
418
|
-
|
|
419
|
-
| **Onfido**
|
|
420
|
-
| **Sumsub**
|
|
421
|
-
| **Incode**
|
|
422
|
-
| **Daon**
|
|
423
|
-
| **OcrLabs** | WebRTC + WebSocket
|
|
424
|
-
| **IDVerse** | Web Component face-scan
|
|
381
|
+
| Vendor | Capture Method | Liveness Detection |
|
|
382
|
+
|--------|----------------|-------------------|
|
|
383
|
+
| **Onfido** | SDK face step | Motion, video, or standard variants |
|
|
384
|
+
| **Sumsub** | SDK (product='idv') | Built-in |
|
|
385
|
+
| **Incode** | Native camera selfie | SDK-managed |
|
|
386
|
+
| **Daon** | Iframe with window events | Vendor-managed |
|
|
387
|
+
| **OcrLabs** | WebRTC + WebSocket | Face + Smile detection |
|
|
388
|
+
| **IDVerse** | Web Component face-scan | DFA + face matching |
|
|
425
389
|
|
|
426
390
|
---
|
|
427
391
|
|
|
@@ -429,68 +393,59 @@ OCR vendors share implementations with IDV where applicable. Key differences:
|
|
|
429
393
|
|
|
430
394
|
#### Sardine
|
|
431
395
|
|
|
432
|
-
| Aspect
|
|
433
|
-
|
|
434
|
-
| **Integration Method** | Remote SDK with context-based configuration
|
|
435
|
-
| **SDK Source**
|
|
436
|
-
| **Environments**
|
|
396
|
+
| Aspect | Details |
|
|
397
|
+
|--------|---------|
|
|
398
|
+
| **Integration Method** | Remote SDK with context-based configuration |
|
|
399
|
+
| **SDK Source** | `https://api.{domain}.sardine.ai/assets/loader.min.js` |
|
|
400
|
+
| **Environments** | `api.sardine.ai` (production), `api.sandbox.sardine.ai` (sandbox) |
|
|
437
401
|
|
|
438
402
|
**Configuration:**
|
|
439
|
-
|
|
440
403
|
```javascript
|
|
441
404
|
window._Sardine.createContext({
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
},
|
|
450
|
-
});
|
|
405
|
+
clientId,
|
|
406
|
+
sessionKey,
|
|
407
|
+
environment: 'production' | 'sandbox',
|
|
408
|
+
parentElement: document.body,
|
|
409
|
+
flow: activityType,
|
|
410
|
+
onDeviceResponse: (data) => { /* fingerprint data */ }
|
|
411
|
+
})
|
|
451
412
|
```
|
|
452
413
|
|
|
453
414
|
**Activity Types:**
|
|
454
|
-
|
|
455
|
-
-
|
|
456
|
-
- `LOGIN`, `CRYPTO_DEPOSIT`, `CRYPTO_WITHDRAWAL`, `FIAT_DEPOSIT`, `FIAT_WITHDRAWAL`
|
|
415
|
+
- `REGISTRATION` → mapped to `SIGNUP`
|
|
416
|
+
- `LOGIN`, `CRYPTO_DEPOSIT`, `CRYPTO_WITHDRAWAL`, `FIAT_DEPOSIT`, `FIAT_WITHDRAWAL`
|
|
457
417
|
|
|
458
418
|
**Events:**
|
|
459
|
-
|
|
460
|
-
-
|
|
461
|
-
-
|
|
462
|
-
- `value_set`
|
|
419
|
+
- `session_data_generated`
|
|
420
|
+
- `device_characteristics_extracted`
|
|
421
|
+
- `value_set`
|
|
463
422
|
|
|
464
423
|
**Files:**
|
|
465
|
-
|
|
466
|
-
- `modules/device/vendors/Sardine.ts`
|
|
424
|
+
- `modules/device/vendors/Sardine.ts`
|
|
467
425
|
|
|
468
426
|
---
|
|
469
427
|
|
|
470
428
|
#### ThreatMetrix
|
|
471
429
|
|
|
472
|
-
| Aspect
|
|
473
|
-
|
|
474
|
-
| **Integration Method** | Obfuscated SDK (intentionally hidden)
|
|
475
|
-
| **SDK Source**
|
|
476
|
-
| **Domain**
|
|
430
|
+
| Aspect | Details |
|
|
431
|
+
|--------|---------|
|
|
432
|
+
| **Integration Method** | Obfuscated SDK (intentionally hidden) |
|
|
433
|
+
| **SDK Source** | Inline vendor file `nolint_fp-clientlib-v4.js` |
|
|
434
|
+
| **Domain** | `h.online-metrix.net` |
|
|
477
435
|
|
|
478
436
|
**Initialization:**
|
|
479
|
-
|
|
480
437
|
```javascript
|
|
481
|
-
threatmetrixSdk.profile('h.online-metrix.net', clientID, vendorSessionID)
|
|
438
|
+
threatmetrixSdk.profile('h.online-metrix.net', clientID, vendorSessionID)
|
|
482
439
|
```
|
|
483
440
|
|
|
484
441
|
**Technical Details:**
|
|
485
|
-
|
|
486
|
-
-
|
|
487
|
-
-
|
|
488
|
-
- CSP nonce handling for Content Security Policy compliance
|
|
442
|
+
- Uses RTCPeerConnection with TURN servers for data collection
|
|
443
|
+
- ClientID must be exactly 8 characters
|
|
444
|
+
- CSP nonce handling for Content Security Policy compliance
|
|
489
445
|
|
|
490
446
|
**Files:**
|
|
491
|
-
|
|
492
|
-
-
|
|
493
|
-
- `modules/device/vendors/Threatmetrix/nolint_fp-clientlib-v4.js`
|
|
447
|
+
- `modules/device/vendors/Threatmetrix/index.ts`
|
|
448
|
+
- `modules/device/vendors/Threatmetrix/nolint_fp-clientlib-v4.js`
|
|
494
449
|
|
|
495
450
|
---
|
|
496
451
|
|
|
@@ -498,13 +453,12 @@ threatmetrixSdk.profile('h.online-metrix.net', clientID, vendorSessionID);
|
|
|
498
453
|
|
|
499
454
|
#### Singpass (MyInfo)
|
|
500
455
|
|
|
501
|
-
| Aspect
|
|
502
|
-
|
|
503
|
-
| **Integration Method** | OAuth 2.0 Authorization Code Flow
|
|
504
|
-
| **Protocol**
|
|
456
|
+
| Aspect | Details |
|
|
457
|
+
|--------|---------|
|
|
458
|
+
| **Integration Method** | OAuth 2.0 Authorization Code Flow |
|
|
459
|
+
| **Protocol** | Browser redirect to Singpass, then code exchange |
|
|
505
460
|
|
|
506
461
|
**Environment URLs:**
|
|
507
|
-
|
|
508
462
|
```
|
|
509
463
|
Sandbox: https://sandbox.api.myinfo.gov.sg/com/v3/authorise
|
|
510
464
|
Test: https://test.api.myinfo.gov.sg/com/v3/authorise
|
|
@@ -512,7 +466,6 @@ Production: https://api.myinfo.gov.sg/com/v3/authorise
|
|
|
512
466
|
```
|
|
513
467
|
|
|
514
468
|
**OAuth Flow:**
|
|
515
|
-
|
|
516
469
|
1. Build authorization URL with `client_id`, `attributes`, `state`, `redirect_uri`, `purpose`
|
|
517
470
|
2. Redirect to Singpass
|
|
518
471
|
3. User authenticates and consents
|
|
@@ -523,20 +476,17 @@ Production: https://api.myinfo.gov.sg/com/v3/authorise
|
|
|
523
476
|
8. User approves → `FederationClient.submitCachedData()`
|
|
524
477
|
|
|
525
478
|
**Events:**
|
|
526
|
-
|
|
527
|
-
-
|
|
528
|
-
-
|
|
529
|
-
- `error` - On failures
|
|
479
|
+
- `results` - User data with approve callback
|
|
480
|
+
- `data_extracted_successfully` - After approval
|
|
481
|
+
- `error` - On failures
|
|
530
482
|
|
|
531
483
|
**Validation:**
|
|
532
|
-
|
|
533
|
-
-
|
|
534
|
-
-
|
|
535
|
-
- No preloaded entities allowed
|
|
484
|
+
- State parameter must match session ID
|
|
485
|
+
- Production `redirect_uri` must use HTTPS
|
|
486
|
+
- No preloaded entities allowed
|
|
536
487
|
|
|
537
488
|
**Files:**
|
|
538
|
-
|
|
539
|
-
- `modules/federation/vendors/Singpass.ts`
|
|
489
|
+
- `modules/federation/vendors/Singpass.ts`
|
|
540
490
|
|
|
541
491
|
---
|
|
542
492
|
|
|
@@ -544,29 +494,27 @@ Production: https://api.myinfo.gov.sg/com/v3/authorise
|
|
|
544
494
|
|
|
545
495
|
#### Form Vendors Overview
|
|
546
496
|
|
|
547
|
-
| Vendor
|
|
548
|
-
|
|
549
|
-
| **Formio** | Form.io SDK
|
|
550
|
-
| **React**
|
|
551
|
-
| **Legacy** | Legacy UI widgets
|
|
497
|
+
| Vendor | Technology | Use Case |
|
|
498
|
+
|--------|------------|----------|
|
|
499
|
+
| **Formio** | Form.io SDK | Cloud-based form builder |
|
|
500
|
+
| **React** | Custom React components | Modern, flexible forms |
|
|
501
|
+
| **Legacy** | Legacy UI widgets | Backward compatibility |
|
|
552
502
|
|
|
553
503
|
---
|
|
554
504
|
|
|
555
505
|
#### Formio
|
|
556
506
|
|
|
557
|
-
| Aspect
|
|
558
|
-
|
|
559
|
-
| **SDK Source**
|
|
560
|
-
| **CSS Dependencies** | Bootstrap 4.6.1, Formio CSS, FontAwesome 4.7
|
|
507
|
+
| Aspect | Details |
|
|
508
|
+
|--------|---------|
|
|
509
|
+
| **SDK Source** | `https://cdn.form.io/formiojs/formio.full.js` |
|
|
510
|
+
| **CSS Dependencies** | Bootstrap 4.6.1, Formio CSS, FontAwesome 4.7 |
|
|
561
511
|
|
|
562
512
|
**Wrapping Modes (feature flag controlled):**
|
|
563
|
-
|
|
564
|
-
-
|
|
565
|
-
-
|
|
566
|
-
- **Div** (`'div'`): Direct DOM insertion (default)
|
|
513
|
+
- **Shadow DOM** (`'shadow'`): Isolated styles via `attachShadow({ mode: 'open' })`
|
|
514
|
+
- **Iframe** (`'iframe'`): Complete DOM/CSS isolation
|
|
515
|
+
- **Div** (`'div'`): Direct DOM insertion (default)
|
|
567
516
|
|
|
568
517
|
**Data Transformation:**
|
|
569
|
-
|
|
570
518
|
```
|
|
571
519
|
Individual Data ←→ Formio Schema
|
|
572
520
|
│ │
|
|
@@ -576,31 +524,28 @@ Individual Data ←→ Formio Schema
|
|
|
576
524
|
```
|
|
577
525
|
|
|
578
526
|
**Document Type Mapping:**
|
|
579
|
-
|
|
580
|
-
-
|
|
581
|
-
-
|
|
582
|
-
- `NATIONAL_HEALTH_ID` → `medi_idNumber`, `medi_cardPosition`, `medi_cardColour`, `medi_idExpiry`
|
|
527
|
+
- `PASSPORT` → `pass_idNumber`, `pass_idExpiry`
|
|
528
|
+
- `DRIVERS_LICENCE` → `dl_region`, `dl_idNumber`, `dl_cardNumber`
|
|
529
|
+
- `NATIONAL_HEALTH_ID` → `medi_idNumber`, `medi_cardPosition`, `medi_cardColour`, `medi_idExpiry`
|
|
583
530
|
|
|
584
531
|
**Files:**
|
|
585
|
-
|
|
586
|
-
- `modules/form/vendors/formio/`
|
|
532
|
+
- `modules/form/vendors/formio/`
|
|
587
533
|
|
|
588
534
|
---
|
|
589
535
|
|
|
590
536
|
#### React Form
|
|
591
537
|
|
|
592
|
-
| Aspect
|
|
593
|
-
|
|
594
|
-
| **Framework**
|
|
595
|
-
| **Components** | 60+ form components
|
|
596
|
-
| **Screens**
|
|
538
|
+
| Aspect | Details |
|
|
539
|
+
|--------|---------|
|
|
540
|
+
| **Framework** | React 18 + Redux Toolkit + React Hook Form |
|
|
541
|
+
| **Components** | 60+ form components |
|
|
542
|
+
| **Screens** | Welcome, Consent, IdSelection, IdDetails, PersonalDetails, Review, DocumentUpload, Result |
|
|
597
543
|
|
|
598
544
|
**Key Hooks:**
|
|
599
|
-
|
|
600
|
-
-
|
|
601
|
-
-
|
|
602
|
-
-
|
|
603
|
-
- `useAddressSearch` - Google Maps autocomplete integration
|
|
545
|
+
- `useEventContext` - Event hub context provider
|
|
546
|
+
- `useConfigFactory` - Configuration merging
|
|
547
|
+
- `useFormMapper` - Field component mapping
|
|
548
|
+
- `useAddressSearch` - Google Maps autocomplete integration
|
|
604
549
|
|
|
605
550
|
**Field Configuration by Document Type:**
|
|
606
551
|
|
|
@@ -614,42 +559,39 @@ Individual Data ←→ Formio Schema
|
|
|
614
559
|
| WA | 7 numeric | 8-10 alphanumeric |
|
|
615
560
|
|
|
616
561
|
**Validation Rules:**
|
|
617
|
-
|
|
618
562
|
```javascript
|
|
619
563
|
ValidationRulesForForm = {
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
}
|
|
564
|
+
onlyAlphabets: /^[a-zA-Z]+(\s+[a-zA-Z]+)*$/,
|
|
565
|
+
onlyNumbers: /^[0-9]+$/,
|
|
566
|
+
alphaNumeric: /^[a-zA-Z0-9]+$/,
|
|
567
|
+
emailPattern: /^[a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,4}$/
|
|
568
|
+
}
|
|
625
569
|
```
|
|
626
570
|
|
|
627
571
|
**Screen Events:**
|
|
628
|
-
|
|
629
|
-
-
|
|
630
|
-
-
|
|
631
|
-
-
|
|
632
|
-
- `form:{screenId}:success` - Screen completed
|
|
572
|
+
- `form:{screenId}:ready` - Screen mounted
|
|
573
|
+
- `form:{screenId}:loaded` - Screen loaded
|
|
574
|
+
- `form:{screenId}:failed` - Screen error
|
|
575
|
+
- `form:{screenId}:success` - Screen completed
|
|
633
576
|
|
|
634
577
|
**Files:**
|
|
635
|
-
|
|
636
|
-
- `modules/form/vendors/react/`
|
|
578
|
+
- `modules/form/vendors/react/`
|
|
637
579
|
|
|
638
580
|
---
|
|
639
581
|
|
|
640
582
|
## Integration Method Reference
|
|
641
583
|
|
|
642
|
-
| Method
|
|
643
|
-
|
|
644
|
-
| **Native SDK**
|
|
645
|
-
| **Iframe + PostMessage** | Daon, Mastercard, Incode (IDV) | Sandboxed, vendor-managed UI
|
|
646
|
-
| **Web Component**
|
|
647
|
-
| **WebSocket + WebRTC**
|
|
648
|
-
| **OAuth 2.0**
|
|
649
|
-
| **Remote SDK**
|
|
650
|
-
| **Obfuscated SDK**
|
|
651
|
-
| **Form Builder**
|
|
652
|
-
| **React Components**
|
|
584
|
+
| Method | Vendors | Characteristics |
|
|
585
|
+
|--------|---------|-----------------|
|
|
586
|
+
| **Native SDK** | Onfido, Incode | Full control, version management, CDN loading |
|
|
587
|
+
| **Iframe + PostMessage** | Daon, Mastercard, Incode (IDV) | Sandboxed, vendor-managed UI |
|
|
588
|
+
| **Web Component** | IDVerse, Truuth | Custom elements, event-based |
|
|
589
|
+
| **WebSocket + WebRTC** | OcrLabs | Real-time liveness, canvas/video rendering |
|
|
590
|
+
| **OAuth 2.0** | Singpass | Server-side, browser redirect flow |
|
|
591
|
+
| **Remote SDK** | Sardine, Sumsub | Dynamically loaded from vendor CDN |
|
|
592
|
+
| **Obfuscated SDK** | ThreatMetrix | Inline vendor code, hidden implementation |
|
|
593
|
+
| **Form Builder** | Formio | Cloud service SDK with schema |
|
|
594
|
+
| **React Components** | React Form | Custom component library |
|
|
653
595
|
|
|
654
596
|
---
|
|
655
597
|
|
|
@@ -674,20 +616,20 @@ npm run test # Jest test suite
|
|
|
674
616
|
|
|
675
617
|
### Build Outputs
|
|
676
618
|
|
|
677
|
-
| Output | Location
|
|
678
|
-
|
|
679
|
-
| UMD
|
|
680
|
-
| ESM
|
|
681
|
-
| CSS
|
|
682
|
-
| CLI
|
|
619
|
+
| Output | Location | Description |
|
|
620
|
+
|--------|----------|-------------|
|
|
621
|
+
| UMD | `dist/umd/oneSdk.umd.js` | Browser global bundle |
|
|
622
|
+
| ESM | `dist/esm/modules/index.js` | ES Module with types |
|
|
623
|
+
| CSS | `dist/esm/styles/f1-style.css` | TailwindCSS output |
|
|
624
|
+
| CLI | `dist/cli/{platform}/` | Platform-specific Go binaries |
|
|
683
625
|
|
|
684
626
|
### CLI Platforms
|
|
685
627
|
|
|
686
|
-
-
|
|
687
|
-
-
|
|
688
|
-
-
|
|
689
|
-
-
|
|
690
|
-
-
|
|
628
|
+
- `darwin-amd64` (macOS Intel)
|
|
629
|
+
- `darwin-arm64` (macOS Apple Silicon)
|
|
630
|
+
- `linux-amd64`
|
|
631
|
+
- `linux-arm64`
|
|
632
|
+
- `windows-amd64`
|
|
691
633
|
|
|
692
634
|
---
|
|
693
635
|
|
|
@@ -697,49 +639,15 @@ Deployments are managed via GitHub Actions using reusable workflows.
|
|
|
697
639
|
|
|
698
640
|
### Workflows
|
|
699
641
|
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
| `publish_npm.yml` | Called by `main.yml` | Publish production release to NPM |
|
|
706
|
-
| `publish_npm_rc.yml` | Called by `main.yml` or manual dispatch | Publish RC (release candidate) to NPM |
|
|
707
|
-
| `rollback.yml` | Manual dispatch | Deployment rollback |
|
|
708
|
-
|
|
709
|
-
### Main Pipeline (`main.yml`)
|
|
710
|
-
|
|
711
|
-
```
|
|
712
|
-
ci → build → publish_artifact → bless-qa → publish-rc → deploy-qa → bless-uat → deploy-uat → bless-prod → deploy-prod → publish_npm
|
|
713
|
-
```
|
|
714
|
-
|
|
715
|
-
Each `bless-*` stage requires manual environment approval before proceeding.
|
|
716
|
-
|
|
717
|
-
### RC Publishing (`publish_npm_rc.yml`)
|
|
718
|
-
|
|
719
|
-
Publishes a release candidate to NPM under the `rc` dist-tag **before** QA deployment. This is required because the QA automated tests (`qe-ui-tests`) install the RC package to run against.
|
|
720
|
-
|
|
721
|
-
**How it works:**
|
|
722
|
-
|
|
723
|
-
1. Reads the base version from `package.json` (e.g. `1.9.13`)
|
|
724
|
-
2. Queries the NPM registry for existing RC versions matching that base
|
|
725
|
-
3. Computes the next RC version:
|
|
726
|
-
- No existing RCs → `1.9.13-rc`
|
|
727
|
-
- Existing `1.9.13-rc` → `1.9.13-rc.1`
|
|
728
|
-
- Existing `1.9.13-rc.1` → `1.9.13-rc.2`
|
|
729
|
-
4. Sets the version, builds via `scripts/build-to-npm.sh`, and publishes with `npm publish --tag rc`
|
|
730
|
-
|
|
731
|
-
**Installing an RC version:**
|
|
732
|
-
|
|
733
|
-
```bash
|
|
734
|
-
npm install @frankieone/one-sdk@rc
|
|
735
|
-
```
|
|
736
|
-
|
|
737
|
-
**Manual trigger:** The workflow can also be dispatched manually from the Actions tab for ad-hoc RC publishes.
|
|
642
|
+
- `publish_npm.yml` - NPM publication
|
|
643
|
+
- `feature_pr.yml` - Feature branch CI
|
|
644
|
+
- `develop.yml` - Development branch
|
|
645
|
+
- `main.yml` - Main branch deployment
|
|
646
|
+
- `rollback.yml` - Deployment rollback
|
|
738
647
|
|
|
739
648
|
For detailed deployment instructions, see:
|
|
740
|
-
|
|
741
|
-
-
|
|
742
|
-
- [Rollback Frontend Deployment](https://frankieone.atlassian.net/wiki/x/FAGgZw)
|
|
649
|
+
- [Reusable CICD Github Actions Workflows](https://frankieone.atlassian.net/wiki/x/doCMZw)
|
|
650
|
+
- [Rollback Frontend Deployment](https://frankieone.atlassian.net/wiki/x/FAGgZw)
|
|
743
651
|
|
|
744
652
|
---
|
|
745
653
|
|