zmp-sdk 2.39.9 → 2.40.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/index.d.ts CHANGED
@@ -841,6 +841,9 @@ declare const ACTION: {
841
841
  MP_SELECT_PAYMENT_METHOD: {
842
842
  skipJump: boolean;
843
843
  };
844
+ MP_CONFIRM_REQUEST_PAYMENT: {
845
+ skipJump: boolean;
846
+ };
844
847
  };
845
848
  declare const AUTHEN_SCOPE_VALUES: readonly ["scope.userInfo", "scope.userLocation", "scope.userPhonenumber"];
846
849
  declare const GET_SETTINGS_SCOPE_VALUES: readonly ["scope.userInfo", "scope.userLocation", "scope.userPhonenumber", "scope.camera", "scope.micro"];
@@ -1028,9 +1031,15 @@ type ChooseImageReturns = {
1028
1031
  };
1029
1032
  type CreateOrderReturns = {
1030
1033
  orderId: string;
1034
+ messageToken?: string;
1035
+ transId?: string;
1031
1036
  };
1032
1037
  type SelectPaymentMethodReturns = {
1033
1038
  method: string;
1039
+ isCustom?: boolean;
1040
+ displayName?: string;
1041
+ subMethod?: string;
1042
+ logo?: string;
1034
1043
  };
