diff --git a/App/common/interface/MemberDetailsResponse.ts b/App/common/interface/MemberDetailsResponse.ts deleted file mode 100644 index 18c984b7b5..0000000000 --- a/App/common/interface/MemberDetailsResponse.ts +++ /dev/null @@ -1,181 +0,0 @@ -import { Widget, GenericWidgetData } from "./widgets/Widget"; - -export interface MemberDetailsRootObject { - applicationResponse: ApplicationResponse; - currentScreenCta: CurrentScreenCta; - currentScreenDefinition: CurrentScreenDefinition; -} - -interface CurrentScreenDefinition { - screenData: ScreenData; -} - -interface ScreenData { - metaData: ScreenMetaData; - screenStructure: ScreenStructure; -} - -interface ScreenStructure { - drawer: Drawer; - footer: Footer; - header: Header; - content: Content; - renderActions: RenderActions; - systemBackCta: SystemBackCta; - floatingActionButton: Drawer; -} - -interface SystemBackCta { - actions: Action2[]; -} - -interface Action2 { - type: string; - ctaData: Cta; -} - -interface RenderActions { - preRenderAction: Drawer; - postRenderAction: PostRenderAction; -} - -interface PostRenderAction { - actions: Action[]; -} - -interface Action { - type: string; - isNeededForFirebase: boolean; - isNeededForAppsflyer: boolean; - predefinedEventProperties: PredefinedEventProperty[]; -} - -interface PredefinedEventProperty { - propertyName: string; - propertyValue: string; -} - -interface Content { - widgets: Widget[]; - backgroundColor: string; -} - -interface InfoDisplayWidgetData extends GenericWidgetData { - cardData?: Container; - titleData?: Banner; - leftIconData?: LeftBottomEndTextIcon; -} - -interface NameDobWidget extends GenericWidgetData { - endInput?: EndInput; - labelTitle?: Banner; - startInput?: StartInput; - outputFields?: OutputFields; -} -interface OutputFields { - endInputField: string; - startInputField: string; -} -interface StartInput { - hint: string; - style: Drawer; - keyboardType: string; -} - -interface EndInput { - hint: string; - style: Drawer; - endIconUrl: string; -} - -interface Header { - widgetId: string; - widgetData: HeaderWidgetData; - widgetType: string; -} - -interface HeaderWidgetData { - backIconData: LeftBottomEndTextIcon; - endTitleData: Banner; - middleTitleData: Banner; -} - -interface Footer { - widgetId: string; - widgetData: FooterWidgetData; - widgetName: string; - widgetType: string; -} - -interface FooterWidgetData { - banner: Banner; - progress: Progress; - rightCta: RightCta; - leftBottomText: Banner; - leftTopStrikedText: Banner; - leftTopUnstrikedText: Banner; - leftBottomEndTextIcon: LeftBottomEndTextIcon; -} - -interface LeftBottomEndTextIcon { - style: Drawer; - iconUrl: string; -} - -interface RightCta { - title: Banner; - container: Container; -} - -interface Container { - style: Drawer; -} - -interface Progress { - style: Drawer; - progress: string; -} - -interface Banner { - text: string; - style: Drawer; -} - -interface Drawer {} - -interface CurrentScreenCta { - cta: Cta; - shouldPoll: boolean; - shouldRender: boolean; - screenMetaData: ScreenMetaData; - screenPollingConfigs: ScreenPollingConfigs; -} - -interface ScreenPollingConfigs { - initialDelay: number; - interval: number; - numOfRetries: number; -} - -interface ScreenMetaData { - screenName: string; - screenType: string; -} - -interface Cta { - url: string; - parameters: Parameter[]; -} - -interface Parameter { - key: string; - value: string; -} - -interface ApplicationResponse { - applicationType: string; - applicationId: string; - applicantType: string; - applicationStatus: string; - configVersion: string; -} diff --git a/network/BuildConfigDetails.ts b/network/BuildConfigDetails.ts new file mode 100644 index 0000000000..c4929603c1 --- /dev/null +++ b/network/BuildConfigDetails.ts @@ -0,0 +1,6 @@ +interface BuildConfigDetails { + baseUrl?: string; + appVersionName?: string; + appVersionCode?: string; + flavor: string; +} diff --git a/network/NetworkConstant.ts b/network/NetworkConstant.ts index b766b22339..ab21ffd0e6 100644 --- a/network/NetworkConstant.ts +++ b/network/NetworkConstant.ts @@ -1,6 +1,3 @@ export const BASE_URL = "https://sa.navi.com"; -export const APPLICATION_ID_PATH = "/arc-warden/api/v2/application"; -export const FILL_APPLICATION_PATH = - "/arc-warden/api/v2/application/:applicationId/fill"; export const BUNDLE_VERSION = "x-rn-bundle-version"; -export const GZIP = "gzip"; \ No newline at end of file +export const GZIP = "gzip"; diff --git a/network/payloads/request/FillApplicationRequest.ts b/network/payloads/request/FillApplicationRequest.ts deleted file mode 100644 index 8ca586a2b1..0000000000 --- a/network/payloads/request/FillApplicationRequest.ts +++ /dev/null @@ -1,24 +0,0 @@ -interface Field { - key: string; - value: string; -} - -interface ApplicationFields { - fields: Field[]; -} - -interface FillRequest { - applicationFields: ApplicationFields; - applicationType: string; -} - -interface ScreenRequest { - action: string; - isScreenDefinitionRequired: boolean; - sourceScreen: string; -} - -interface AppFormData { - fillRequest: FillRequest; - screenRequest: ScreenRequest; -} diff --git a/network/payloads/response/FillApplicationResponse.ts b/network/payloads/response/FillApplicationResponse.ts deleted file mode 100644 index 14bf8aad0d..0000000000 --- a/network/payloads/response/FillApplicationResponse.ts +++ /dev/null @@ -1,33 +0,0 @@ -interface FillApplicationResponse { - currentScreenCta: CurrentScreenCta; -} - -interface CurrentScreenCta { - cta: Cta; - shouldPoll: boolean; - shouldRender: boolean; - screenMetaData: ScreenMetaData; - screenPollingConfigs: ScreenPollingConfigs; -} - -interface ScreenPollingConfigs { - initialDelay: number; - interval: number; - numOfRetries: number; -} - -interface ScreenMetaData { - screenName: string; - screenType: string; - screenHash: string; -} - -interface Cta { - url: string; - parameters: Parameter[]; -} - -interface Parameter { - key: string; - value: string; -} diff --git a/network/repo/BuildConfigDetails.ts b/network/repo/BuildConfigDetails.ts deleted file mode 100644 index 0d9b695922..0000000000 --- a/network/repo/BuildConfigDetails.ts +++ /dev/null @@ -1,7 +0,0 @@ - -interface BuildConfigDetails { - baseUrl?: string; - appVersionName?: string; - appVersionCode?: string; - flavor: string -} \ No newline at end of file diff --git a/network/repo/GiApplicationRepo.ts b/network/repo/GiApplicationRepo.ts deleted file mode 100644 index ce26b7428a..0000000000 --- a/network/repo/GiApplicationRepo.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { patch, post } from "../NetworkService"; -import { APPLICATION_ID_PATH, FILL_APPLICATION_PATH } from "../NetworkConstant"; -import { MemberDetailsRootObject } from "../../App/common/interface/MemberDetailsResponse"; - -export const getApplicationId = ( - applicationType: string = "DEMO_11", - applicantType: string = "CUSTOMER" -) => { - const path = APPLICATION_ID_PATH; - const requestBody = JSON.stringify({ - applicantType: applicantType, - applicationType: applicationType, - isScreenCtaRequired: true, - isScreenDefinitionRequired: true, - }); - return post>(path, requestBody); -}; - -export const fillApplication = (applicationId: string, fields: Field[]) => { - const updatedPath = FILL_APPLICATION_PATH.replace( - ":applicationId", - applicationId - ); - - const requestBody: AppFormData = { - fillRequest: { - applicationFields: { - fields: fields, - }, - applicationType: "DEMO_11", - }, - screenRequest: { - action: "NEXT", - isScreenDefinitionRequired: true, - sourceScreen: "home", - }, - }; - return patch>(updatedPath, requestBody); -};