skyflow-js 2.5.0-beta.5 → 2.5.0-beta.7
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/dist/sdkNodeBuild/index.js +1 -1
- package/dist/sdkNodeBuild/index.js.LICENSE.txt +1 -1
- package/dist/sdkNodeBuild/index.js.LICENSE.txt.gz +0 -0
- package/dist/sdkNodeBuild/index.js.gz +0 -0
- package/package.json +1 -1
- package/types/core/constants.d.ts +26 -3
- package/types/core/external/collect/collect-container.d.ts +0 -1
- package/types/core/external/collect/collect-element.d.ts +0 -2
- package/types/core/external/collect/compose-collect-container.d.ts +2 -1
- package/types/core/external/collect/compose-collect-element.d.ts +3 -2
- package/types/core/external/reveal/composable-reveal-container.d.ts +14 -0
- package/types/core/external/reveal/composable-reveal-element.d.ts +12 -0
- package/types/core/external/reveal/composable-reveal-internal.d.ts +29 -0
- package/types/core/external/reveal/reveal-element.d.ts +0 -2
- package/types/core/internal/composable-frame-element-init.d.ts +21 -0
- package/types/core/internal/frame-element-init.d.ts +11 -0
- package/types/core/internal/iframe-form/index.d.ts +0 -27
- package/types/core/internal/index.d.ts +2 -1
- package/types/core/internal/reveal/reveal-frame.d.ts +6 -1
- package/types/core/internal/skyflow-frame/skyflow-frame-controller.d.ts +1 -2
- package/types/core-utils/collect.d.ts +3 -0
- package/types/core-utils/reveal.d.ts +13 -1
- package/types/skyflow.d.ts +4 -1
- package/types/utils/common/index.d.ts +11 -0
- package/types/utils/constants.d.ts +8 -0
- package/types/utils/logs.d.ts +5 -4
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/
|
|
8
|
+
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -9,10 +9,12 @@ export declare const SDK_IFRAME_EVENT = "SDK IFRAME EVENT";
|
|
|
9
9
|
export declare const DOMAIN = "US2";
|
|
10
10
|
export declare const CORALOGIX_DOMAIN = "https://cdn.rum-ingress-coralogix.com/coralogix/browser/latest/coralogix-browser-sdk.js";
|
|
11
11
|
export declare const FRAME_ELEMENT = "element";
|
|
12
|
+
export declare const COMPOSABLE_REVEAL = "reveal-composable";
|
|
12
13
|
export declare const ELEMENT_TYPES: {
|
|
13
14
|
COLLECT: string;
|
|
14
15
|
REVEAL: string;
|
|
15
16
|
COMPOSE: string;
|
|
17
|
+
REVEAL_COMPOSE: string;
|
|
16
18
|
};
|
|
17
19
|
export declare const EVENT_TYPES: {
|
|
18
20
|
MOUNTED: string;
|
|
@@ -30,6 +32,7 @@ export declare const METRIC_TYPES: {
|
|
|
30
32
|
COLLECT: string;
|
|
31
33
|
REVEAL: string;
|
|
32
34
|
COMPOSE: string;
|
|
35
|
+
REVEAL_COMPOSE: string;
|
|
33
36
|
};
|
|
34
37
|
ELEMENT_TYPE_KEY: string;
|
|
35
38
|
DIV_ID: string;
|
|
@@ -86,10 +89,19 @@ export declare const ELEMENT_EVENTS_TO_CLIENT: {
|
|
|
86
89
|
HEIGHT: string;
|
|
87
90
|
};
|
|
88
91
|
export declare const ELEMENT_EVENTS_TO_IFRAME: {
|
|
89
|
-
|
|
90
|
-
|
|
92
|
+
MULTIPLE_UPLOAD_FILES_RESPONSE: string;
|
|
93
|
+
RENDER_MOUNTED: string;
|
|
94
|
+
HEIGHT_CALLBACK: string;
|
|
95
|
+
HEIGHT_CALLBACK_COMPOSABLE: string;
|
|
96
|
+
COMPOSABLE_REVEAL: string;
|
|
97
|
+
MULTIPLE_UPLOAD_FILES: string;
|
|
91
98
|
COLLECT_CALL_REQUESTS: string;
|
|
99
|
+
COMPOSABLE_CALL_REQUESTS: string;
|
|
100
|
+
COMPOSABLE_CALL_RESPONSE: string;
|
|
101
|
+
COMPOSABLE_FILE_CALL_RESPONSE: string;
|
|
102
|
+
COMPOSABLE_CONTAINER: string;
|
|
92
103
|
REVEAL_CALL_REQUESTS: string;
|
|
104
|
+
REVEAL_CALL_RESPONSE: string;
|
|
93
105
|
FRAME_READY: string;
|
|
94
106
|
READY_FOR_CLIENT: string;
|
|
95
107
|
TOKENIZATION_REQUEST: string;
|
|
@@ -142,7 +154,8 @@ export declare enum ElementType {
|
|
|
142
154
|
PIN = "PIN",
|
|
143
155
|
EXPIRATION_MONTH = "EXPIRATION_MONTH",
|
|
144
156
|
EXPIRATION_YEAR = "EXPIRATION_YEAR",
|
|
145
|
-
FILE_INPUT = "FILE_INPUT"
|
|
157
|
+
FILE_INPUT = "FILE_INPUT",
|
|
158
|
+
MULTI_FILE_INPUT = "MULTI_FILE_INPUT"
|
|
146
159
|
}
|
|
147
160
|
export declare enum CardType {
|
|
148
161
|
VISA = "VISA",
|
|
@@ -324,6 +337,14 @@ export declare const ELEMENTS: {
|
|
|
324
337
|
type: string;
|
|
325
338
|
};
|
|
326
339
|
};
|
|
340
|
+
MULTI_FILE_INPUT: {
|
|
341
|
+
name: string;
|
|
342
|
+
sensitive: boolean;
|
|
343
|
+
attributes: {
|
|
344
|
+
type: string;
|
|
345
|
+
multiple: string;
|
|
346
|
+
};
|
|
347
|
+
};
|
|
327
348
|
};
|
|
328
349
|
export declare const CARDNUMBER_INPUT_FORMAT: {
|
|
329
350
|
SPACE_FORMAT: string;
|
|
@@ -552,6 +573,7 @@ export declare const DEFAULT_ERROR_TEXT_ELEMENT_TYPES: {
|
|
|
552
573
|
EXPIRATION_MONTH: string;
|
|
553
574
|
EXPIRATION_YEAR: string;
|
|
554
575
|
FILE_INPUT: string;
|
|
576
|
+
MULTI_FILE_INPUT: string;
|
|
555
577
|
};
|
|
556
578
|
export declare const DEFAULT_REQUIRED_TEXT_ELEMENT_TYPES: {
|
|
557
579
|
CVV: string;
|
|
@@ -563,6 +585,7 @@ export declare const DEFAULT_REQUIRED_TEXT_ELEMENT_TYPES: {
|
|
|
563
585
|
EXPIRATION_MONTH: string;
|
|
564
586
|
EXPIRATION_YEAR: string;
|
|
565
587
|
FILE_INPUT: string;
|
|
588
|
+
MULTI_FILE_INPUT: string;
|
|
566
589
|
};
|
|
567
590
|
export declare const INPUT_KEYBOARD_EVENTS: {
|
|
568
591
|
ENTER: string;
|
|
@@ -8,6 +8,5 @@ declare class CollectContainer extends Container {
|
|
|
8
8
|
create: (input: CollectElementInput, options?: CollectElementOptions) => CollectElement;
|
|
9
9
|
collect: (options?: ICollectOptions) => Promise<CollectResponse>;
|
|
10
10
|
uploadFiles: (options: ICollectOptions) => Promise<UploadFilesResponse>;
|
|
11
|
-
checkIfFrameExistsInShadowRoot: (shadowRoot: ShadowRoot | null, frameName: string) => boolean;
|
|
12
11
|
}
|
|
13
12
|
export default CollectContainer;
|
|
@@ -10,8 +10,6 @@ declare class CollectElement extends SkyflowElement {
|
|
|
10
10
|
constructor(elementId: string, elementGroup: any, metaData: any, container: any, isSingleElementAPI: boolean | undefined, destroyCallback: Function, updateCallback: Function, context: Context, groupEventEmitter?: EventEmitter);
|
|
11
11
|
getID: () => string;
|
|
12
12
|
mount: (domElement: HTMLElement | string) => void;
|
|
13
|
-
getShadowRoot: () => ShadowRoot | null;
|
|
14
|
-
emitEventFromShadowRoot: (eventName: string, options?: Record<string, any>, callback?: any) => void;
|
|
15
13
|
unmount: () => void;
|
|
16
14
|
updateElementGroup: (group: any) => void;
|
|
17
15
|
updateElement: (elementOptions: any) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CollectElementInput, CollectElementOptions, ICollectOptions, CollectResponse } from '../../../utils/common';
|
|
1
|
+
import { CollectElementInput, CollectElementOptions, ICollectOptions, CollectResponse, UploadFilesResponse } from '../../../utils/common';
|
|
2
2
|
import Container from '../common/container';
|
|
3
3
|
import ComposableElement from './compose-collect-element';
|
|
4
4
|
declare class ComposableContainer extends Container {
|
|
@@ -10,5 +10,6 @@ declare class ComposableContainer extends Container {
|
|
|
10
10
|
mount: (domElement: HTMLElement | string) => void;
|
|
11
11
|
unmount: () => void;
|
|
12
12
|
collect: (options?: ICollectOptions) => Promise<CollectResponse>;
|
|
13
|
+
uploadFiles: (options: ICollectOptions) => Promise<UploadFilesResponse>;
|
|
13
14
|
}
|
|
14
15
|
export default ComposableContainer;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { CollectElementUpdateOptions } from '../../../utils/common';
|
|
1
|
+
import { CollectElementUpdateOptions, MetaData } from '../../../utils/common';
|
|
2
2
|
declare class ComposableElement {
|
|
3
3
|
#private;
|
|
4
4
|
type: string;
|
|
5
|
-
constructor(name: any, eventEmitter: any, iframeName: any);
|
|
5
|
+
constructor(name: any, eventEmitter: any, iframeName: any, metaData: any);
|
|
6
6
|
on(eventName: string, handler: Function): void;
|
|
7
7
|
iframeName(): string;
|
|
8
8
|
getID(): string;
|
|
9
9
|
update: (options: CollectElementUpdateOptions) => void;
|
|
10
|
+
uploadMultipleFiles: (metaData?: MetaData) => Promise<unknown>;
|
|
10
11
|
}
|
|
11
12
|
export default ComposableElement;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import Container from '../common/container';
|
|
2
|
+
import ComposableRevealElement from './composable-reveal-element';
|
|
3
|
+
import { RevealElementInput, RevealResponse } from '../../../index-node';
|
|
4
|
+
import { IRevealElementOptions } from './reveal-container';
|
|
5
|
+
declare class ComposableRevealContainer extends Container {
|
|
6
|
+
#private;
|
|
7
|
+
type: string;
|
|
8
|
+
constructor(options: any, metaData: any, skyflowElements: any, context: any);
|
|
9
|
+
create: (input: RevealElementInput, options?: IRevealElementOptions) => ComposableRevealElement;
|
|
10
|
+
mount: (domElement: HTMLElement | string) => void;
|
|
11
|
+
unmount: () => void;
|
|
12
|
+
reveal(): Promise<RevealResponse>;
|
|
13
|
+
}
|
|
14
|
+
export default ComposableRevealContainer;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { RenderFileResponse } from '../../../utils/common';
|
|
2
|
+
import { IRevealElementInput, IRevealElementOptions } from './reveal-container';
|
|
3
|
+
declare class ComposableRevealElement {
|
|
4
|
+
#private;
|
|
5
|
+
type: string;
|
|
6
|
+
constructor(name: any, eventEmitter: any, iframeName: any);
|
|
7
|
+
iframeName(): string;
|
|
8
|
+
getID(): string;
|
|
9
|
+
renderFile(): Promise<RenderFileResponse>;
|
|
10
|
+
update: (options: IRevealElementInput | IRevealElementOptions) => void;
|
|
11
|
+
}
|
|
12
|
+
export default ComposableRevealElement;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Context, RenderFileResponse } from '../../../utils/common';
|
|
2
|
+
import SkyflowElement from '../common/skyflow-element';
|
|
3
|
+
import { IRevealElementInput, IRevealElementOptions } from './reveal-container';
|
|
4
|
+
export interface RevealComposableGroup {
|
|
5
|
+
record: IRevealElementInput;
|
|
6
|
+
options: IRevealElementOptions;
|
|
7
|
+
}
|
|
8
|
+
declare class ComposableRevealInternalElement extends SkyflowElement {
|
|
9
|
+
#private;
|
|
10
|
+
constructor(elementId: string, recordGroup: RevealComposableGroup[], metaData: any, container: any, isSingleElementAPI: boolean | undefined, context: Context);
|
|
11
|
+
private setupRenderFileEventListener;
|
|
12
|
+
getID(): string;
|
|
13
|
+
mount(domElementSelector: HTMLElement | string): void;
|
|
14
|
+
renderFile(recordData: any): Promise<RenderFileResponse>;
|
|
15
|
+
iframeName(): string;
|
|
16
|
+
isMounted(): boolean;
|
|
17
|
+
hasToken(): boolean;
|
|
18
|
+
isClientSetError(): boolean;
|
|
19
|
+
getRecordData(): any;
|
|
20
|
+
setErrorOverride(clientErrorText: string): void;
|
|
21
|
+
setError(clientErrorText: string): void;
|
|
22
|
+
resetError(): void;
|
|
23
|
+
setAltText(altText: string): void;
|
|
24
|
+
clearAltText(): void;
|
|
25
|
+
setToken(token: string): void;
|
|
26
|
+
unmount(): void;
|
|
27
|
+
update(options: IRevealElementInput | IRevealElementOptions, record: any): void;
|
|
28
|
+
}
|
|
29
|
+
export default ComposableRevealInternalElement;
|
|
@@ -5,8 +5,6 @@ declare class RevealElement extends SkyflowElement {
|
|
|
5
5
|
#private;
|
|
6
6
|
constructor(record: IRevealElementInput, options: IRevealElementOptions | undefined, metaData: any, container: any, elementId: string, context: Context);
|
|
7
7
|
getID(): string;
|
|
8
|
-
getShadowRoot: () => ShadowRoot | null;
|
|
9
|
-
emitEventFromShadowRoot: (eventName: string, options?: Record<string, any>) => void;
|
|
10
8
|
mount(domElementSelector: HTMLElement | string): void;
|
|
11
9
|
renderFile(): Promise<RenderFileResponse>;
|
|
12
10
|
iframeName(): string;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { IRevealRecordComposable } from '../../utils/common';
|
|
2
|
+
import IFrameFormElement from './iframe-form';
|
|
3
|
+
import FrameElement from '.';
|
|
4
|
+
export default class RevealComposableFrameElementInit {
|
|
5
|
+
#private;
|
|
6
|
+
iframeFormElement: IFrameFormElement | undefined;
|
|
7
|
+
clientMetaData: any;
|
|
8
|
+
frameElement: FrameElement;
|
|
9
|
+
private static frameEle?;
|
|
10
|
+
containerId: string;
|
|
11
|
+
group: any;
|
|
12
|
+
frameList: FrameElement[];
|
|
13
|
+
iframeFormList: IFrameFormElement[];
|
|
14
|
+
revealFrameList: any[];
|
|
15
|
+
rootDiv: HTMLDivElement;
|
|
16
|
+
constructor();
|
|
17
|
+
updateGroupData: () => void;
|
|
18
|
+
static startFrameElement: () => void;
|
|
19
|
+
revealData(revealRecords: IRevealRecordComposable[], containerId: any, authToken: any): Promise<unknown>;
|
|
20
|
+
createContainerDiv: (newGroup: any) => void;
|
|
21
|
+
}
|
|
@@ -10,7 +10,18 @@ export default class FrameElementInit {
|
|
|
10
10
|
private static frameEle?;
|
|
11
11
|
containerId: string;
|
|
12
12
|
group: any;
|
|
13
|
+
frameList: FrameElement[];
|
|
14
|
+
iframeFormList: IFrameFormElement[];
|
|
13
15
|
constructor();
|
|
16
|
+
private handleCollectCall;
|
|
17
|
+
private parallelUploadFiles;
|
|
18
|
+
uploadFiles: (fileElement: any, clientConfig: any) => Promise<unknown>;
|
|
19
|
+
private tokenize;
|
|
20
|
+
private multipleUploadFiles;
|
|
21
|
+
private validateFiles;
|
|
22
|
+
private createInsertRequest;
|
|
23
|
+
private extractSkyflowIDs;
|
|
24
|
+
private insertDataCallInMultiFiles;
|
|
14
25
|
updateGroupData: () => void;
|
|
15
26
|
createIframeElement: (frameName: any, label: any, skyflowID: any, isRequired: any) => IFrameFormElement;
|
|
16
27
|
static startFrameElement: () => void;
|
|
@@ -35,34 +35,7 @@ export default class IFrameFormElement extends EventEmitter {
|
|
|
35
35
|
preserveFileName: boolean;
|
|
36
36
|
allowedFileType: any;
|
|
37
37
|
blockEmptyFiles: boolean;
|
|
38
|
-
containerId: string;
|
|
39
|
-
clientId: string;
|
|
40
38
|
constructor(name: string, label: string, metaData: any, context: Context, skyflowID?: string);
|
|
41
|
-
getProperties: () => {
|
|
42
|
-
state: {
|
|
43
|
-
value: any;
|
|
44
|
-
isFocused: boolean;
|
|
45
|
-
isValid: boolean;
|
|
46
|
-
isEmpty: boolean;
|
|
47
|
-
isComplete: boolean;
|
|
48
|
-
name: string;
|
|
49
|
-
isRequired: boolean;
|
|
50
|
-
isTouched: boolean;
|
|
51
|
-
selectedCardScheme: string;
|
|
52
|
-
};
|
|
53
|
-
value: any;
|
|
54
|
-
fieldType: string;
|
|
55
|
-
doesClientHasError: boolean;
|
|
56
|
-
clientErrorText: string | undefined;
|
|
57
|
-
errorText: string | undefined;
|
|
58
|
-
onFocusChange: (focus: boolean) => void;
|
|
59
|
-
setValue: (value?: any, valid?: boolean, isReset?: boolean) => void;
|
|
60
|
-
validations: IValidationRule[] | undefined;
|
|
61
|
-
isMatchEqual: (index: number, value: string, validation: IValidationRule) => boolean;
|
|
62
|
-
tableName: string | undefined;
|
|
63
|
-
skyflowID: string | undefined;
|
|
64
|
-
preserveFileName: boolean;
|
|
65
|
-
};
|
|
66
39
|
isMatchEqual(index: number, value: string, validation: IValidationRule): boolean;
|
|
67
40
|
checkMatch(index: number, validation: IValidationRule): void;
|
|
68
41
|
listenForMatchRule(): void;
|
|
@@ -20,7 +20,8 @@ export default class FrameElement {
|
|
|
20
20
|
private selectionStart?;
|
|
21
21
|
private selectionEnd?;
|
|
22
22
|
private selectedData?;
|
|
23
|
-
|
|
23
|
+
private clientDomain;
|
|
24
|
+
constructor(iFrameFormElement: IFrameFormElement, options: any, htmlDivElement: HTMLDivElement, clientDomain?: string);
|
|
24
25
|
mount: () => void;
|
|
25
26
|
setupInputField(newValue?: boolean): void;
|
|
26
27
|
updateParentDiv: (newDiv: HTMLDivElement) => void;
|
|
@@ -4,7 +4,12 @@ declare class RevealFrame {
|
|
|
4
4
|
private domCopy?;
|
|
5
5
|
private isRevealCalled?;
|
|
6
6
|
static init(): void;
|
|
7
|
-
constructor(record: any, context: any, id: any);
|
|
7
|
+
constructor(record: any, context: any, id: any, rootDiv?: any);
|
|
8
|
+
responseUpdate: (data: any) => void;
|
|
9
|
+
getConfig: () => void;
|
|
10
|
+
getData: () => any;
|
|
11
|
+
private sub2;
|
|
12
|
+
private renderFile;
|
|
8
13
|
private getExtension;
|
|
9
14
|
private addFileRender;
|
|
10
15
|
private setRevealError;
|
|
@@ -5,8 +5,7 @@ declare class SkyflowFrameController {
|
|
|
5
5
|
static init(clientId: any): SkyflowFrameController;
|
|
6
6
|
revealData(revealRecords: IRevealRecord[], containerId: any): Promise<unknown>;
|
|
7
7
|
insertData(records: any, options: any): Promise<unknown>;
|
|
8
|
-
renderFile(data: any, iframeName: any
|
|
9
|
-
getProperties(element: any, containerId: string): any;
|
|
8
|
+
renderFile(data: any, iframeName: any): Promise<unknown>;
|
|
10
9
|
tokenize: (options: any) => Promise<unknown>;
|
|
11
10
|
parallelUploadFiles: (options: any) => Promise<unknown>;
|
|
12
11
|
uploadFiles: (fileElement: any) => Promise<unknown>;
|
|
@@ -28,5 +28,8 @@ export declare const constructElementsInsertReq: (req: any, update: any, options
|
|
|
28
28
|
records?: undefined;
|
|
29
29
|
})[];
|
|
30
30
|
export declare const updateRecordsBySkyflowID: (skyflowIdRecords: any, client: Client, options: any) => Promise<unknown>;
|
|
31
|
+
export declare const updateRecordsBySkyflowIDComposable: (skyflowIdRecords: any, client: Client, options: any, authToken: string) => Promise<unknown>;
|
|
32
|
+
export declare const insertDataInCollect: (records: any, client: Client, options: any, finalInsertRecords: any, authToken: string) => Promise<unknown>;
|
|
33
|
+
export declare const insertDataInMultipleFiles: (records: any, client: Client, options: any, finalInsertRecords: any, authToken: string) => Promise<unknown>;
|
|
31
34
|
export declare const checkForElementMatchRule: (validations: IValidationRule[]) => boolean;
|
|
32
35
|
export declare const checkForValueMatch: (validations: IValidationRule[], element: IFrameFormElement) => boolean;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import Client from '../client';
|
|
2
|
-
import { IRevealRecord, IRevealResponseType, IGetRecord, ISkyflowIdRecord, IRenderResponseType, IGetOptions, RenderFileResponse } from '../utils/common';
|
|
2
|
+
import { IRevealRecord, IRevealResponseType, IGetRecord, ISkyflowIdRecord, IRenderResponseType, IGetOptions, RenderFileResponse, IRevealRecordComposable } from '../utils/common';
|
|
3
3
|
export declare const getFileURLForRender: (skyflowIdRecord: IRevealRecord, client: Client, authToken: string) => Promise<any>;
|
|
4
4
|
export declare const getFileURLFromVaultBySkyflowID: (skyflowIdRecord: IRevealRecord, client: Client) => Promise<IRenderResponseType>;
|
|
5
|
+
export declare const getFileURLFromVaultBySkyflowIDComposable: (skyflowIdRecord: IRevealRecord, client: Client, authToken: string) => Promise<IRenderResponseType>;
|
|
5
6
|
export declare const fetchRecordsByTokenId: (tokenIdRecords: IRevealRecord[], client: Client) => Promise<IRevealResponseType>;
|
|
7
|
+
export declare const fetchRecordsByTokenIdComposable: (tokenIdRecords: IRevealRecordComposable[], client: Client, authToken: string) => Promise<IRevealResponseType>;
|
|
6
8
|
export declare const formatRecordsForIframe: (response: IRevealResponseType) => Record<string, string>;
|
|
7
9
|
export declare const formatRecordsForRender: (response: IRenderResponseType, column: any, skyflowID: any) => {
|
|
8
10
|
column: any;
|
|
@@ -26,5 +28,15 @@ export declare const formatRecordsForClient: (response: IRevealResponseType) =>
|
|
|
26
28
|
errors: Record<string, any>[] | undefined;
|
|
27
29
|
success?: undefined;
|
|
28
30
|
};
|
|
31
|
+
export declare const formatRecordsForClientComposable: (response: any) => {
|
|
32
|
+
success: never[];
|
|
33
|
+
errors: never[];
|
|
34
|
+
} | {
|
|
35
|
+
success: never[];
|
|
36
|
+
errors?: undefined;
|
|
37
|
+
} | {
|
|
38
|
+
errors: never[];
|
|
39
|
+
success?: undefined;
|
|
40
|
+
};
|
|
29
41
|
export declare const fetchRecordsGET: (skyflowIdRecords: IGetRecord[], client: Client, options?: IGetOptions) => Promise<unknown>;
|
|
30
42
|
export declare const fetchRecordsBySkyflowID: (skyflowIdRecords: ISkyflowIdRecord[], client: Client) => Promise<unknown>;
|
package/types/skyflow.d.ts
CHANGED
|
@@ -5,10 +5,12 @@ import SkyflowError from './libs/skyflow-error';
|
|
|
5
5
|
import { RequestMethod, IInsertRecordInput, IDetokenizeInput, IGetInput, RedactionType, EventName, Env, LogLevel, ValidationRuleType, IGetByIdInput, IInsertOptions, IDeleteRecordInput, IDeleteOptions, IGetOptions, InsertResponse, GetResponse, GetByIdResponse, DeleteResponse, ContainerOptions, DetokenizeResponse } from './utils/common';
|
|
6
6
|
import ComposableContainer from './core/external/collect/compose-collect-container';
|
|
7
7
|
import ThreeDS from './core/external/threeds/threeds';
|
|
8
|
+
import ComposableRevealContainer from './core/external/reveal/composable-reveal-container';
|
|
8
9
|
export declare enum ContainerType {
|
|
9
10
|
COLLECT = "COLLECT",
|
|
10
11
|
REVEAL = "REVEAL",
|
|
11
|
-
COMPOSABLE = "COMPOSABLE"
|
|
12
|
+
COMPOSABLE = "COMPOSABLE",
|
|
13
|
+
COMPOSE_REVEAL = "COMPOSABLE_REVEAL"
|
|
12
14
|
}
|
|
13
15
|
export interface ISkyflow {
|
|
14
16
|
vaultID?: string;
|
|
@@ -23,6 +25,7 @@ declare class Skyflow {
|
|
|
23
25
|
container(type: ContainerType.COLLECT, options?: ContainerOptions): CollectContainer;
|
|
24
26
|
container(type: ContainerType.COMPOSABLE, options?: ContainerOptions): ComposableContainer;
|
|
25
27
|
container(type: ContainerType.REVEAL, options?: ContainerOptions): RevealContainer;
|
|
28
|
+
container(type: ContainerType.COMPOSE_REVEAL, options?: ContainerOptions): ComposableRevealContainer;
|
|
26
29
|
insert(records: IInsertRecordInput, options?: IInsertOptions): Promise<InsertResponse>;
|
|
27
30
|
detokenize(detokenizeInput: IDetokenizeInput): Promise<DetokenizeResponse>;
|
|
28
31
|
getById(getByIdInput: IGetByIdInput): Promise<GetByIdResponse>;
|
|
@@ -60,6 +60,14 @@ export interface IRevealRecord {
|
|
|
60
60
|
skyflowID?: string;
|
|
61
61
|
table?: string;
|
|
62
62
|
}
|
|
63
|
+
export interface IRevealRecordComposable {
|
|
64
|
+
token?: string;
|
|
65
|
+
redaction?: RedactionType;
|
|
66
|
+
column?: string;
|
|
67
|
+
skyflowID?: string;
|
|
68
|
+
table?: string;
|
|
69
|
+
iframeName?: string;
|
|
70
|
+
}
|
|
63
71
|
export interface IInsertResponse {
|
|
64
72
|
records: IInsertResponseReocrds[];
|
|
65
73
|
}
|
|
@@ -260,6 +268,9 @@ export interface ICollectOptions {
|
|
|
260
268
|
additionalFields?: IInsertRecordInput;
|
|
261
269
|
upsert?: Array<IUpsertOptions>;
|
|
262
270
|
}
|
|
271
|
+
export interface MetaData {
|
|
272
|
+
[key: string]: any;
|
|
273
|
+
}
|
|
263
274
|
export interface UploadFilesResponse {
|
|
264
275
|
fileUploadResponse: [{
|
|
265
276
|
skyflow_id: string;
|
package/types/utils/logs.d.ts
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
declare const logs: {
|
|
2
2
|
infoLogs: {
|
|
3
|
-
TOKENIZE_REQUEST: string;
|
|
4
|
-
TOKENIZE_REQUEST_INSERT: string;
|
|
5
|
-
TOKENIZE_REQUEST_CREATED: string;
|
|
6
3
|
INITIALIZE_CLIENT: string;
|
|
7
4
|
CLIENT_INITIALIZED: string;
|
|
8
5
|
CREATE_COLLECT_CONTAINER: string;
|
|
9
6
|
COLLECT_CONTAINER_CREATED: string;
|
|
7
|
+
INITIALIZE_COMPOSABLE_CLIENT: string;
|
|
10
8
|
CREATE_REVEAL_CONTAINER: string;
|
|
11
9
|
REVEAL_CONTAINER_CREATED: string;
|
|
12
10
|
VALIDATE_RECORDS: string;
|
|
@@ -21,6 +19,8 @@ declare const logs: {
|
|
|
21
19
|
ELEMENT_REVEALED: string;
|
|
22
20
|
FILE_RENDERED: string;
|
|
23
21
|
COLLECT_SUBMIT_SUCCESS: string;
|
|
22
|
+
UPLOAD_FILES_SUCCESS: string;
|
|
23
|
+
MULTI_UPLOAD_FILES_SUCCESS: string;
|
|
24
24
|
REVEAL_SUBMIT_SUCCESS: string;
|
|
25
25
|
RENDER_SUBMIT_SUCCESS: string;
|
|
26
26
|
INSERT_DATA_SUCCESS: string;
|
|
@@ -77,7 +77,8 @@ declare const logs: {
|
|
|
77
77
|
VALIDATE_GET_BY_ID_INPUT: string;
|
|
78
78
|
};
|
|
79
79
|
errorLogs: {
|
|
80
|
-
|
|
80
|
+
MULTI_FILE_NOT_SUPPORTED: string;
|
|
81
|
+
INVALID_REVEAL_COMPOSABLE_INPUT: string;
|
|
81
82
|
NO_ELEMENTS_IN_COLLECT: string;
|
|
82
83
|
NO_ELEMENTS_IN_COMPOSABLE: string;
|
|
83
84
|
NO_ELEMENTS_IN_REVEAL: string;
|