1035
1044
  type CheckTransactionReturns = {
1036
1045
  err: number;
@@ -2965,12 +2974,71 @@ declare const createOrderArgs: ZodObject<{
2965
2974
  }>[];
2966
2975
  declare function createOrder(args: AsyncCallback<CreateOrderReturns> & TypeOf<(typeof createOrderArgs)[0]>): Promise<CreateOrderReturns>;
2967
2976
 
2977
+ declare const purchaseArgs: ZodObject<{
2978
+ amount: ZodUnion<[ZodString, ZodNumber]>;
2979
+ desc: ZodString;
2980
+ method: ZodString;
2981
+ transId: ZodOptional<ZodString>;
2982
+ mac: ZodOptional<ZodString>;
2983
+ }, "strip", ZodTypeAny, {
2984
+ transId?: string | undefined;
2985
+ mac?: string | undefined;
2986
+ method: string;
2987
+ desc: string;
2988
+ amount: string | number;
2989
+ }, {
2990
+ transId?: string | undefined;
2991
+ mac?: string | undefined;
2992
+ method: string;
2993
+ desc: string;
2994
+ amount: string | number;
2995
+ }>[];
2996
+ declare function purchase(args: AsyncCallback<CreateOrderReturns> & TypeOf<(typeof purchaseArgs)[0]>): Promise<CreateOrderReturns>;
2997
+
2968
2998
  declare const selectPaymentMethodArgs: ZodOptional<ZodObject<{
2969
- method: ZodOptional<ZodString>;
2999
+ channels: ZodOptional<ZodArray<ZodObject<{
3000
+ method: ZodString;
3001
+ subMethod: ZodOptional<ZodString>;
3002
+ subInfo: ZodOptional<ZodString>;
3003
+ }, "strip", ZodTypeAny, {
3004
+ subMethod?: string | undefined;
3005
+ subInfo?: string | undefined;
3006
+ method: string;
3007
+ }, {
3008
+ subMethod?: string | undefined;
3009
+ subInfo?: string | undefined;
3010
+ method: string;
3011
+ }>, "many">>;
3012
+ selectedMethod: ZodOptional<ZodObject<{
3013
+ method: ZodString;
3014
+ subMethod: ZodOptional<ZodString>;
3015
+ }, "strip", ZodTypeAny, {
3016
+ subMethod?: string | undefined;
3017
+ method: string;
3018
+ }, {
3019
+ subMethod?: string | undefined;
3020
+ method: string;
3021
+ }>>;
2970
3022
  }, "strip", ZodTypeAny, {
2971
- method?: string | undefined;
3023
+ channels?: {
3024
+ subMethod?: string | undefined;
3025
+ subInfo?: string | undefined;
3026
+ method: string;
3027
+ }[] | undefined;
3028
+ selectedMethod?: {
3029
+ subMethod?: string | undefined;
3030
+ method: string;
3031
+ } | undefined;
2972
3032
  }, {
2973
- method?: string | undefined;
3033
+ channels?: {
3034
+ subMethod?: string | undefined;
3035
+ subInfo?: string | undefined;
3036
+ method: string;
3037
+ }[] | undefined;
3038
+ selectedMethod?: {
3039
+ subMethod?: string | undefined;
3040
+ method: string;
3041
+ } | undefined;
2974
3042
  }>>[];
2975
3043
  declare function selectPaymentMethod(args: AsyncCallback<SelectPaymentMethodReturns> & TypeOf<(typeof selectPaymentMethodArgs)[0]>): Promise<SelectPaymentMethodReturns>;
2976
3044
 
@@ -3472,5 +3540,9 @@ declare const payment: {
3472
3540
  createOrderIAP: typeof createOrderIAP;
3473
3541
  selectPaymentMethod: typeof selectPaymentMethod;
3474
3542
  };
3543
+ declare const checkout: {
3544
+ selectPaymentMethod: typeof selectPaymentMethod;
3545
+ purchase: typeof purchase;
3546
+ };
3475
3547
 
3476
- export { Action, AndroidBottomNavigationBarType, AsyncCallback, AsyncCallbackFailObject, AsyncVoidCallback, AuthorizeType, CameraEvents, CameraParams, ChatType, CheckStateBioAuthenticationReturns, CheckTransactionReturns, CheckZaloCameraPermissionReturns, ChooseImageReturns, Common, ContextInfo, CreateOrderIAPReturns, CreateOrderReturns, Events as EventName, Events, FacingMode, FunctionProps, GetAppInfoReturns, GetAuthCodeReturns, GetBeaconDiscoveryReturns, GetLocationReturns, GetNetworkTypeReturns, GetPhoneNumberReturns, GetSettingReturn, GetStorageReturns, GetUserInfoReturns, GetZPITokenReturns, IAPMethodType, IAPPayType, IAPPayTypeType, IOSSafeAreaBottomType, JumpStatus, KeepScreenReturns, LogData, MediaConstraints, MediaDevice, MediaPickerType, NativeCallBackData, NetworkType, OpenBioAuthenticationReturns, OpenMediaPickerReturns, OpenPostFeedReturns, OpenProfilePickerReturns, OpenShareSheetReturns, OpenWebviewReturns, OrientationType, payment as Payment, PhotoConstraint, PhotoFormat, PhotoFrame, PhotoQuality, PickAttr, PlatformType, PostFeedType, ProfileType, ProrationMode, ProrationModeType, RemoveStorageReturns, RequestCameraPermissionReturns, ScanQRCodeReturns, SelectPaymentMethodReturns, SetStorageReturns, ShareSheetType, StatusBarType, StorageInfo, StreamType, SystemInfo, TextAlignType, VibrateType, ZMACamera, ZMACameraImp, addRating, authorize, checkStateBioAuthentication, checkTransaction, checkZaloCameraPermission, chooseImage, clearStorage, closeApp, closeLoading, configAppView, connectWifi, createCameraContext, createOrder, createOrderIAP, createShortcut, otherApis as default, displayAd, events, favoriteApp, followOA, getAccessToken, getAppInfo, getAuthCode, getBeacons, getContext, getContextAsync, getDeviceId, getDeviceIdAsync, getIDToken, getLocation, getNetworkType, getPhoneNumber, getRouteParams, getSetting, getShareableLink, getStorage, getStorageInfo, getSystemInfo, getUserID, getUserInfo, getVersion, getZPIToken, hideKeyboard, iBeaconInfo, interactOA, interactOA as interactOa, checkIsAllowedInteractWithOA as isAllowedInteractWithOA, keepScreen, loadAd, login, minimizeApp, offConfirmToExit, offKeepScreen, onCallbackData, onConfirmToExit, onKeepScreen, onNetworkStatusChange, openBioAuthentication, openChat, openGroupList, openMediaPicker, openMiniApp, openOutApp, openPermissionSetting, openPhone, openPostFeed, openProfile, openProfilePicker, openSMS, openShareSheet, openWebview, refreshAd, removeStorage, requestCameraPermission, requestSendNotification, requestUpdateZalo, saveImageToGallery, scanQRCode, selectPaymentMethod, sendDataToPreviousMiniApp, setAccessToken, setAndroidBottomNavigationBar, setIOSBottomSafeArea, setNavigationBarColor, setNavigationBarLeftButton, setNavigationBarTitle, setStatusBar, setStorage, setupAd, showFunctionButtonWidget, showOAWidget, showToast, startBeaconDiscovery, stopBeaconDiscovery, unfollowOA, vibrate, viewOAQr };
3548
+ export { Action, AndroidBottomNavigationBarType, AsyncCallback, AsyncCallbackFailObject, AsyncVoidCallback, AuthorizeType, CameraEvents, CameraParams, ChatType, CheckStateBioAuthenticationReturns, CheckTransactionReturns, CheckZaloCameraPermissionReturns, checkout as CheckoutSDK, ChooseImageReturns, Common, ContextInfo, CreateOrderIAPReturns, CreateOrderReturns, Events as EventName, Events, FacingMode, FunctionProps, GetAppInfoReturns, GetAuthCodeReturns, GetBeaconDiscoveryReturns, GetLocationReturns, GetNetworkTypeReturns, GetPhoneNumberReturns, GetSettingReturn, GetStorageReturns, GetUserInfoReturns, GetZPITokenReturns, IAPMethodType, IAPPayType, IAPPayTypeType, IOSSafeAreaBottomType, JumpStatus, KeepScreenReturns, LogData, MediaConstraints, MediaDevice, MediaPickerType, NativeCallBackData, NetworkType, OpenBioAuthenticationReturns, OpenMediaPickerReturns, OpenPostFeedReturns, OpenProfilePickerReturns, OpenShareSheetReturns, OpenWebviewReturns, OrientationType, payment as Payment, PhotoConstraint, PhotoFormat, PhotoFrame, PhotoQuality, PickAttr, PlatformType, PostFeedType, ProfileType, ProrationMode, ProrationModeType, RemoveStorageReturns, RequestCameraPermissionReturns, ScanQRCodeReturns, SelectPaymentMethodReturns, SetStorageReturns, ShareSheetType, StatusBarType, StorageInfo, StreamType, SystemInfo, TextAlignType, VibrateType, ZMACamera, ZMACameraImp, addRating, authorize, checkStateBioAuthentication, checkTransaction, checkZaloCameraPermission, chooseImage, clearStorage, closeApp, closeLoading, configAppView, connectWifi, createCameraContext, createOrder, createOrderIAP, createShortcut, otherApis as default, displayAd, events, favoriteApp, followOA, getAccessToken, getAppInfo, getAuthCode, getBeacons, getContext, getContextAsync, getDeviceId, getDeviceIdAsync, getIDToken, getLocation, getNetworkType, getPhoneNumber, getRouteParams, getSetting, getShareableLink, getStorage, getStorageInfo, getSystemInfo, getUserID, getUserInfo, getVersion, getZPIToken, hideKeyboard, iBeaconInfo, interactOA, interactOA as interactOa, checkIsAllowedInteractWithOA as isAllowedInteractWithOA, keepScreen, loadAd, login, minimizeApp, offConfirmToExit, offKeepScreen, onCallbackData, onConfirmToExit, onKeepScreen, onNetworkStatusChange, openBioAuthentication, openChat, openGroupList, openMediaPicker, openMiniApp, openOutApp, openPermissionSetting, openPhone, openPostFeed, openProfile, openProfilePicker, openSMS, openShareSheet, openWebview, purchase, refreshAd, removeStorage, requestCameraPermission, requestSendNotification, requestUpdateZalo, saveImageToGallery, scanQRCode, selectPaymentMethod, sendDataToPreviousMiniApp, setAccessToken, setAndroidBottomNavigationBar, setIOSBottomSafeArea, setNavigationBarColor, setNavigationBarLeftButton, setNavigationBarTitle, setStatusBar, setStorage, setupAd, showFunctionButtonWidget, showOAWidget, showToast, startBeaconDiscovery, stopBeaconDiscovery, unfollowOA, vibrate, viewOAQr };