@nokinc-flur/sdk 2.5.0 → 3.0.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.
@@ -1,235 +1,350 @@
1
- {
2
- "openapi": "3.0.3",
3
- "info": {
4
- "title": "Flur API",
5
- "version": "0.1.0"
6
- },
7
- "paths": {
8
- "/health": {
9
- "get": {
10
- "responses": {
11
- "200": {
12
- "description": "OK",
13
- "content": {
14
- "application/json": {
15
- "schema": {
16
- "type": "object",
17
- "properties": {
18
- "ok": {
19
- "type": "boolean"
20
- }
21
- },
22
- "required": [
23
- "ok"
24
- ]
25
- }
26
- }
27
- }
28
- }
29
- }
30
- }
31
- },
32
- "/welcome": {
33
- "get": {
34
- "responses": {
35
- "200": {
36
- "description": "OK",
37
- "content": {
38
- "application/json": {
39
- "schema": {
40
- "type": "object",
41
- "properties": {
42
- "message": {
43
- "type": "string",
44
- "example": "welcome to flur wallet. Today is 2026-02-07T19:09:53.238Z"
45
- }
46
- },
47
- "required": [
48
- "message"
49
- ]
50
- }
51
- }
52
- }
53
- }
54
- }
55
- }
56
- },
57
- "/v1/onboarding/start": {
58
- "post": {
59
- "requestBody": {
60
- "required": true,
61
- "content": {
62
- "application/json": {
63
- "schema": {
64
- "type": "object",
65
- "properties": {
66
- "phoneE164": {
67
- "type": "string"
68
- }
69
- },
70
- "required": [
71
- "phoneE164"
72
- ]
73
- }
74
- }
75
- }
76
- },
77
- "responses": {
78
- "200": {
79
- "description": "Verification started",
80
- "content": {
81
- "application/json": {
82
- "schema": {
83
- "type": "object",
84
- "properties": {
85
- "requestId": {
86
- "type": "string"
87
- },
88
- "checkUrl": {
89
- "type": "string"
90
- },
91
- "expiresInSec": {
92
- "type": "integer"
93
- },
94
- "fallback": {
95
- "type": "string",
96
- "enum": [
97
- "SILENT_AUTH",
98
- "OTP"
99
- ]
100
- }
101
- },
102
- "required": [
103
- "requestId",
104
- "expiresInSec",
105
- "fallback"
106
- ]
107
- }
108
- }
109
- }
110
- },
111
- "400": {
112
- "description": "Unable to start verification",
113
- "content": {
114
- "application/json": {
115
- "schema": {
116
- "type": "object",
117
- "properties": {
118
- "error": {
119
- "type": "string"
120
- }
121
- },
122
- "required": [
123
- "error"
124
- ]
125
- }
126
- }
127
- }
128
- },
129
- "429": {
130
- "description": "Rate limited",
131
- "content": {
132
- "application/json": {
133
- "schema": {
134
- "type": "object",
135
- "properties": {
136
- "error": {
137
- "type": "string"
138
- }
139
- },
140
- "required": [
141
- "error"
142
- ]
143
- }
144
- }
145
- }
146
- }
147
- }
148
- }
149
- },
150
- "/v1/onboarding/complete": {
151
- "post": {
152
- "requestBody": {
153
- "required": true,
154
- "content": {
155
- "application/json": {
156
- "schema": {
157
- "type": "object",
158
- "properties": {
159
- "requestId": {
160
- "type": "string"
161
- },
162
- "code": {
163
- "type": "string"
164
- }
165
- },
166
- "required": [
167
- "requestId",
168
- "code"
169
- ]
170
- }
171
- }
172
- }
173
- },
174
- "responses": {
175
- "200": {
176
- "description": "Verification completed",
177
- "content": {
178
- "application/json": {
179
- "schema": {
180
- "type": "object",
181
- "properties": {
182
- "sessionToken": {
183
- "type": "string"
184
- },
185
- "userId": {
186
- "type": "string"
187
- },
188
- "restricted": {
189
- "type": "boolean"
190
- },
191
- "risk_reasons": {
192
- "type": "array",
193
- "items": {
194
- "type": "string",
195
- "enum": [
196
- "SIM_SWAP_RECENT",
197
- "ROAMING",
198
- "CARRIER_CHANGED"
199
- ]
200
- }
201
- }
202
- },
203
- "required": [
204
- "sessionToken",
205
- "userId",
206
- "restricted",
207
- "risk_reasons"
208
- ]
209
- }
210
- }
211
- }
212
- },
213
- "400": {
214
- "description": "Verification failed",
215
- "content": {
216
- "application/json": {
217
- "schema": {
218
- "type": "object",
219
- "properties": {
220
- "error": {
221
- "type": "string"
222
- }
223
- },
224
- "required": [
225
- "error"
226
- ]
227
- }
228
- }
229
- }
230
- }
231
- }
232
- }
233
- }
234
- }
235
- }
1
+ {
2
+ "openapi": "3.0.3",
3
+ "info": {
4
+ "title": "Flur API",
5
+ "version": "2.5.0"
6
+ },
7
+ "paths": {
8
+ "/health": {
9
+ "get": {
10
+ "responses": {
11
+ "200": {
12
+ "description": "OK",
13
+ "content": {
14
+ "application/json": {
15
+ "schema": {
16
+ "type": "object",
17
+ "properties": {
18
+ "ok": {
19
+ "type": "boolean"
20
+ }
21
+ },
22
+ "required": ["ok"]
23
+ }
24
+ }
25
+ }
26
+ }
27
+ }
28
+ }
29
+ },
30
+ "/welcome": {
31
+ "get": {
32
+ "responses": {
33
+ "200": {
34
+ "description": "OK",
35
+ "content": {
36
+ "application/json": {
37
+ "schema": {
38
+ "type": "object",
39
+ "properties": {
40
+ "message": {
41
+ "type": "string",
42
+ "example": "welcome to flur wallet. Today is 2026-02-07T19:09:53.238Z"
43
+ }
44
+ },
45
+ "required": ["message"]
46
+ }
47
+ }
48
+ }
49
+ }
50
+ }
51
+ }
52
+ },
53
+ "/v1/onboarding/start": {
54
+ "post": {
55
+ "requestBody": {
56
+ "required": true,
57
+ "content": {
58
+ "application/json": {
59
+ "schema": {
60
+ "type": "object",
61
+ "properties": {
62
+ "phoneE164": {
63
+ "type": "string",
64
+ "pattern": "^\\+[1-9]\\d{7,14}$"
65
+ },
66
+ "appInstanceId": {
67
+ "type": "string",
68
+ "minLength": 3
69
+ },
70
+ "platform": {
71
+ "type": "string",
72
+ "enum": ["android", "ios", "web"]
73
+ },
74
+ "turnstileToken": {
75
+ "type": "string",
76
+ "minLength": 20
77
+ },
78
+ "appAttestation": {
79
+ "type": "object",
80
+ "properties": {
81
+ "provider": {
82
+ "type": "string",
83
+ "enum": ["android", "ios", "web"]
84
+ },
85
+ "token": {
86
+ "type": "string",
87
+ "minLength": 24
88
+ }
89
+ },
90
+ "required": ["provider", "token"]
91
+ },
92
+ "firstName": {
93
+ "type": "string",
94
+ "minLength": 1,
95
+ "maxLength": 80
96
+ },
97
+ "lastName": {
98
+ "type": "string",
99
+ "minLength": 1,
100
+ "maxLength": 80
101
+ }
102
+ },
103
+ "required": ["phoneE164", "appInstanceId", "platform"]
104
+ }
105
+ }
106
+ }
107
+ },
108
+ "responses": {
109
+ "200": {
110
+ "description": "Verification started",
111
+ "content": {
112
+ "application/json": {
113
+ "schema": {
114
+ "type": "object",
115
+ "properties": {
116
+ "requestId": {
117
+ "type": "string"
118
+ },
119
+ "checkUrl": {
120
+ "type": "string"
121
+ },
122
+ "expiresInSec": {
123
+ "type": "integer"
124
+ },
125
+ "fallback": {
126
+ "type": "string",
127
+ "enum": ["SILENT_AUTH", "OTP"]
128
+ }
129
+ },
130
+ "required": ["requestId", "expiresInSec", "fallback"]
131
+ }
132
+ }
133
+ }
134
+ },
135
+ "400": {
136
+ "description": "Unable to start verification",
137
+ "content": {
138
+ "application/json": {
139
+ "schema": {
140
+ "type": "object",
141
+ "properties": {
142
+ "error": {
143
+ "type": "string"
144
+ }
145
+ },
146
+ "required": ["error"]
147
+ }
148
+ }
149
+ }
150
+ },
151
+ "429": {
152
+ "description": "Rate limited",
153
+ "content": {
154
+ "application/json": {
155
+ "schema": {
156
+ "type": "object",
157
+ "properties": {
158
+ "error": {
159
+ "type": "string"
160
+ }
161
+ },
162
+ "required": ["error"]
163
+ }
164
+ }
165
+ }
166
+ }
167
+ }
168
+ }
169
+ },
170
+ "/v1/onboarding/complete": {
171
+ "post": {
172
+ "requestBody": {
173
+ "required": true,
174
+ "content": {
175
+ "application/json": {
176
+ "schema": {
177
+ "type": "object",
178
+ "properties": {
179
+ "requestId": {
180
+ "type": "string"
181
+ },
182
+ "code": {
183
+ "type": "string",
184
+ "minLength": 1,
185
+ "maxLength": 32
186
+ },
187
+ "appInstanceId": {
188
+ "type": "string",
189
+ "minLength": 3
190
+ },
191
+ "fingerprintHash": {
192
+ "type": "string",
193
+ "minLength": 3
194
+ }
195
+ },
196
+ "required": ["requestId", "code", "appInstanceId"]
197
+ }
198
+ }
199
+ }
200
+ },
201
+ "responses": {
202
+ "200": {
203
+ "description": "Verification completed",
204
+ "content": {
205
+ "application/json": {
206
+ "schema": {
207
+ "type": "object",
208
+ "properties": {
209
+ "accessToken": {
210
+ "type": "string"
211
+ },
212
+ "refreshToken": {
213
+ "type": "string"
214
+ },
215
+ "userId": {
216
+ "type": "string"
217
+ },
218
+ "restricted": {
219
+ "type": "boolean"
220
+ },
221
+ "risk_reasons": {
222
+ "type": "array",
223
+ "items": {
224
+ "type": "string",
225
+ "enum": [
226
+ "SIM_SWAP_RECENT",
227
+ "ROAMING",
228
+ "CARRIER_CHANGED"
229
+ ]
230
+ }
231
+ },
232
+ "stepUpRequired": {
233
+ "type": "boolean"
234
+ },
235
+ "riskStatus": {
236
+ "type": "string",
237
+ "enum": ["ok", "unavailable"]
238
+ }
239
+ },
240
+ "required": [
241
+ "accessToken",
242
+ "refreshToken",
243
+ "userId",
244
+ "restricted",
245
+ "risk_reasons"
246
+ ]
247
+ }
248
+ }
249
+ }
250
+ },
251
+ "400": {
252
+ "description": "Verification failed",
253
+ "content": {
254
+ "application/json": {
255
+ "schema": {
256
+ "type": "object",
257
+ "properties": {
258
+ "error": {
259
+ "type": "string"
260
+ }
261
+ },
262
+ "required": ["error"]
263
+ }
264
+ }
265
+ }
266
+ }
267
+ }
268
+ }
269
+ },
270
+ "/v1/auth/refresh": {
271
+ "post": {
272
+ "requestBody": {
273
+ "required": true,
274
+ "content": {
275
+ "application/json": {
276
+ "schema": {
277
+ "type": "object",
278
+ "properties": {
279
+ "userId": {
280
+ "type": "string"
281
+ },
282
+ "refreshToken": {
283
+ "type": "string",
284
+ "minLength": 8
285
+ },
286
+ "appInstanceId": {
287
+ "type": "string",
288
+ "minLength": 3
289
+ },
290
+ "fingerprintHash": {
291
+ "type": "string",
292
+ "minLength": 3
293
+ }
294
+ },
295
+ "required": [
296
+ "userId",
297
+ "refreshToken",
298
+ "appInstanceId",
299
+ "fingerprintHash"
300
+ ]
301
+ }
302
+ }
303
+ }
304
+ },
305
+ "responses": {
306
+ "200": {
307
+ "description": "Access token refreshed",
308
+ "content": {
309
+ "application/json": {
310
+ "schema": {
311
+ "type": "object",
312
+ "properties": {
313
+ "accessToken": {
314
+ "type": "string",
315
+ "minLength": 8
316
+ },
317
+ "refreshToken": {
318
+ "type": "string",
319
+ "minLength": 8
320
+ },
321
+ "stepUpRequired": {
322
+ "type": "boolean"
323
+ }
324
+ },
325
+ "required": ["accessToken", "refreshToken", "stepUpRequired"]
326
+ }
327
+ }
328
+ }
329
+ },
330
+ "401": {
331
+ "description": "Refresh token invalid or expired",
332
+ "content": {
333
+ "application/json": {
334
+ "schema": {
335
+ "type": "object",
336
+ "properties": {
337
+ "error": {
338
+ "type": "string"
339
+ }
340
+ },
341
+ "required": ["error"]
342
+ }
343
+ }
344
+ }
345
+ }
346
+ }
347
+ }
348
+ }
349
+ }
350
+ }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@nokinc-flur/sdk",
3
- "version": "2.5.0",
4
- "description": "Flur Wallet SDK (sprint 1 scaffold)",
3
+ "version": "3.0.1",
4
+ "description": "Flur Wallet SDK",
5
5
  "license": "UNLICENSED",
6
6
  "private": false,
7
7
  "type": "module",
@@ -66,14 +66,5 @@
66
66
  "tsup": "^8.0.2",
67
67
  "typescript": "~5.5.4",
68
68
  "vitest": "^1.5.0"
69
- },
70
- "lint-staged": {
71
- "*.{ts,tsx}": [
72
- "prettier --write",
73
- "eslint --fix --max-warnings 0"
74
- ],
75
- "*.{js,jsx,json,md,cjs,mjs}": [
76
- "prettier --write"
77
- ]
78
69
  }
79
70
  }