@tap-payments/auth-jsconnect 2.6.7-test → 2.6.8-test

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.
@@ -210,7 +210,6 @@ interface LibCallbacks {
210
210
  }
211
211
  export interface LibConfig extends LibCallbacks {
212
212
  publicKey: string;
213
- mode: 'popup' | 'page';
214
213
  open: boolean;
215
214
  merchantDomain: string;
216
215
  language: LanguageMode;
@@ -220,6 +219,7 @@ export interface LibConfig extends LibCallbacks {
220
219
  postURL?: string;
221
220
  redirectUrl?: string;
222
221
  data?: Array<string>;
222
+ mode?: 'popup' | 'page';
223
223
  authId?: string;
224
224
  boardMaturity?: boolean;
225
225
  }
@@ -9,6 +9,8 @@ export declare type ValidateOperatorBody = {
9
9
  export declare type UpdateOperatorBody = {
10
10
  id: string;
11
11
  post_url: string;
12
+ authentication_id: string;
13
+ bi: string;
12
14
  };
13
15
  declare const operatorService: {
14
16
  validateOperator: (body: ValidateOperatorBody) => Promise<any>;
@@ -160,7 +160,9 @@ export var onCloseComplete = createAsyncThunk('settings/onCloseComplete', functi
160
160
  id = ((_c = (_b = list === null || list === void 0 ? void 0 : list[0]) === null || _b === void 0 ? void 0 : _b.operator) === null || _c === void 0 ? void 0 : _c.id) || '';
161
161
  body = {
162
162
  id: id,
163
- post_url: postURL || ''
163
+ post_url: postURL || '',
164
+ authentication_id: authId || '',
165
+ bi: bi
164
166
  };
165
167
  return [4, API.operatorService.updateOperator(body)];
166
168
  case 2:
@@ -837,7 +837,7 @@ export var updateLeadBusinessDataAsync = createAsyncThunk('updateLeadBusinessDat
837
837
  export var updateOperatorInfoAsync = createAsyncThunk('connectExpress/updateOperatorInfoAsync', function (_a, thunkApi) {
838
838
  var terminalInfo = _a.terminalInfo;
839
839
  return __awaiter(void 0, void 0, void 0, function () {
840
- var _b, connectExpress, settings, responseData, _c, postURL, redirectUrl, bi, body, data, authId, urlQueryStart;
840
+ var _b, connectExpress, settings, responseData, _c, postURL, redirectUrl, bi, authId, body, data, urlQueryStart;
841
841
  var _d, _e, _f, _g, _h;
842
842
  return __generator(this, function (_j) {
843
843
  switch (_j.label) {
@@ -846,15 +846,17 @@ export var updateOperatorInfoAsync = createAsyncThunk('connectExpress/updateOper
846
846
  responseData = connectExpress.data.responseData;
847
847
  _c = settings.data.appConfig, postURL = _c.postURL, redirectUrl = _c.redirectUrl;
848
848
  bi = settings.data.deviceInfo.browser.browser_id;
849
+ authId = (_e = (_d = responseData === null || responseData === void 0 ? void 0 : responseData.authData) === null || _d === void 0 ? void 0 : _d.auth) === null || _e === void 0 ? void 0 : _e.id;
849
850
  body = {
850
- id: ((_d = terminalInfo === null || terminalInfo === void 0 ? void 0 : terminalInfo.operator) === null || _d === void 0 ? void 0 : _d.id) || '',
851
- post_url: postURL || ''
851
+ id: ((_f = terminalInfo === null || terminalInfo === void 0 ? void 0 : terminalInfo.operator) === null || _f === void 0 ? void 0 : _f.id) || '',
852
+ post_url: postURL || '',
853
+ authentication_id: authId,
854
+ bi: bi
852
855
  };
853
856
  return [4, API.operatorService.updateOperator(body)];
854
857
  case 1:
855
858
  data = _j.sent();
856
- (_f = (_e = settings.data.appConfig).onStepCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, settings.data.activeScreen.name, data);
857
- authId = (_h = (_g = responseData === null || responseData === void 0 ? void 0 : responseData.authData) === null || _g === void 0 ? void 0 : _g.auth) === null || _h === void 0 ? void 0 : _h.id;
859
+ (_h = (_g = settings.data.appConfig).onStepCompleted) === null || _h === void 0 ? void 0 : _h.call(_g, settings.data.activeScreen.name, data);
858
860
  if (authId) {
859
861
  if (settings.data.appConfig.mode === 'popup') {
860
862
  settings.data.appConfig.onFlowCompleted({ auth_id: authId, bi: bi });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tap-payments/auth-jsconnect",
3
- "version": "2.6.7-test",
3
+ "version": "2.6.8-test",
4
4
  "description": "connect library, auth",
5
5
  "private": false,
6
6
  "main": "build/index.js",