@omniretail/lending 0.0.0-stage → 3.0.0
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 +322 -2
- package/lib/assets/fonts/GorditaBold.ttf +0 -0
- package/lib/assets/fonts/GorditaMedium.ttf +0 -0
- package/lib/assets/fonts/GorditaRegular.ttf +0 -0
- package/lib/assets/lending/close.png +0 -0
- package/lib/assets/lending/icon-apply.png +0 -0
- package/lib/assets/lending/icon-approval-clock.png +0 -0
- package/lib/assets/lending/icon-clock.png +0 -0
- package/lib/assets/lending/icon-close.png +0 -0
- package/lib/assets/lending/icon-copy.png +0 -0
- package/lib/assets/lending/icon-download.png +0 -0
- package/lib/assets/lending/icon-eye.png +0 -0
- package/lib/assets/lending/icon-filter.png +0 -0
- package/lib/assets/lending/icon-history.png +0 -0
- package/lib/assets/lending/icon-megaphone.png +0 -0
- package/lib/assets/lending/icon-payment-success.png +0 -0
- package/lib/assets/lending/icon-plan-check.png +0 -0
- package/lib/assets/lending/icon-plus.png +0 -0
- package/lib/assets/lending/icon-radio-on.png +0 -0
- package/lib/assets/lending/icon-repay.png +0 -0
- package/lib/assets/lending/icon-statement-synced.png +0 -0
- package/lib/assets/lending/icon-step-done.png +0 -0
- package/lib/assets/lending/icon-step-pending.png +0 -0
- package/lib/assets/lending/icon-submitted-check.png +0 -0
- package/lib/assets/lending/icon-synced.png +0 -0
- package/lib/assets/lending/icon-tx-credit.png +0 -0
- package/lib/assets/lending/icon-tx-debit.png +0 -0
- package/lib/assets/lending/icon-upgrade.png +0 -0
- package/lib/assets/lending/icon-upload.png +0 -0
- package/lib/assets/lending/illo-auth-details.png +0 -0
- package/lib/assets/lending/illo-brand-selection.png +0 -0
- package/lib/assets/lending/illo-coins.png +0 -0
- package/lib/assets/lending/illo-credit-amount.png +0 -0
- package/lib/assets/lending/illo-customer-agreement.png +0 -0
- package/lib/assets/lending/illo-hand.png +0 -0
- package/lib/assets/lending/illo-limit-pending.png +0 -0
- package/lib/assets/lending/illo-limit-rejected.png +0 -0
- package/lib/assets/lending/illo-manufacturer.png +0 -0
- package/lib/assets/lending/illo-no-active-credit.png +0 -0
- package/lib/assets/lending/illo-proof-account.png +0 -0
- package/lib/assets/lending/illo-repay-phone.png +0 -0
- package/lib/assets/lending/illo-request-pending.png +0 -0
- package/lib/assets/lending/logo-cbn.png +0 -0
- package/lib/assets/lending/logo-collections.png +0 -0
- package/lib/assets/lending/logo-fmn.png +0 -0
- package/lib/assets/lending/logo-golden-penny.png +0 -0
- package/lib/assets/lending/logo-guinness.png +0 -0
- package/lib/assets/lending/logo-ndic.png +0 -0
- package/lib/assets/lending/logo-nestle.png +0 -0
- package/lib/assets/lending/logo-omnipay.png +0 -0
- package/lib/assets/lending/sig-beneficiary.png +0 -0
- package/lib/assets/lending/sig-omnipay.png +0 -0
- package/lib/assets/lending/watermark-receipt.png +0 -0
- package/lib/components/IconBack.d.ts +7 -0
- package/lib/components/IconBack.d.ts.map +1 -0
- package/lib/components/IconBack.js +17 -0
- package/lib/components/IconBack.js.map +1 -0
- package/lib/components/LicensingFooter.d.ts +6 -0
- package/lib/components/LicensingFooter.d.ts.map +1 -0
- package/lib/components/LicensingFooter.js +76 -0
- package/lib/components/LicensingFooter.js.map +1 -0
- package/lib/components/ScreenHeader.d.ts +10 -0
- package/lib/components/ScreenHeader.d.ts.map +1 -0
- package/lib/components/ScreenHeader.js +72 -0
- package/lib/components/ScreenHeader.js.map +1 -0
- package/lib/components/index.d.ts +5 -0
- package/lib/components/index.d.ts.map +1 -0
- package/lib/components/index.js +4 -0
- package/lib/components/index.js.map +1 -0
- package/lib/flows/lending/AgreementSigningSheet.d.ts +8 -0
- package/lib/flows/lending/AgreementSigningSheet.d.ts.map +1 -0
- package/lib/flows/lending/AgreementSigningSheet.js +178 -0
- package/lib/flows/lending/AgreementSigningSheet.js.map +1 -0
- package/lib/flows/lending/ApplyCreditFlow.d.ts +6 -0
- package/lib/flows/lending/ApplyCreditFlow.d.ts.map +1 -0
- package/lib/flows/lending/ApplyCreditFlow.js +64 -0
- package/lib/flows/lending/ApplyCreditFlow.js.map +1 -0
- package/lib/flows/lending/AuthorisationDetailsSheet.d.ts +9 -0
- package/lib/flows/lending/AuthorisationDetailsSheet.d.ts.map +1 -0
- package/lib/flows/lending/AuthorisationDetailsSheet.js +94 -0
- package/lib/flows/lending/AuthorisationDetailsSheet.js.map +1 -0
- package/lib/flows/lending/BankListSheet.d.ts +12 -0
- package/lib/flows/lending/BankListSheet.d.ts.map +1 -0
- package/lib/flows/lending/BankListSheet.js +105 -0
- package/lib/flows/lending/BankListSheet.js.map +1 -0
- package/lib/flows/lending/BankStatementSyncedSheet.d.ts +7 -0
- package/lib/flows/lending/BankStatementSyncedSheet.d.ts.map +1 -0
- package/lib/flows/lending/BankStatementSyncedSheet.js +71 -0
- package/lib/flows/lending/BankStatementSyncedSheet.js.map +1 -0
- package/lib/flows/lending/BottomSheet.d.ts +11 -0
- package/lib/flows/lending/BottomSheet.d.ts.map +1 -0
- package/lib/flows/lending/BottomSheet.js +72 -0
- package/lib/flows/lending/BottomSheet.js.map +1 -0
- package/lib/flows/lending/BrandCreditOverview.d.ts +6 -0
- package/lib/flows/lending/BrandCreditOverview.d.ts.map +1 -0
- package/lib/flows/lending/BrandCreditOverview.js +43 -0
- package/lib/flows/lending/BrandCreditOverview.js.map +1 -0
- package/lib/flows/lending/BrandLimitCard.d.ts +19 -0
- package/lib/flows/lending/BrandLimitCard.d.ts.map +1 -0
- package/lib/flows/lending/BrandLimitCard.js +122 -0
- package/lib/flows/lending/BrandLimitCard.js.map +1 -0
- package/lib/flows/lending/BrandSelectionSheet.d.ts +10 -0
- package/lib/flows/lending/BrandSelectionSheet.d.ts.map +1 -0
- package/lib/flows/lending/BrandSelectionSheet.js +88 -0
- package/lib/flows/lending/BrandSelectionSheet.js.map +1 -0
- package/lib/flows/lending/CompletePaymentSheet.d.ts +11 -0
- package/lib/flows/lending/CompletePaymentSheet.d.ts.map +1 -0
- package/lib/flows/lending/CompletePaymentSheet.js +139 -0
- package/lib/flows/lending/CompletePaymentSheet.js.map +1 -0
- package/lib/flows/lending/ConfirmStatusSheet.d.ts +11 -0
- package/lib/flows/lending/ConfirmStatusSheet.d.ts.map +1 -0
- package/lib/flows/lending/ConfirmStatusSheet.js +63 -0
- package/lib/flows/lending/ConfirmStatusSheet.js.map +1 -0
- package/lib/flows/lending/CreditAgreementSheet.d.ts +13 -0
- package/lib/flows/lending/CreditAgreementSheet.d.ts.map +1 -0
- package/lib/flows/lending/CreditAgreementSheet.js +242 -0
- package/lib/flows/lending/CreditAgreementSheet.js.map +1 -0
- package/lib/flows/lending/CreditAmountSheet.d.ts +9 -0
- package/lib/flows/lending/CreditAmountSheet.d.ts.map +1 -0
- package/lib/flows/lending/CreditAmountSheet.js +96 -0
- package/lib/flows/lending/CreditAmountSheet.js.map +1 -0
- package/lib/flows/lending/CreditBreakdownSheet.d.ts +8 -0
- package/lib/flows/lending/CreditBreakdownSheet.d.ts.map +1 -0
- package/lib/flows/lending/CreditBreakdownSheet.js +82 -0
- package/lib/flows/lending/CreditBreakdownSheet.js.map +1 -0
- package/lib/flows/lending/CreditFlow.d.ts +12 -0
- package/lib/flows/lending/CreditFlow.d.ts.map +1 -0
- package/lib/flows/lending/CreditFlow.js +458 -0
- package/lib/flows/lending/CreditFlow.js.map +1 -0
- package/lib/flows/lending/CreditHistory.screen.d.ts +10 -0
- package/lib/flows/lending/CreditHistory.screen.d.ts.map +1 -0
- package/lib/flows/lending/CreditHistory.screen.js +138 -0
- package/lib/flows/lending/CreditHistory.screen.js.map +1 -0
- package/lib/flows/lending/CreditReceipt.screen.d.ts +12 -0
- package/lib/flows/lending/CreditReceipt.screen.d.ts.map +1 -0
- package/lib/flows/lending/CreditReceipt.screen.js +73 -0
- package/lib/flows/lending/CreditReceipt.screen.js.map +1 -0
- package/lib/flows/lending/CreditUpgrade.screen.d.ts +12 -0
- package/lib/flows/lending/CreditUpgrade.screen.d.ts.map +1 -0
- package/lib/flows/lending/CreditUpgrade.screen.js +168 -0
- package/lib/flows/lending/CreditUpgrade.screen.js.map +1 -0
- package/lib/flows/lending/DowngradeLimitSheet.d.ts +8 -0
- package/lib/flows/lending/DowngradeLimitSheet.d.ts.map +1 -0
- package/lib/flows/lending/DowngradeLimitSheet.js +103 -0
- package/lib/flows/lending/DowngradeLimitSheet.js.map +1 -0
- package/lib/flows/lending/FindCreditSheet.d.ts +11 -0
- package/lib/flows/lending/FindCreditSheet.d.ts.map +1 -0
- package/lib/flows/lending/FindCreditSheet.js +140 -0
- package/lib/flows/lending/FindCreditSheet.js.map +1 -0
- package/lib/flows/lending/FlatLoanAgreementBody.d.ts +10 -0
- package/lib/flows/lending/FlatLoanAgreementBody.d.ts.map +1 -0
- package/lib/flows/lending/FlatLoanAgreementBody.js +224 -0
- package/lib/flows/lending/FlatLoanAgreementBody.js.map +1 -0
- package/lib/flows/lending/FlatLoanDetailsSheet.d.ts +6 -0
- package/lib/flows/lending/FlatLoanDetailsSheet.d.ts.map +1 -0
- package/lib/flows/lending/FlatLoanDetailsSheet.js +127 -0
- package/lib/flows/lending/FlatLoanDetailsSheet.js.map +1 -0
- package/lib/flows/lending/GetStatementSheet.d.ts +6 -0
- package/lib/flows/lending/GetStatementSheet.d.ts.map +1 -0
- package/lib/flows/lending/GetStatementSheet.js +90 -0
- package/lib/flows/lending/GetStatementSheet.js.map +1 -0
- package/lib/flows/lending/HistoryFilterSheet.d.ts +6 -0
- package/lib/flows/lending/HistoryFilterSheet.d.ts.map +1 -0
- package/lib/flows/lending/HistoryFilterSheet.js +140 -0
- package/lib/flows/lending/HistoryFilterSheet.js.map +1 -0
- package/lib/flows/lending/IconClose.d.ts +6 -0
- package/lib/flows/lending/IconClose.d.ts.map +1 -0
- package/lib/flows/lending/IconClose.js +11 -0
- package/lib/flows/lending/IconClose.js.map +1 -0
- package/lib/flows/lending/IconEyeOpen.d.ts +4 -0
- package/lib/flows/lending/IconEyeOpen.d.ts.map +1 -0
- package/lib/flows/lending/IconEyeOpen.js +11 -0
- package/lib/flows/lending/IconEyeOpen.js.map +1 -0
- package/lib/flows/lending/IconPayArrow.d.ts +5 -0
- package/lib/flows/lending/IconPayArrow.d.ts.map +1 -0
- package/lib/flows/lending/IconPayArrow.js +10 -0
- package/lib/flows/lending/IconPayArrow.js.map +1 -0
- package/lib/flows/lending/IconPinStar.d.ts +10 -0
- package/lib/flows/lending/IconPinStar.d.ts.map +1 -0
- package/lib/flows/lending/IconPinStar.js +11 -0
- package/lib/flows/lending/IconPinStar.js.map +1 -0
- package/lib/flows/lending/IncreaseSpendingLimitSheet.d.ts +6 -0
- package/lib/flows/lending/IncreaseSpendingLimitSheet.d.ts.map +1 -0
- package/lib/flows/lending/IncreaseSpendingLimitSheet.js +115 -0
- package/lib/flows/lending/IncreaseSpendingLimitSheet.js.map +1 -0
- package/lib/flows/lending/Lending.screen.d.ts +12 -0
- package/lib/flows/lending/Lending.screen.d.ts.map +1 -0
- package/lib/flows/lending/Lending.screen.js +244 -0
- package/lib/flows/lending/Lending.screen.js.map +1 -0
- package/lib/flows/lending/LendingDetails.screen.d.ts +5 -0
- package/lib/flows/lending/LendingDetails.screen.d.ts.map +1 -0
- package/lib/flows/lending/LendingDetails.screen.js +34 -0
- package/lib/flows/lending/LendingDetails.screen.js.map +1 -0
- package/lib/flows/lending/LimitHomeWithLimit.screen.d.ts +17 -0
- package/lib/flows/lending/LimitHomeWithLimit.screen.d.ts.map +1 -0
- package/lib/flows/lending/LimitHomeWithLimit.screen.js +295 -0
- package/lib/flows/lending/LimitHomeWithLimit.screen.js.map +1 -0
- package/lib/flows/lending/ListSearchField.d.ts +8 -0
- package/lib/flows/lending/ListSearchField.d.ts.map +1 -0
- package/lib/flows/lending/ListSearchField.js +37 -0
- package/lib/flows/lending/ListSearchField.js.map +1 -0
- package/lib/flows/lending/ManufacturerListSheet.d.ts +7 -0
- package/lib/flows/lending/ManufacturerListSheet.d.ts.map +1 -0
- package/lib/flows/lending/ManufacturerListSheet.js +83 -0
- package/lib/flows/lending/ManufacturerListSheet.js.map +1 -0
- package/lib/flows/lending/ManufacturerStatementSheet.d.ts +15 -0
- package/lib/flows/lending/ManufacturerStatementSheet.d.ts.map +1 -0
- package/lib/flows/lending/ManufacturerStatementSheet.js +177 -0
- package/lib/flows/lending/ManufacturerStatementSheet.js.map +1 -0
- package/lib/flows/lending/PaymentSuccessfulSheet.d.ts +6 -0
- package/lib/flows/lending/PaymentSuccessfulSheet.d.ts.map +1 -0
- package/lib/flows/lending/PaymentSuccessfulSheet.js +56 -0
- package/lib/flows/lending/PaymentSuccessfulSheet.js.map +1 -0
- package/lib/flows/lending/ProofOfAccountSheet.d.ts +23 -0
- package/lib/flows/lending/ProofOfAccountSheet.d.ts.map +1 -0
- package/lib/flows/lending/ProofOfAccountSheet.js +213 -0
- package/lib/flows/lending/ProofOfAccountSheet.js.map +1 -0
- package/lib/flows/lending/ReferScreenChrome.d.ts +8 -0
- package/lib/flows/lending/ReferScreenChrome.d.ts.map +1 -0
- package/lib/flows/lending/ReferScreenChrome.js +31 -0
- package/lib/flows/lending/ReferScreenChrome.js.map +1 -0
- package/lib/flows/lending/ReferralCodeSheet.d.ts +11 -0
- package/lib/flows/lending/ReferralCodeSheet.d.ts.map +1 -0
- package/lib/flows/lending/ReferralCodeSheet.js +137 -0
- package/lib/flows/lending/ReferralCodeSheet.js.map +1 -0
- package/lib/flows/lending/RepayCredit.screen.d.ts +6 -0
- package/lib/flows/lending/RepayCredit.screen.d.ts.map +1 -0
- package/lib/flows/lending/RepayCredit.screen.js +352 -0
- package/lib/flows/lending/RepayCredit.screen.js.map +1 -0
- package/lib/flows/lending/RepayErrorSheet.d.ts +6 -0
- package/lib/flows/lending/RepayErrorSheet.d.ts.map +1 -0
- package/lib/flows/lending/RepayErrorSheet.js +71 -0
- package/lib/flows/lending/RepayErrorSheet.js.map +1 -0
- package/lib/flows/lending/RepaymentPlanSheet.d.ts +8 -0
- package/lib/flows/lending/RepaymentPlanSheet.d.ts.map +1 -0
- package/lib/flows/lending/RepaymentPlanSheet.js +49 -0
- package/lib/flows/lending/RepaymentPlanSheet.js.map +1 -0
- package/lib/flows/lending/RequestPendingSheet.d.ts +9 -0
- package/lib/flows/lending/RequestPendingSheet.d.ts.map +1 -0
- package/lib/flows/lending/RequestPendingSheet.js +109 -0
- package/lib/flows/lending/RequestPendingSheet.js.map +1 -0
- package/lib/flows/lending/SubLimitEmpty.d.ts +5 -0
- package/lib/flows/lending/SubLimitEmpty.d.ts.map +1 -0
- package/lib/flows/lending/SubLimitEmpty.js +65 -0
- package/lib/flows/lending/SubLimitEmpty.js.map +1 -0
- package/lib/flows/lending/Transactions.screen.d.ts +5 -0
- package/lib/flows/lending/Transactions.screen.d.ts.map +1 -0
- package/lib/flows/lending/Transactions.screen.js +124 -0
- package/lib/flows/lending/Transactions.screen.js.map +1 -0
- package/lib/flows/lending/agreements/CustomerAgreementBody.d.ts +8 -0
- package/lib/flows/lending/agreements/CustomerAgreementBody.d.ts.map +1 -0
- package/lib/flows/lending/agreements/CustomerAgreementBody.js +35 -0
- package/lib/flows/lending/agreements/CustomerAgreementBody.js.map +1 -0
- package/lib/flows/lending/agreements/agreementFormat.d.ts +16 -0
- package/lib/flows/lending/agreements/agreementFormat.d.ts.map +1 -0
- package/lib/flows/lending/agreements/agreementFormat.js +73 -0
- package/lib/flows/lending/agreements/agreementFormat.js.map +1 -0
- package/lib/flows/lending/agreements/agreementPrintHtml.d.ts +7 -0
- package/lib/flows/lending/agreements/agreementPrintHtml.d.ts.map +1 -0
- package/lib/flows/lending/agreements/agreementPrintHtml.generated.d.ts +7 -0
- package/lib/flows/lending/agreements/agreementPrintHtml.generated.d.ts.map +1 -0
- package/lib/flows/lending/agreements/agreementPrintHtml.generated.js +5520 -0
- package/lib/flows/lending/agreements/agreementPrintHtml.generated.js.map +1 -0
- package/lib/flows/lending/agreements/agreementPrintHtml.js +32 -0
- package/lib/flows/lending/agreements/agreementPrintHtml.js.map +1 -0
- package/lib/flows/lending/agreements/agreementStyles.d.ts +92 -0
- package/lib/flows/lending/agreements/agreementStyles.d.ts.map +1 -0
- package/lib/flows/lending/agreements/agreementStyles.js +70 -0
- package/lib/flows/lending/agreements/agreementStyles.js.map +1 -0
- package/lib/flows/lending/agreements/agreementTypes.d.ts +11 -0
- package/lib/flows/lending/agreements/agreementTypes.d.ts.map +1 -0
- package/lib/flows/lending/agreements/agreementTypes.js +2 -0
- package/lib/flows/lending/agreements/agreementTypes.js.map +1 -0
- package/lib/flows/lending/agreements/generalAgreement.d.ts +4 -0
- package/lib/flows/lending/agreements/generalAgreement.d.ts.map +1 -0
- package/lib/flows/lending/agreements/generalAgreement.js +14 -0
- package/lib/flows/lending/agreements/generalAgreement.js.map +1 -0
- package/lib/flows/lending/agreements/generalAgreementV2.d.ts +4 -0
- package/lib/flows/lending/agreements/generalAgreementV2.d.ts.map +1 -0
- package/lib/flows/lending/agreements/generalAgreementV2.js +14 -0
- package/lib/flows/lending/agreements/generalAgreementV2.js.map +1 -0
- package/lib/flows/lending/agreements/generalAgreementV3.d.ts +4 -0
- package/lib/flows/lending/agreements/generalAgreementV3.d.ts.map +1 -0
- package/lib/flows/lending/agreements/generalAgreementV3.js +14 -0
- package/lib/flows/lending/agreements/generalAgreementV3.js.map +1 -0
- package/lib/flows/lending/agreements/generalAgreementV4.d.ts +4 -0
- package/lib/flows/lending/agreements/generalAgreementV4.d.ts.map +1 -0
- package/lib/flows/lending/agreements/generalAgreementV4.js +14 -0
- package/lib/flows/lending/agreements/generalAgreementV4.js.map +1 -0
- package/lib/flows/lending/agreements/generalAgreementV5.d.ts +4 -0
- package/lib/flows/lending/agreements/generalAgreementV5.d.ts.map +1 -0
- package/lib/flows/lending/agreements/generalAgreementV5.js +14 -0
- package/lib/flows/lending/agreements/generalAgreementV5.js.map +1 -0
- package/lib/flows/lending/agreements/ghanaAgreement.d.ts +4 -0
- package/lib/flows/lending/agreements/ghanaAgreement.d.ts.map +1 -0
- package/lib/flows/lending/agreements/ghanaAgreement.js +14 -0
- package/lib/flows/lending/agreements/ghanaAgreement.js.map +1 -0
- package/lib/flows/lending/agreements/mcplAgreement.d.ts +4 -0
- package/lib/flows/lending/agreements/mcplAgreement.d.ts.map +1 -0
- package/lib/flows/lending/agreements/mcplAgreement.js +14 -0
- package/lib/flows/lending/agreements/mcplAgreement.js.map +1 -0
- package/lib/flows/lending/agreements/mcplAgreementV2.d.ts +4 -0
- package/lib/flows/lending/agreements/mcplAgreementV2.d.ts.map +1 -0
- package/lib/flows/lending/agreements/mcplAgreementV2.js +14 -0
- package/lib/flows/lending/agreements/mcplAgreementV2.js.map +1 -0
- package/lib/flows/lending/agreements/omnibizAgreement.d.ts +4 -0
- package/lib/flows/lending/agreements/omnibizAgreement.d.ts.map +1 -0
- package/lib/flows/lending/agreements/omnibizAgreement.js +14 -0
- package/lib/flows/lending/agreements/omnibizAgreement.js.map +1 -0
- package/lib/flows/lending/agreements/omnibizAgreementV2.d.ts +4 -0
- package/lib/flows/lending/agreements/omnibizAgreementV2.d.ts.map +1 -0
- package/lib/flows/lending/agreements/omnibizAgreementV2.js +14 -0
- package/lib/flows/lending/agreements/omnibizAgreementV2.js.map +1 -0
- package/lib/flows/lending/agreements/pickAgreementKind.d.ts +13 -0
- package/lib/flows/lending/agreements/pickAgreementKind.d.ts.map +1 -0
- package/lib/flows/lending/agreements/pickAgreementKind.js +43 -0
- package/lib/flows/lending/agreements/pickAgreementKind.js.map +1 -0
- package/lib/flows/lending/downloadDisplayedAgreement.d.ts +13 -0
- package/lib/flows/lending/downloadDisplayedAgreement.d.ts.map +1 -0
- package/lib/flows/lending/downloadDisplayedAgreement.js +48 -0
- package/lib/flows/lending/downloadDisplayedAgreement.js.map +1 -0
- package/lib/flows/lending/ghanaBanks.d.ts +3 -0
- package/lib/flows/lending/ghanaBanks.d.ts.map +1 -0
- package/lib/flows/lending/ghanaBanks.js +7 -0
- package/lib/flows/lending/ghanaBanks.js.map +1 -0
- package/lib/flows/lending/inventoryCreditAgreementCopy.d.ts +4 -0
- package/lib/flows/lending/inventoryCreditAgreementCopy.d.ts.map +1 -0
- package/lib/flows/lending/inventoryCreditAgreementCopy.js +117 -0
- package/lib/flows/lending/inventoryCreditAgreementCopy.js.map +1 -0
- package/lib/flows/lending/manufacturers.d.ts +11 -0
- package/lib/flows/lending/manufacturers.d.ts.map +1 -0
- package/lib/flows/lending/manufacturers.js +7 -0
- package/lib/flows/lending/manufacturers.js.map +1 -0
- package/lib/flows/lending/useAccountNameInquiry.d.ts +5 -0
- package/lib/flows/lending/useAccountNameInquiry.d.ts.map +1 -0
- package/lib/flows/lending/useAccountNameInquiry.js +35 -0
- package/lib/flows/lending/useAccountNameInquiry.js.map +1 -0
- package/lib/index.d.ts +8 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +7 -0
- package/lib/index.js.map +1 -0
- package/lib/sdk/SDKRoot.d.ts +6 -0
- package/lib/sdk/SDKRoot.d.ts.map +1 -0
- package/lib/sdk/SDKRoot.js +28 -0
- package/lib/sdk/SDKRoot.js.map +1 -0
- package/lib/sdk/bootstrap/SDKConfigProvider.d.ts +7 -0
- package/lib/sdk/bootstrap/SDKConfigProvider.d.ts.map +1 -0
- package/lib/sdk/bootstrap/SDKConfigProvider.js +132 -0
- package/lib/sdk/bootstrap/SDKConfigProvider.js.map +1 -0
- package/lib/sdk/bootstrap/bootstrapScreens.d.ts +8 -0
- package/lib/sdk/bootstrap/bootstrapScreens.d.ts.map +1 -0
- package/lib/sdk/bootstrap/bootstrapScreens.js +44 -0
- package/lib/sdk/bootstrap/bootstrapScreens.js.map +1 -0
- package/lib/sdk/configIdentity.d.ts +4 -0
- package/lib/sdk/configIdentity.d.ts.map +1 -0
- package/lib/sdk/configIdentity.js +17 -0
- package/lib/sdk/configIdentity.js.map +1 -0
- package/lib/sdk/providers/ApplicationFlowProvider.d.ts +9 -0
- package/lib/sdk/providers/ApplicationFlowProvider.d.ts.map +1 -0
- package/lib/sdk/providers/ApplicationFlowProvider.js +21 -0
- package/lib/sdk/providers/ApplicationFlowProvider.js.map +1 -0
- package/lib/sdk/providers/BrandColorProvider.d.ts +19 -0
- package/lib/sdk/providers/BrandColorProvider.d.ts.map +1 -0
- package/lib/sdk/providers/BrandColorProvider.js +24 -0
- package/lib/sdk/providers/BrandColorProvider.js.map +1 -0
- package/lib/sdk/providers/PayLimitProvider.d.ts +2 -0
- package/lib/sdk/providers/PayLimitProvider.d.ts.map +1 -0
- package/lib/sdk/providers/PayLimitProvider.js +2 -0
- package/lib/sdk/providers/PayLimitProvider.js.map +1 -0
- package/lib/sdk/providers/SDKFontProvider.d.ts +5 -0
- package/lib/sdk/providers/SDKFontProvider.d.ts.map +1 -0
- package/lib/sdk/providers/SDKFontProvider.js +23 -0
- package/lib/sdk/providers/SDKFontProvider.js.map +1 -0
- package/lib/sdk/providers/SDKProviders.d.ts +6 -0
- package/lib/sdk/providers/SDKProviders.d.ts.map +1 -0
- package/lib/sdk/providers/SDKProviders.js +10 -0
- package/lib/sdk/providers/SDKProviders.js.map +1 -0
- package/lib/sdk/providers/ToastProvider.d.ts +5 -0
- package/lib/sdk/providers/ToastProvider.d.ts.map +1 -0
- package/lib/sdk/providers/ToastProvider.js +53 -0
- package/lib/sdk/providers/ToastProvider.js.map +1 -0
- package/lib/sdk/screens/InterceptAndToastScreen.d.ts +6 -0
- package/lib/sdk/screens/InterceptAndToastScreen.d.ts.map +1 -0
- package/lib/sdk/screens/InterceptAndToastScreen.js +91 -0
- package/lib/sdk/screens/InterceptAndToastScreen.js.map +1 -0
- package/lib/sdk/screens/registry.d.ts +42 -0
- package/lib/sdk/screens/registry.d.ts.map +1 -0
- package/lib/sdk/screens/registry.js +41 -0
- package/lib/sdk/screens/registry.js.map +1 -0
- package/lib/sdk/types.d.ts +104 -0
- package/lib/sdk/types.d.ts.map +1 -0
- package/lib/sdk/types.js +48 -0
- package/lib/sdk/types.js.map +1 -0
- package/lib/services/apply/accountNameInquiry.d.ts +6 -0
- package/lib/services/apply/accountNameInquiry.d.ts.map +1 -0
- package/lib/services/apply/accountNameInquiry.js +45 -0
- package/lib/services/apply/accountNameInquiry.js.map +1 -0
- package/lib/services/apply/applicationFlow.d.ts +21 -0
- package/lib/services/apply/applicationFlow.d.ts.map +1 -0
- package/lib/services/apply/applicationFlow.js +96 -0
- package/lib/services/apply/applicationFlow.js.map +1 -0
- package/lib/services/apply/bankStatement.d.ts +55 -0
- package/lib/services/apply/bankStatement.d.ts.map +1 -0
- package/lib/services/apply/bankStatement.js +154 -0
- package/lib/services/apply/bankStatement.js.map +1 -0
- package/lib/services/apply/creditTierUpgradeStatus.d.ts +10 -0
- package/lib/services/apply/creditTierUpgradeStatus.d.ts.map +1 -0
- package/lib/services/apply/creditTierUpgradeStatus.js +74 -0
- package/lib/services/apply/creditTierUpgradeStatus.js.map +1 -0
- package/lib/services/apply/customerAgreement.d.ts +42 -0
- package/lib/services/apply/customerAgreement.d.ts.map +1 -0
- package/lib/services/apply/customerAgreement.js +190 -0
- package/lib/services/apply/customerAgreement.js.map +1 -0
- package/lib/services/apply/customerProduct.d.ts +10 -0
- package/lib/services/apply/customerProduct.d.ts.map +1 -0
- package/lib/services/apply/customerProduct.js +62 -0
- package/lib/services/apply/customerProduct.js.map +1 -0
- package/lib/services/apply/customerUpgradeDetails.d.ts +6 -0
- package/lib/services/apply/customerUpgradeDetails.d.ts.map +1 -0
- package/lib/services/apply/customerUpgradeDetails.js +35 -0
- package/lib/services/apply/customerUpgradeDetails.js.map +1 -0
- package/lib/services/apply/flatLoanAmountDue.d.ts +14 -0
- package/lib/services/apply/flatLoanAmountDue.d.ts.map +1 -0
- package/lib/services/apply/flatLoanAmountDue.js +68 -0
- package/lib/services/apply/flatLoanAmountDue.js.map +1 -0
- package/lib/services/apply/getLoans.d.ts +55 -0
- package/lib/services/apply/getLoans.d.ts.map +1 -0
- package/lib/services/apply/getLoans.js +116 -0
- package/lib/services/apply/getLoans.js.map +1 -0
- package/lib/services/apply/getPaylaterTransactions.d.ts +9 -0
- package/lib/services/apply/getPaylaterTransactions.d.ts.map +1 -0
- package/lib/services/apply/getPaylaterTransactions.js +61 -0
- package/lib/services/apply/getPaylaterTransactions.js.map +1 -0
- package/lib/services/apply/getTransactions.d.ts +18 -0
- package/lib/services/apply/getTransactions.d.ts.map +1 -0
- package/lib/services/apply/getTransactions.js +73 -0
- package/lib/services/apply/getTransactions.js.map +1 -0
- package/lib/services/apply/index.d.ts +47 -0
- package/lib/services/apply/index.d.ts.map +1 -0
- package/lib/services/apply/index.js +29 -0
- package/lib/services/apply/index.js.map +1 -0
- package/lib/services/apply/loanBrands.d.ts +15 -0
- package/lib/services/apply/loanBrands.d.ts.map +1 -0
- package/lib/services/apply/loanBrands.js +63 -0
- package/lib/services/apply/loanBrands.js.map +1 -0
- package/lib/services/apply/manufacturerStatement.d.ts +41 -0
- package/lib/services/apply/manufacturerStatement.d.ts.map +1 -0
- package/lib/services/apply/manufacturerStatement.js +207 -0
- package/lib/services/apply/manufacturerStatement.js.map +1 -0
- package/lib/services/apply/mapCatalog.d.ts +30 -0
- package/lib/services/apply/mapCatalog.d.ts.map +1 -0
- package/lib/services/apply/mapCatalog.js +153 -0
- package/lib/services/apply/mapCatalog.js.map +1 -0
- package/lib/services/apply/mapLimitHome.d.ts +66 -0
- package/lib/services/apply/mapLimitHome.d.ts.map +1 -0
- package/lib/services/apply/mapLimitHome.js +152 -0
- package/lib/services/apply/mapLimitHome.js.map +1 -0
- package/lib/services/apply/paths.d.ts +87 -0
- package/lib/services/apply/paths.d.ts.map +1 -0
- package/lib/services/apply/paths.js +99 -0
- package/lib/services/apply/paths.js.map +1 -0
- package/lib/services/apply/payLaterLimitRequest.d.ts +19 -0
- package/lib/services/apply/payLaterLimitRequest.d.ts.map +1 -0
- package/lib/services/apply/payLaterLimitRequest.js +91 -0
- package/lib/services/apply/payLaterLimitRequest.js.map +1 -0
- package/lib/services/apply/productBucket.d.ts +75 -0
- package/lib/services/apply/productBucket.d.ts.map +1 -0
- package/lib/services/apply/productBucket.js +224 -0
- package/lib/services/apply/productBucket.js.map +1 -0
- package/lib/services/apply/referralDetails.d.ts +26 -0
- package/lib/services/apply/referralDetails.d.ts.map +1 -0
- package/lib/services/apply/referralDetails.js +187 -0
- package/lib/services/apply/referralDetails.js.map +1 -0
- package/lib/services/apply/repayLoan.d.ts +9 -0
- package/lib/services/apply/repayLoan.d.ts.map +1 -0
- package/lib/services/apply/repayLoan.js +58 -0
- package/lib/services/apply/repayLoan.js.map +1 -0
- package/lib/services/apply/sdkSession.d.ts +12 -0
- package/lib/services/apply/sdkSession.d.ts.map +1 -0
- package/lib/services/apply/sdkSession.js +104 -0
- package/lib/services/apply/sdkSession.js.map +1 -0
- package/lib/services/apply/statementBanks.d.ts +4 -0
- package/lib/services/apply/statementBanks.d.ts.map +1 -0
- package/lib/services/apply/statementBanks.js +17 -0
- package/lib/services/apply/statementBanks.js.map +1 -0
- package/lib/services/apply/statementParseBanks.d.ts +8 -0
- package/lib/services/apply/statementParseBanks.d.ts.map +1 -0
- package/lib/services/apply/statementParseBanks.js +84 -0
- package/lib/services/apply/statementParseBanks.js.map +1 -0
- package/lib/services/apply/sublimitDowngrade.d.ts +5 -0
- package/lib/services/apply/sublimitDowngrade.d.ts.map +1 -0
- package/lib/services/apply/sublimitDowngrade.js +27 -0
- package/lib/services/apply/sublimitDowngrade.js.map +1 -0
- package/lib/services/apply/sublimitRequestDetails.d.ts +5 -0
- package/lib/services/apply/sublimitRequestDetails.d.ts.map +1 -0
- package/lib/services/apply/sublimitRequestDetails.js +31 -0
- package/lib/services/apply/sublimitRequestDetails.js.map +1 -0
- package/lib/services/apply/walletBanks.d.ts +3 -0
- package/lib/services/apply/walletBanks.d.ts.map +1 -0
- package/lib/services/apply/walletBanks.js +14 -0
- package/lib/services/apply/walletBanks.js.map +1 -0
- package/lib/services/customerBoot.d.ts +4 -0
- package/lib/services/customerBoot.d.ts.map +1 -0
- package/lib/services/customerBoot.js +103 -0
- package/lib/services/customerBoot.js.map +1 -0
- package/lib/services/customerRuntime.d.ts +36 -0
- package/lib/services/customerRuntime.d.ts.map +1 -0
- package/lib/services/customerRuntime.js +40 -0
- package/lib/services/customerRuntime.js.map +1 -0
- package/lib/services/deviceInfo.d.ts +7 -0
- package/lib/services/deviceInfo.d.ts.map +1 -0
- package/lib/services/deviceInfo.js +22 -0
- package/lib/services/deviceInfo.js.map +1 -0
- package/lib/services/gatewayHash.d.ts +57 -0
- package/lib/services/gatewayHash.d.ts.map +1 -0
- package/lib/services/gatewayHash.js +382 -0
- package/lib/services/gatewayHash.js.map +1 -0
- package/lib/services/http.d.ts +30 -0
- package/lib/services/http.d.ts.map +1 -0
- package/lib/services/http.js +122 -0
- package/lib/services/http.js.map +1 -0
- package/lib/services/httpRuntime.d.ts +39 -0
- package/lib/services/httpRuntime.d.ts.map +1 -0
- package/lib/services/httpRuntime.js +122 -0
- package/lib/services/httpRuntime.js.map +1 -0
- package/lib/services/md5.d.ts +3 -0
- package/lib/services/md5.d.ts.map +1 -0
- package/lib/services/md5.js +134 -0
- package/lib/services/md5.js.map +1 -0
- package/lib/services/pickDocument.d.ts +15 -0
- package/lib/services/pickDocument.d.ts.map +1 -0
- package/lib/services/pickDocument.js +11 -0
- package/lib/services/pickDocument.js.map +1 -0
- package/lib/services/serviceHelper.d.ts +2 -0
- package/lib/services/serviceHelper.d.ts.map +1 -0
- package/lib/services/serviceHelper.js +19 -0
- package/lib/services/serviceHelper.js.map +1 -0
- package/lib/theme/brandColor.d.ts +8 -0
- package/lib/theme/brandColor.d.ts.map +1 -0
- package/lib/theme/brandColor.js +30 -0
- package/lib/theme/brandColor.js.map +1 -0
- package/lib/theme/fonts.d.ts +12 -0
- package/lib/theme/fonts.d.ts.map +1 -0
- package/lib/theme/fonts.js +18 -0
- package/lib/theme/fonts.js.map +1 -0
- package/lib/utils/fontScale.d.ts +13 -0
- package/lib/utils/fontScale.d.ts.map +1 -0
- package/lib/utils/fontScale.js +17 -0
- package/lib/utils/fontScale.js.map +1 -0
- package/lib/utils/formatAmount.d.ts +28 -0
- package/lib/utils/formatAmount.d.ts.map +1 -0
- package/lib/utils/formatAmount.js +88 -0
- package/lib/utils/formatAmount.js.map +1 -0
- package/lib/utils/messageCleaner.d.ts +2 -0
- package/lib/utils/messageCleaner.d.ts.map +1 -0
- package/lib/utils/messageCleaner.js +11 -0
- package/lib/utils/messageCleaner.js.map +1 -0
- package/lib/utils/responseObserver.d.ts +10 -0
- package/lib/utils/responseObserver.d.ts.map +1 -0
- package/lib/utils/responseObserver.js +50 -0
- package/lib/utils/responseObserver.js.map +1 -0
- package/lib/web/index.d.ts +8 -0
- package/lib/web/index.d.ts.map +1 -0
- package/lib/web/index.js +7 -0
- package/lib/web/index.js.map +1 -0
- package/package.json +49 -4
- package/react-native.config.js +3 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"walletBanks.d.ts","sourceRoot":"","sources":["../../../src/services/apply/walletBanks.ts"],"names":[],"mappings":"AAEA,OAAO,EAAgB,KAAK,QAAQ,EAAE,MAAM,cAAc,CAAC;AAI3D,wBAAsB,cAAc,IAAI,OAAO,CAAC,QAAQ,EAAE,CAAC,CAO1D"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { GET } from "../http";
|
|
2
|
+
import { getWalletBankHeaders } from "../gatewayHash";
|
|
3
|
+
import { mapBankItems } from "./mapCatalog";
|
|
4
|
+
import { applyCustomerId } from "./payLaterLimitRequest";
|
|
5
|
+
import { WALLET_BANKS_PATH } from "./paths";
|
|
6
|
+
export async function getWalletBanks() {
|
|
7
|
+
const body = await GET({
|
|
8
|
+
requestUrl: WALLET_BANKS_PATH,
|
|
9
|
+
exactHeaders: true,
|
|
10
|
+
customHeaders: getWalletBankHeaders(applyCustomerId())
|
|
11
|
+
});
|
|
12
|
+
return mapBankItems(body);
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=walletBanks.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"walletBanks.js","sourceRoot":"","sources":["../../../src/services/apply/walletBanks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,SAAS,CAAC;AAC9B,OAAO,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AACtD,OAAO,EAAE,YAAY,EAAiB,MAAM,cAAc,CAAC;AAC3D,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAE5C,MAAM,CAAC,KAAK,UAAU,cAAc;IAClC,MAAM,IAAI,GAAG,MAAM,GAAG,CAAU;QAC9B,UAAU,EAAE,iBAAiB;QAC7B,YAAY,EAAE,IAAI;QAClB,aAAa,EAAE,oBAAoB,CAAC,eAAe,EAAE,CAAC;KACvD,CAAC,CAAC;IACH,OAAO,YAAY,CAAC,IAAI,CAAC,CAAC;AAC5B,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type CustomerGlobals } from "./customerRuntime";
|
|
2
|
+
export declare function getCustomerDetails(customerPhone: string, epoch?: number): Promise<CustomerGlobals>;
|
|
3
|
+
export declare function bootCustomerGlobals(epoch?: number): Promise<CustomerGlobals>;
|
|
4
|
+
//# sourceMappingURL=customerBoot.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerBoot.d.ts","sourceRoot":"","sources":["../../src/services/customerBoot.ts"],"names":[],"mappings":"AACA,OAAO,EACL,KAAK,eAAe,EAOrB,MAAM,mBAAmB,CAAC;AAoC3B,wBAAsB,kBAAkB,CAAC,aAAa,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC,CAuDxG;AAED,wBAAsB,mBAAmB,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC,CAiClF"}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { GET } from "./http";
|
|
2
|
+
import { getCustomerBootState, getCustomerPhone, setCustomerBooting, setCustomerFailed, setCustomerReady, setCustomerUpgradeDetails } from "./customerRuntime";
|
|
3
|
+
import { getCustomerRef, getUserRef, isBootEpoch, setServiceToken } from "./httpRuntime";
|
|
4
|
+
import { fetchCustomerUpgradeDetails } from "./apply/customerUpgradeDetails";
|
|
5
|
+
const CUSTOMER_DETAILS_PATH = "/sdk/getCustomerDetails";
|
|
6
|
+
class BootCancelledError extends Error {
|
|
7
|
+
constructor() {
|
|
8
|
+
super("SDK boot cancelled");
|
|
9
|
+
this.name = "BootCancelledError";
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
export async function getCustomerDetails(customerPhone, epoch) {
|
|
13
|
+
const qs = new URLSearchParams({
|
|
14
|
+
customerPhone,
|
|
15
|
+
userRef: getUserRef(),
|
|
16
|
+
customerRef: getCustomerRef()
|
|
17
|
+
}).toString();
|
|
18
|
+
const body = await GET({
|
|
19
|
+
requestUrl: `${CUSTOMER_DETAILS_PATH}?${qs}`
|
|
20
|
+
});
|
|
21
|
+
if (epoch != null && !isBootEpoch(epoch))
|
|
22
|
+
throw new BootCancelledError();
|
|
23
|
+
if (body?.error) {
|
|
24
|
+
throw new Error(body.message || "Failed to retrieve customer details.");
|
|
25
|
+
}
|
|
26
|
+
const data = body?.data;
|
|
27
|
+
const token = typeof data?.token === "string" && data.token ? data.token : null;
|
|
28
|
+
if (token)
|
|
29
|
+
setServiceToken(token);
|
|
30
|
+
const walletId = typeof data?.walletId === "string" ? data.walletId : "";
|
|
31
|
+
const customerRef = typeof data?.customerRef === "string" ? data.customerRef : "";
|
|
32
|
+
const customerName = typeof data?.customerName === "string" ? data.customerName : "";
|
|
33
|
+
const companyRef = typeof data?.companyRef === "string" && data.companyRef ? data.companyRef : undefined;
|
|
34
|
+
const rawCountryId = data?.countryDetails?.countryId;
|
|
35
|
+
const countryId = typeof rawCountryId === "number" && Number.isFinite(rawCountryId)
|
|
36
|
+
? rawCountryId
|
|
37
|
+
: typeof rawCountryId === "string" && rawCountryId.trim() && Number.isFinite(Number(rawCountryId))
|
|
38
|
+
? Number(rawCountryId)
|
|
39
|
+
: 0;
|
|
40
|
+
const rawCountryName = data?.countryDetails?.countryName ?? data?.countryDetails?.name;
|
|
41
|
+
const countryName = typeof rawCountryName === "string" ? rawCountryName.trim() : "";
|
|
42
|
+
const currency = typeof data?.countryDetails?.currency === "string" ? data.countryDetails.currency.trim() : "";
|
|
43
|
+
const currencySymbol = typeof data?.countryDetails?.currencySymbol === "string" ? data.countryDetails.currencySymbol.trim() : "";
|
|
44
|
+
const fieldOfficerId = typeof data?.fieldOfficerId === "string" ? data.fieldOfficerId.trim() : "";
|
|
45
|
+
const referralCode = typeof data?.referralCode === "string" ? data.referralCode.trim() : "";
|
|
46
|
+
const hasPayLimitReferral = Boolean(fieldOfficerId && referralCode);
|
|
47
|
+
if (!walletId || !customerRef || !customerName) {
|
|
48
|
+
throw new Error("Invalid customer details response — expected walletId, customerRef, and customerName.");
|
|
49
|
+
}
|
|
50
|
+
if (!countryId) {
|
|
51
|
+
throw new Error("Invalid customer details response — expected data.countryDetails.countryId.");
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
walletId,
|
|
55
|
+
customerRef,
|
|
56
|
+
customerName,
|
|
57
|
+
companyRef,
|
|
58
|
+
countryId,
|
|
59
|
+
countryName,
|
|
60
|
+
currency,
|
|
61
|
+
currencySymbol,
|
|
62
|
+
hasPayLimitReferral
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
export async function bootCustomerGlobals(epoch) {
|
|
66
|
+
const current = getCustomerBootState();
|
|
67
|
+
if (current.status === "ready")
|
|
68
|
+
return current.globals;
|
|
69
|
+
if (current.status === "booting")
|
|
70
|
+
return current.promise;
|
|
71
|
+
const phone = getCustomerPhone();
|
|
72
|
+
if (!phone) {
|
|
73
|
+
const err = new Error("Missing customerPhone in SDK config.");
|
|
74
|
+
setCustomerFailed(err);
|
|
75
|
+
throw err;
|
|
76
|
+
}
|
|
77
|
+
const promise = getCustomerDetails(phone, epoch)
|
|
78
|
+
.then(async (globals) => {
|
|
79
|
+
if (epoch != null && !isBootEpoch(epoch))
|
|
80
|
+
throw new BootCancelledError();
|
|
81
|
+
setCustomerReady(globals);
|
|
82
|
+
try {
|
|
83
|
+
const upgradeDetails = await fetchCustomerUpgradeDetails(globals.customerRef);
|
|
84
|
+
if (epoch == null || isBootEpoch(epoch))
|
|
85
|
+
setCustomerUpgradeDetails(upgradeDetails);
|
|
86
|
+
}
|
|
87
|
+
catch {
|
|
88
|
+
/* Upgrade details are optional for boot. */
|
|
89
|
+
}
|
|
90
|
+
return globals;
|
|
91
|
+
})
|
|
92
|
+
.catch((e) => {
|
|
93
|
+
if (e instanceof BootCancelledError)
|
|
94
|
+
throw e;
|
|
95
|
+
const err = e instanceof Error ? e : new Error(String(e));
|
|
96
|
+
if (epoch == null || isBootEpoch(epoch))
|
|
97
|
+
setCustomerFailed(err);
|
|
98
|
+
throw err;
|
|
99
|
+
});
|
|
100
|
+
setCustomerBooting(promise);
|
|
101
|
+
return promise;
|
|
102
|
+
}
|
|
103
|
+
//# sourceMappingURL=customerBoot.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerBoot.js","sourceRoot":"","sources":["../../src/services/customerBoot.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,QAAQ,CAAC;AAC7B,OAAO,EAEL,oBAAoB,EACpB,gBAAgB,EAChB,kBAAkB,EAClB,iBAAiB,EACjB,gBAAgB,EAChB,yBAAyB,EAC1B,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,WAAW,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACzF,OAAO,EAAE,2BAA2B,EAAE,MAAM,gCAAgC,CAAC;AAE7E,MAAM,qBAAqB,GAAG,yBAAyB,CAAC;AAyBxD,MAAM,kBAAmB,SAAQ,KAAK;IACp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,OAAO,EAAE,EAAE;QACtB,IAAI,KAAK,IAAI,IAAI,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC;YAAE,MAAM,IAAI,kBAAkB,EAAE,CAAC;QACzE,gBAAgB,CAAC,OAAO,CAAC,CAAC;QAC1B,IAAI,CAAC;YACH,MAAM,cAAc,GAAG,MAAM,2BAA2B,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC;YAC9E,IAAI,KAAK,IAAI,IAAI,IAAI,WAAW,CAAC,KAAK,CAAC;gBAAE,yBAAyB,CAAC,cAAc,CAAC,CAAC;QACrF,CAAC;QAAC,MAAM,CAAC;YACP,4CAA4C;QAC9C,CAAC;QACD,OAAO,OAAO,CAAC;IACjB,CAAC,CAAC;SACD,KAAK,CAAC,CAAC,CAAC,EAAE,EAAE;QACX,IAAI,CAAC,YAAY,kBAAkB;YAAE,MAAM,CAAC,CAAC;QAC7C,MAAM,GAAG,GAAG,CAAC,YAAY,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;QAC1D,IAAI,KAAK,IAAI,IAAI,IAAI,WAAW,CAAC,KAAK,CAAC;YAAE,iBAAiB,CAAC,GAAG,CAAC,CAAC;QAChE,MAAM,GAAG,CAAC;IACZ,CAAC,CAAC,CAAC;IAEL,kBAAkB,CAAC,OAAO,CAAC,CAAC;IAC5B,OAAO,OAAO,CAAC;AACjB,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
type CustomerGlobals = {
|
|
2
|
+
walletId: string;
|
|
3
|
+
customerRef: string;
|
|
4
|
+
customerName: string;
|
|
5
|
+
companyRef?: string;
|
|
6
|
+
countryId: number;
|
|
7
|
+
countryName: string;
|
|
8
|
+
currency: string;
|
|
9
|
+
currencySymbol: string;
|
|
10
|
+
hasPayLimitReferral: boolean;
|
|
11
|
+
};
|
|
12
|
+
type CustomerBootState = {
|
|
13
|
+
status: "idle";
|
|
14
|
+
} | {
|
|
15
|
+
status: "booting";
|
|
16
|
+
promise: Promise<CustomerGlobals>;
|
|
17
|
+
} | {
|
|
18
|
+
status: "ready";
|
|
19
|
+
globals: CustomerGlobals;
|
|
20
|
+
} | {
|
|
21
|
+
status: "failed";
|
|
22
|
+
error: Error;
|
|
23
|
+
};
|
|
24
|
+
export declare function setCustomerPhone(phone: string | null | undefined): void;
|
|
25
|
+
export declare function getCustomerPhone(): string | null;
|
|
26
|
+
export declare function getCustomerBootState(): CustomerBootState;
|
|
27
|
+
export declare function getCustomerGlobals(): CustomerGlobals | undefined;
|
|
28
|
+
export declare function isGhanaCustomer(): boolean;
|
|
29
|
+
export declare function setCustomerBooting(promise: Promise<CustomerGlobals>): void;
|
|
30
|
+
export declare function setCustomerReady(globals: CustomerGlobals): void;
|
|
31
|
+
export declare function setCustomerFailed(error: Error): void;
|
|
32
|
+
export declare function setCustomerUpgradeDetails(data: unknown): void;
|
|
33
|
+
export declare function getCustomerUpgradeDetails(): unknown;
|
|
34
|
+
export declare function clearCustomerRuntime(): void;
|
|
35
|
+
export type { CustomerGlobals };
|
|
36
|
+
//# sourceMappingURL=customerRuntime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerRuntime.d.ts","sourceRoot":"","sources":["../../src/services/customerRuntime.ts"],"names":[],"mappings":"AAAA,KAAK,eAAe,GAAG;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,MAAM,CAAC;IACvB,mBAAmB,EAAE,OAAO,CAAC;CAC9B,CAAC;AAEF,KAAK,iBAAiB,GAClB;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE,GAClB;IAAE,MAAM,EAAE,SAAS,CAAC;IAAC,OAAO,EAAE,OAAO,CAAC,eAAe,CAAC,CAAA;CAAE,GACxD;IAAE,MAAM,EAAE,OAAO,CAAC;IAAC,OAAO,EAAE,eAAe,CAAA;CAAE,GAC7C;IAAE,MAAM,EAAE,QAAQ,CAAC;IAAC,KAAK,EAAE,KAAK,CAAA;CAAE,CAAC;AAMvC,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,QAEhE;AAED,wBAAgB,gBAAgB,kBAE/B;AAED,wBAAgB,oBAAoB,sBAEnC;AAED,wBAAgB,kBAAkB,IAAI,eAAe,GAAG,SAAS,CAEhE;AAED,wBAAgB,eAAe,IAAI,OAAO,CAGzC;AAED,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,OAAO,CAAC,eAAe,CAAC,QAEnE;AAED,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,eAAe,QAExD;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,KAAK,QAE7C;AAED,wBAAgB,yBAAyB,CAAC,IAAI,EAAE,OAAO,QAEtD;AAED,wBAAgB,yBAAyB,YAExC;AAED,wBAAgB,oBAAoB,SAInC;AAED,YAAY,EAAE,eAAe,EAAE,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
let customerPhone = null;
|
|
2
|
+
let state = { status: "idle" };
|
|
3
|
+
let customerUpgradeDetails = undefined;
|
|
4
|
+
export function setCustomerPhone(phone) {
|
|
5
|
+
customerPhone = phone ?? null;
|
|
6
|
+
}
|
|
7
|
+
export function getCustomerPhone() {
|
|
8
|
+
return customerPhone;
|
|
9
|
+
}
|
|
10
|
+
export function getCustomerBootState() {
|
|
11
|
+
return state;
|
|
12
|
+
}
|
|
13
|
+
export function getCustomerGlobals() {
|
|
14
|
+
return state.status === "ready" ? state.globals : undefined;
|
|
15
|
+
}
|
|
16
|
+
export function isGhanaCustomer() {
|
|
17
|
+
const globals = getCustomerGlobals();
|
|
18
|
+
return Boolean(globals?.countryName && /ghana/i.test(globals.countryName));
|
|
19
|
+
}
|
|
20
|
+
export function setCustomerBooting(promise) {
|
|
21
|
+
state = { status: "booting", promise };
|
|
22
|
+
}
|
|
23
|
+
export function setCustomerReady(globals) {
|
|
24
|
+
state = { status: "ready", globals };
|
|
25
|
+
}
|
|
26
|
+
export function setCustomerFailed(error) {
|
|
27
|
+
state = { status: "failed", error };
|
|
28
|
+
}
|
|
29
|
+
export function setCustomerUpgradeDetails(data) {
|
|
30
|
+
customerUpgradeDetails = data;
|
|
31
|
+
}
|
|
32
|
+
export function getCustomerUpgradeDetails() {
|
|
33
|
+
return customerUpgradeDetails;
|
|
34
|
+
}
|
|
35
|
+
export function clearCustomerRuntime() {
|
|
36
|
+
customerPhone = null;
|
|
37
|
+
customerUpgradeDetails = undefined;
|
|
38
|
+
state = { status: "idle" };
|
|
39
|
+
}
|
|
40
|
+
//# sourceMappingURL=customerRuntime.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"customerRuntime.js","sourceRoot":"","sources":["../../src/services/customerRuntime.ts"],"names":[],"mappings":"AAkBA,IAAI,aAAa,GAAkB,IAAI,CAAC;AACxC,IAAI,KAAK,GAAsB,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;AAClD,IAAI,sBAAsB,GAAY,SAAS,CAAC;AAEhD,MAAM,UAAU,gBAAgB,CAAC,KAAgC;IAC/D,aAAa,GAAG,KAAK,IAAI,IAAI,CAAC;AAChC,CAAC;AAED,MAAM,UAAU,gBAAgB;IAC9B,OAAO,aAAa,CAAC;AACvB,CAAC;AAED,MAAM,UAAU,oBAAoB;IAClC,OAAO,KAAK,CAAC;AACf,CAAC;AAED,MAAM,UAAU,kBAAkB;IAChC,OAAO,KAAK,CAAC,MAAM,KAAK,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,CAAC;AAC9D,CAAC;AAED,MAAM,UAAU,eAAe;IAC7B,MAAM,OAAO,GAAG,kBAAkB,EAAE,CAAC;IACrC,OAAO,OAAO,CAAC,OAAO,EAAE,WAAW,IAAI,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC;AAC7E,CAAC;AAED,MAAM,UAAU,kBAAkB,CAAC,OAAiC;IAClE,KAAK,GAAG,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC;AACzC,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,OAAwB;IACvD,KAAK,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC;AACvC,CAAC;AAED,MAAM,UAAU,iBAAiB,CAAC,KAAY;IAC5C,KAAK,GAAG,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;AACtC,CAAC;AAED,MAAM,UAAU,yBAAyB,CAAC,IAAa;IACrD,sBAAsB,GAAG,IAAI,CAAC;AAChC,CAAC;AAED,MAAM,UAAU,yBAAyB;IACvC,OAAO,sBAAsB,CAAC;AAChC,CAAC;AAED,MAAM,UAAU,oBAAoB;IAClC,aAAa,GAAG,IAAI,CAAC;IACrB,sBAAsB,GAAG,SAAS,CAAC;IACnC,KAAK,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;AAC7B,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export type RepayDevice = {
|
|
2
|
+
deviceId: string;
|
|
3
|
+
deviceName: string;
|
|
4
|
+
};
|
|
5
|
+
/** Host `config.deviceId` / `config.deviceName` first; else a session fallback. No Expo requires. */
|
|
6
|
+
export declare function repayDevice(): Promise<RepayDevice>;
|
|
7
|
+
//# sourceMappingURL=deviceInfo.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deviceInfo.d.ts","sourceRoot":"","sources":["../../src/services/deviceInfo.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAYF,qGAAqG;AACrG,wBAAsB,WAAW,IAAI,OAAO,CAAC,WAAW,CAAC,CAOxD"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Platform } from "react-native";
|
|
2
|
+
import { uuidV4 } from "./gatewayHash";
|
|
3
|
+
import { getHostDevice } from "./httpRuntime";
|
|
4
|
+
let sessionDeviceId = "";
|
|
5
|
+
function fallbackDevice() {
|
|
6
|
+
if (!sessionDeviceId)
|
|
7
|
+
sessionDeviceId = `${Platform.OS}-${uuidV4()}`;
|
|
8
|
+
return {
|
|
9
|
+
deviceId: sessionDeviceId,
|
|
10
|
+
deviceName: `${Platform.OS} ${String(Platform.Version)}`
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
/** Host `config.deviceId` / `config.deviceName` first; else a session fallback. No Expo requires. */
|
|
14
|
+
export async function repayDevice() {
|
|
15
|
+
const host = getHostDevice();
|
|
16
|
+
const fallback = fallbackDevice();
|
|
17
|
+
return {
|
|
18
|
+
deviceId: host.deviceId || fallback.deviceId,
|
|
19
|
+
deviceName: host.deviceName || fallback.deviceName
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
//# sourceMappingURL=deviceInfo.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deviceInfo.js","sourceRoot":"","sources":["../../src/services/deviceInfo.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAO9C,IAAI,eAAe,GAAG,EAAE,CAAC;AAEzB,SAAS,cAAc;IACrB,IAAI,CAAC,eAAe;QAAE,eAAe,GAAG,GAAG,QAAQ,CAAC,EAAE,IAAI,MAAM,EAAE,EAAE,CAAC;IACrE,OAAO;QACL,QAAQ,EAAE,eAAe;QACzB,UAAU,EAAE,GAAG,QAAQ,CAAC,EAAE,IAAI,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE;KACzD,CAAC;AACJ,CAAC;AAED,qGAAqG;AACrG,MAAM,CAAC,KAAK,UAAU,WAAW;IAC/B,MAAM,IAAI,GAAG,aAAa,EAAE,CAAC;IAC7B,MAAM,QAAQ,GAAG,cAAc,EAAE,CAAC;IAClC,OAAO;QACL,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,QAAQ,CAAC,QAAQ;QAC5C,UAAU,EAAE,IAAI,CAAC,UAAU,IAAI,QAAQ,CAAC,UAAU;KACnD,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Same contract as the host `getHash(headers)` helper (no axios).
|
|
3
|
+
* Defaults: `publicKey` / `customerPhone` from SDK runtime when missing on this request.
|
|
4
|
+
* Per request: `redirectUrl` from the headers passed in (`redirectUrl` or `redirecturl`).
|
|
5
|
+
* MD5(`${customerPhone}pn${redirectUrl}rul${publicKey}pbey`).
|
|
6
|
+
*/
|
|
7
|
+
export declare function getHash(headers?: Record<string, string | undefined>): string;
|
|
8
|
+
/** Headers for hashed gateway calls. `hash` is derived from this same header set. */
|
|
9
|
+
export declare function getHashedGatewayHeaders(customerId: string): Record<string, string>;
|
|
10
|
+
/** Admin/Brands spec: publicKey, hash, customerPhone, customerId. */
|
|
11
|
+
export declare function getLoanBrandHeaders(customerId: string): Record<string, string>;
|
|
12
|
+
export declare function uuidV4(): string;
|
|
13
|
+
/** Confirmed repay idempotency: `${uuidv4()}-${Date.valueOf()}-${customerPhone}`. */
|
|
14
|
+
export declare function repayIdempotencyKey(customerPhone: string): string;
|
|
15
|
+
/** repayLoan curl: hash + loans redirect, customerid + customeridentifier, no Bearer. */
|
|
16
|
+
export declare function getRepayLoanHeaders(customerId: string, idempotencyKey: string): Record<string, string>;
|
|
17
|
+
/** getLoans curl: hash + wallet redirect with customerref/userref query, no Bearer. */
|
|
18
|
+
export declare function getLoansHeaders(customerId: string): Record<string, string>;
|
|
19
|
+
/** getTransactions curl: hash + wallet redirect with lowercase gettransactions query, no Bearer. */
|
|
20
|
+
export declare function getTransactionsHeaders(customerId: string): Record<string, string>;
|
|
21
|
+
/** getBanks curl: hash + wallet redirect, customeridentifier, no customerid, no Bearer. */
|
|
22
|
+
export declare function getWalletBankHeaders(customerId: string): Record<string, string>;
|
|
23
|
+
/** Account-name-inquiry curl: Bearer + customerid/identifier/phone/publickey/redirectservice/redirecturl. No hash. */
|
|
24
|
+
export declare function getAccountInquiryHeaders(customerId: string): Record<string, string>;
|
|
25
|
+
/** configurational-products curl: hash + bills redirect + customerid, no Bearer. */
|
|
26
|
+
export declare function getCustomerProductHeaders(): Record<string, string>;
|
|
27
|
+
/** customer-products/update curl: `customerref`, bills hash, empty `redirecturl`. No Bearer. */
|
|
28
|
+
export declare function getCustomerProductUpdateHeaders(customerId: string): Record<string, string>;
|
|
29
|
+
/** get-product-bucket curl: bills hash, no Bearer. */
|
|
30
|
+
export declare function getProductBucketHeaders(): Record<string, string>;
|
|
31
|
+
/** Product/customer-brands curl: `publicKey`, `hash`, `customerPhone`. No Bearer. */
|
|
32
|
+
export declare function getProductCustomerBrandsHeaders(): Record<string, string>;
|
|
33
|
+
/** get-customer-brands curl: Bearer + `x-redirect-service: bills`. No hash. */
|
|
34
|
+
export declare function getCustomerBrandsHeaders(): Record<string, string>;
|
|
35
|
+
/** getCustomerUpgradeDetails curl: Bearer + `x-redirect-service: bills`. No hash. */
|
|
36
|
+
export declare function getCustomerUpgradeDetailsHeaders(): Record<string, string>;
|
|
37
|
+
/** getSublimitRequestDetails curl: Bearer + customerid + x-redirect-service: loans. No hash. */
|
|
38
|
+
export declare function getSublimitRequestDetailsHeaders(customerId: string): Record<string, string>;
|
|
39
|
+
/** POST Bnpl/paylaterLimitRequest: Bearer + customerref + x-redirect-service: loans. No hash. */
|
|
40
|
+
export declare function getPaylaterLimitRequestHeaders(customerRef: string): Record<string, string>;
|
|
41
|
+
/** getLoansList curl for Repay Credit: Bearer + `x-redirect-service: loans`. No hash. Query `isPaid`. */
|
|
42
|
+
export declare function getRepayLoansListHeaders(): Record<string, string>;
|
|
43
|
+
/** getPaylaterTransactionsList curl: `accept: text/plain` + `Authorization: bearer`. No hash. */
|
|
44
|
+
export declare function getBnplLoansListHeaders(): Record<string, string>;
|
|
45
|
+
/** getRequestDetails / sendCustomerAgreement curls: loans hash, empty redirecturl, no Bearer. */
|
|
46
|
+
export declare function getKycLoansHeaders(customerId: string, withCustomerRef: boolean): Record<string, string>;
|
|
47
|
+
/** getAgreementDetails curl: boot Bearer + `x-redirect-service: loans`. No hash. */
|
|
48
|
+
export declare function getKycAgreementDetailsHeaders(): Record<string, string>;
|
|
49
|
+
/** Brand referral GET/PUT: publicKey, hash, customerPhone, customerRef. No Bearer. */
|
|
50
|
+
export declare function getBrandReferralHeaders(customerRef: string, withContentType: boolean): Record<string, string>;
|
|
51
|
+
/** @deprecated Use getBrandReferralHeaders. */
|
|
52
|
+
export declare function getUpdateReferralDetailsHeaders(): Record<string, string>;
|
|
53
|
+
/** authenticateSdkSession curl: Bearer, customerref, sessionid, loans redirect. No hash. */
|
|
54
|
+
export declare function getAuthenticateSdkSessionHeaders(sessionId: string): Record<string, string>;
|
|
55
|
+
/** checkCreditTierUpgradeStatus curl: wallet hash, empty redirecturl, customerid + customeridentifier, no Bearer. */
|
|
56
|
+
export declare function getCheckCreditTierUpgradeStatusHeaders(customerId: string): Record<string, string>;
|
|
57
|
+
//# sourceMappingURL=gatewayHash.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gatewayHash.d.ts","sourceRoot":"","sources":["../../src/services/gatewayHash.ts"],"names":[],"mappings":"AAiCA;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,OAAO,GAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAM,GAA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