diff --git a/README.md b/README.md index d36180a..bbadc5b 100644 --- a/README.md +++ b/README.md @@ -4,8 +4,8 @@ Mobile Payments SDK for React Native supports the following SDK versions: - * [iOS](https://developer.squareup.com/docs/mobile-payments-sdk/ios#1-install-the-sdk-and-dependencies): 2.0.2 and above - * [Android](https://developer.squareup.com/docs/mobile-payments-sdk/android#1-install-the-sdk-and-dependencies): 2.0.2 and above + * [iOS](https://developer.squareup.com/docs/mobile-payments-sdk/ios#1-install-the-sdk-and-dependencies): 2.2.3 and above + * [Android](https://developer.squareup.com/docs/mobile-payments-sdk/android#1-install-the-sdk-and-dependencies): 2.3.0 and above ## Review requirements Before getting started, please review the Requirements and Limitations and Device Compatibility sections to ensure that the SDK can be used in your project: diff --git a/example/ios/MobilePaymentsSdkReactNativeExample.xcodeproj/project.pbxproj b/example/ios/MobilePaymentsSdkReactNativeExample.xcodeproj/project.pbxproj index 032e0d1..b346bb7 100644 --- a/example/ios/MobilePaymentsSdkReactNativeExample.xcodeproj/project.pbxproj +++ b/example/ios/MobilePaymentsSdkReactNativeExample.xcodeproj/project.pbxproj @@ -12,14 +12,13 @@ 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 284D5646CA70F0F108B69F7F /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = 2D836B28FA8B57D7645367CD /* PrivacyInfo.xcprivacy */; }; - 28E754D50BE8A4007B5AF3C3 /* libPods-MobilePaymentsSdkReactNativeExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5DCACB8F33CDC322A6C60F78 /* libPods-MobilePaymentsSdkReactNativeExample.a */; }; + 51020FEC579777DE4F21EAC5 /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = D30A649CCF0A90BF84256D98 /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a */; }; 54EC517F2D35EEB00057F107 /* Config.m in Sources */ = {isa = PBXBuildFile; fileRef = 54EC517E2D35EEB00057F107 /* Config.m */; }; + 76609350658068AD83AAC1BE /* libPods-MobilePaymentsSdkReactNativeExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = C2E96D599ED83A7F7AC20C63 /* libPods-MobilePaymentsSdkReactNativeExample.a */; }; 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */; }; A1682D0D2CBE8D470011933F /* libmobile-payments-sdk-react-native.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A1682D0C2CBE8D470011933F /* libmobile-payments-sdk-react-native.a */; }; A1682D162CBE90620011933F /* SquareMobilePaymentsSDK.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = A1682D152CBE90620011933F /* SquareMobilePaymentsSDK.xcframework */; }; A1682D172CBE90620011933F /* SquareMobilePaymentsSDK.xcframework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = A1682D152CBE90620011933F /* SquareMobilePaymentsSDK.xcframework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; - EAB847EDC876649DB783D7CC /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A1682D132CBE90530011933F /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a */; }; - EE29F7BA8B341EE5191ABF15 /* libPods-MobilePaymentsSdkReactNativeExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = A1682D112CBE904B0011933F /* libPods-MobilePaymentsSdkReactNativeExample.a */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ @@ -57,22 +56,20 @@ 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = MobilePaymentsSdkReactNativeExample/Info.plist; sourceTree = ""; }; 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = MobilePaymentsSdkReactNativeExample/main.m; sourceTree = ""; }; 13B07FB81A68108700A75B9A /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = PrivacyInfo.xcprivacy; path = MobilePaymentsSdkReactNativeExample/PrivacyInfo.xcprivacy; sourceTree = ""; }; - 19F6CBCC0A4E27FBF8BF4A61 /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + 1DA8265643A6ECAEB8883020 /* Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig"; path = "Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig"; sourceTree = ""; }; 2D836B28FA8B57D7645367CD /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xml; name = PrivacyInfo.xcprivacy; path = MobilePaymentsSdkReactNativeExample/PrivacyInfo.xcprivacy; sourceTree = ""; }; - 3B4392A12AC88292D35C810B /* Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig"; path = "Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig"; sourceTree = ""; }; 54EC517D2D35EEB00057F107 /* Config.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = Config.h; path = MobilePaymentsSdkReactNativeExample/Config.h; sourceTree = ""; }; 54EC517E2D35EEB00057F107 /* Config.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; name = Config.m; path = MobilePaymentsSdkReactNativeExample/Config.m; sourceTree = ""; }; - 5709B34CF0A7D63546082F79 /* Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig"; path = "Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig"; sourceTree = ""; }; - 5B7EB9410499542E8C5724F5 /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig"; path = "Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig"; sourceTree = ""; }; - 5DCACB8F33CDC322A6C60F78 /* libPods-MobilePaymentsSdkReactNativeExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-MobilePaymentsSdkReactNativeExample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + 5EF6B75290F83F4093F5CD5A /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig"; path = "Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig"; sourceTree = ""; }; + 65D88241E83508BA54D8AB2E /* Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig"; path = "Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig"; sourceTree = ""; }; 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = MobilePaymentsSdkReactNativeExample/LaunchScreen.storyboard; sourceTree = ""; }; - 89C6BE57DB24E9ADA2F236DE /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig"; path = "Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig"; sourceTree = ""; }; A1682D0C2CBE8D470011933F /* libmobile-payments-sdk-react-native.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = "libmobile-payments-sdk-react-native.a"; sourceTree = BUILT_PRODUCTS_DIR; }; A1682D0F2CBE902C0011933F /* libmobile-payments-sdk-react-native.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = "libmobile-payments-sdk-react-native.a"; sourceTree = BUILT_PRODUCTS_DIR; }; - A1682D112CBE904B0011933F /* libPods-MobilePaymentsSdkReactNativeExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = "libPods-MobilePaymentsSdkReactNativeExample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; - A1682D132CBE90530011933F /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = "libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; A1682D152CBE90620011933F /* SquareMobilePaymentsSDK.xcframework */ = {isa = PBXFileReference; expectedSignature = "AppleDeveloperProgram:EYF346PHUG:Block, Inc."; lastKnownFileType = wrapper.xcframework; name = SquareMobilePaymentsSDK.xcframework; path = Pods/SquareMobilePaymentsSDK/SquareMobilePaymentsSDK.xcframework; sourceTree = ""; }; A1682D1C2CBE9EC10011933F /* MobilePaymentsSdkReactNativeExample-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "MobilePaymentsSdkReactNativeExample-Bridging-Header.h"; sourceTree = ""; }; + C2E96D599ED83A7F7AC20C63 /* libPods-MobilePaymentsSdkReactNativeExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-MobilePaymentsSdkReactNativeExample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + CB786A6E42D2E13AC43FE0C8 /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig"; path = "Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig"; sourceTree = ""; }; + D30A649CCF0A90BF84256D98 /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; }; /* End PBXFileReference section */ @@ -82,7 +79,7 @@ buildActionMask = 2147483647; files = ( A1682D162CBE90620011933F /* SquareMobilePaymentsSDK.xcframework in Frameworks */, - EAB847EDC876649DB783D7CC /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a in Frameworks */, + 51020FEC579777DE4F21EAC5 /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -91,8 +88,7 @@ buildActionMask = 2147483647; files = ( A1682D0D2CBE8D470011933F /* libmobile-payments-sdk-react-native.a in Frameworks */, - 28E754D50BE8A4007B5AF3C3 /* libPods-MobilePaymentsSdkReactNativeExample.a in Frameworks */, - EE29F7BA8B341EE5191ABF15 /* libPods-MobilePaymentsSdkReactNativeExample.a in Frameworks */, + 76609350658068AD83AAC1BE /* libPods-MobilePaymentsSdkReactNativeExample.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -138,13 +134,11 @@ isa = PBXGroup; children = ( A1682D152CBE90620011933F /* SquareMobilePaymentsSDK.xcframework */, - A1682D132CBE90530011933F /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a */, - A1682D112CBE904B0011933F /* libPods-MobilePaymentsSdkReactNativeExample.a */, A1682D0F2CBE902C0011933F /* libmobile-payments-sdk-react-native.a */, A1682D0C2CBE8D470011933F /* libmobile-payments-sdk-react-native.a */, ED297162215061F000B7C4FE /* JavaScriptCore.framework */, - 5DCACB8F33CDC322A6C60F78 /* libPods-MobilePaymentsSdkReactNativeExample.a */, - 19F6CBCC0A4E27FBF8BF4A61 /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a */, + C2E96D599ED83A7F7AC20C63 /* libPods-MobilePaymentsSdkReactNativeExample.a */, + D30A649CCF0A90BF84256D98 /* libPods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.a */, ); name = Frameworks; sourceTree = ""; @@ -191,10 +185,10 @@ BBD78D7AC51CEA395F1C20DB /* Pods */ = { isa = PBXGroup; children = ( - 3B4392A12AC88292D35C810B /* Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig */, - 5709B34CF0A7D63546082F79 /* Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig */, - 5B7EB9410499542E8C5724F5 /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig */, - 89C6BE57DB24E9ADA2F236DE /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig */, + 1DA8265643A6ECAEB8883020 /* Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig */, + 65D88241E83508BA54D8AB2E /* Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig */, + 5EF6B75290F83F4093F5CD5A /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig */, + CB786A6E42D2E13AC43FE0C8 /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig */, ); path = Pods; sourceTree = ""; @@ -206,13 +200,13 @@ isa = PBXNativeTarget; buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "MobilePaymentsSdkReactNativeExampleTests" */; buildPhases = ( - A55EABD7B0C7F3A422A6CC61 /* [CP] Check Pods Manifest.lock */, + 295E2396B706A0A1F6E99588 /* [CP] Check Pods Manifest.lock */, 00E356EA1AD99517003FC87E /* Sources */, 00E356EB1AD99517003FC87E /* Frameworks */, 00E356EC1AD99517003FC87E /* Resources */, - C59DA0FBD6956966B86A3779 /* [CP] Embed Pods Frameworks */, - F6A41C54EA430FDDC6A6ED99 /* [CP] Copy Pods Resources */, A1682D182CBE90620011933F /* Embed Frameworks */, + C3BDED39F1942673AB42C961 /* [CP] Embed Pods Frameworks */, + 3C456DE4F4088A22D3774B6E /* [CP] Copy Pods Resources */, ); buildRules = ( ); @@ -228,14 +222,14 @@ isa = PBXNativeTarget; buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "MobilePaymentsSdkReactNativeExample" */; buildPhases = ( - C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */, + 86D3416DAA5375E13F94EC7F /* [CP] Check Pods Manifest.lock */, 13B07F871A680F5B00A75B9A /* Sources */, 13B07F8C1A680F5B00A75B9A /* Frameworks */, 13B07F8E1A680F5B00A75B9A /* Resources */, 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, - 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */, - E235C05ADACE081382539298 /* [CP] Copy Pods Resources */, A1682D1A2CBE9B6C0011933F /* ShellScript */, + F0C06FCD06EEF84EA2F24865 /* [CP] Embed Pods Frameworks */, + 6946B4FEF2A06271C5A3F199 /* [CP] Copy Pods Resources */, ); buildRules = ( ); @@ -322,63 +316,63 @@ shellPath = /bin/sh; shellScript = "set -e\n\nWITH_ENVIRONMENT=\"$REACT_NATIVE_PATH/scripts/xcode/with-environment.sh\"\nREACT_NATIVE_XCODE=\"$REACT_NATIVE_PATH/scripts/react-native-xcode.sh\"\n\n/bin/sh -c \"$WITH_ENVIRONMENT $REACT_NATIVE_XCODE\"\n"; }; - 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */ = { + 295E2396B706A0A1F6E99588 /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-frameworks-${CONFIGURATION}-input-files.xcfilelist", ); - name = "[CP] Embed Pods Frameworks"; + inputPaths = ( + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", + "${PODS_ROOT}/Manifest.lock", + ); + name = "[CP] Check Pods Manifest.lock"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-frameworks-${CONFIGURATION}-output-files.xcfilelist", + ); + outputPaths = ( + "$(DERIVED_FILE_DIR)/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-checkManifestLockResult.txt", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-frameworks.sh\"\n"; + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; showEnvVarsInLog = 0; }; - A1682D1A2CBE9B6C0011933F /* ShellScript */ = { + 3C456DE4F4088A22D3774B6E /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-resources-${CONFIGURATION}-input-files.xcfilelist", ); - inputPaths = ( - ); + name = "[CP] Copy Pods Resources"; outputFileListPaths = ( - ); - outputPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-resources-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "# Type a script or drag a script file from your workspace to insert its path.\nFRAMEWORKS=\"${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}\"\n\"${FRAMEWORKS}/SquareMobilePaymentsSDK.framework/setup\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-resources.sh\"\n"; + showEnvVarsInLog = 0; }; - A55EABD7B0C7F3A422A6CC61 /* [CP] Check Pods Manifest.lock */ = { + 6946B4FEF2A06271C5A3F199 /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( + "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-resources-${CONFIGURATION}-input-files.xcfilelist", ); - inputPaths = ( - "${PODS_PODFILE_DIR_PATH}/Podfile.lock", - "${PODS_ROOT}/Manifest.lock", - ); - name = "[CP] Check Pods Manifest.lock"; + name = "[CP] Copy Pods Resources"; outputFileListPaths = ( - ); - outputPaths = ( - "$(DERIVED_FILE_DIR)/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-checkManifestLockResult.txt", + "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-resources-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-resources.sh\"\n"; showEnvVarsInLog = 0; }; - C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */ = { + 86D3416DAA5375E13F94EC7F /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( @@ -400,55 +394,55 @@ shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; showEnvVarsInLog = 0; }; - C59DA0FBD6956966B86A3779 /* [CP] Embed Pods Frameworks */ = { + A1682D1A2CBE9B6C0011933F /* ShellScript */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", ); - name = "[CP] Embed Pods Frameworks"; + inputPaths = ( + ); outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", + ); + outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-frameworks.sh\"\n"; - showEnvVarsInLog = 0; + shellScript = "# Type a script or drag a script file from your workspace to insert its path.\nFRAMEWORKS=\"${BUILT_PRODUCTS_DIR}/${FRAMEWORKS_FOLDER_PATH}\"\n\"${FRAMEWORKS}/SquareMobilePaymentsSDK.framework/setup\"\n"; }; - E235C05ADACE081382539298 /* [CP] Copy Pods Resources */ = { + C3BDED39F1942673AB42C961 /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-resources-${CONFIGURATION}-input-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", ); - name = "[CP] Copy Pods Resources"; + name = "[CP] Embed Pods Frameworks"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-resources-${CONFIGURATION}-output-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-resources.sh\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; - F6A41C54EA430FDDC6A6ED99 /* [CP] Copy Pods Resources */ = { + F0C06FCD06EEF84EA2F24865 /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; - buildActionMask = 12; + buildActionMask = 2147483647; files = ( ); inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-resources-${CONFIGURATION}-input-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-frameworks-${CONFIGURATION}-input-files.xcfilelist", ); - name = "[CP] Copy Pods Resources"; + name = "[CP] Embed Pods Frameworks"; outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-resources-${CONFIGURATION}-output-files.xcfilelist", + "${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-frameworks-${CONFIGURATION}-output-files.xcfilelist", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests/Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests-resources.sh\"\n"; + shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-MobilePaymentsSdkReactNativeExample/Pods-MobilePaymentsSdkReactNativeExample-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; /* End PBXShellScriptBuildPhase section */ @@ -485,7 +479,7 @@ /* Begin XCBuildConfiguration section */ 00E356F61AD99517003FC87E /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 5B7EB9410499542E8C5724F5 /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig */; + baseConfigurationReference = 5EF6B75290F83F4093F5CD5A /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.debug.xcconfig */; buildSettings = { BUNDLE_LOADER = "$(TEST_HOST)"; GCC_PREPROCESSOR_DEFINITIONS = ( @@ -512,7 +506,7 @@ }; 00E356F71AD99517003FC87E /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 89C6BE57DB24E9ADA2F236DE /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig */; + baseConfigurationReference = CB786A6E42D2E13AC43FE0C8 /* Pods-MobilePaymentsSdkReactNativeExample-MobilePaymentsSdkReactNativeExampleTests.release.xcconfig */; buildSettings = { BUNDLE_LOADER = "$(TEST_HOST)"; COPY_PHASE_STRIP = NO; @@ -536,7 +530,7 @@ }; 13B07F941A680F5B00A75B9A /* Debug */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 3B4392A12AC88292D35C810B /* Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig */; + baseConfigurationReference = 1DA8265643A6ECAEB8883020 /* Pods-MobilePaymentsSdkReactNativeExample.debug.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; @@ -544,7 +538,7 @@ DEVELOPMENT_TEAM = ""; ENABLE_BITCODE = NO; INFOPLIST_FILE = MobilePaymentsSdkReactNativeExample/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 15.1; + IPHONEOS_DEPLOYMENT_TARGET = 18.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", @@ -571,14 +565,14 @@ }; 13B07F951A680F5B00A75B9A /* Release */ = { isa = XCBuildConfiguration; - baseConfigurationReference = 5709B34CF0A7D63546082F79 /* Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig */; + baseConfigurationReference = 65D88241E83508BA54D8AB2E /* Pods-MobilePaymentsSdkReactNativeExample.release.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; INFOPLIST_FILE = MobilePaymentsSdkReactNativeExample/Info.plist; - IPHONEOS_DEPLOYMENT_TARGET = 15.1; + IPHONEOS_DEPLOYMENT_TARGET = 18.0; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@executable_path/Frameworks", diff --git a/example/ios/Podfile b/example/ios/Podfile index 4c87022..0c865d7 100644 --- a/example/ios/Podfile +++ b/example/ios/Podfile @@ -5,7 +5,7 @@ require Pod::Executable.execute_command('node', ['-p', {paths: [process.argv[1]]}, )', __dir__]).strip -platform :ios, 15.1 +platform :ios, 16 prepare_react_native_project! linkage = ENV['USE_FRAMEWORKS'] diff --git a/example/ios/Podfile.lock b/example/ios/Podfile.lock index 67988be..ba535fa 100644 --- a/example/ios/Podfile.lock +++ b/example/ios/Podfile.lock @@ -7,11 +7,11 @@ PODS: - hermes-engine (0.75.3): - hermes-engine/Pre-built (= 0.75.3) - hermes-engine/Pre-built (0.75.3) - - mobile-payments-sdk-react-native (2025.2.2): + - mobile-payments-sdk-react-native (2025.6.1): - DoubleConversion - glog - hermes-engine - - MockReaderUI (~> 2.1.0) + - MockReaderUI (~> 2.2.3) - RCT-Folly (= 2024.01.01.00) - RCTRequired - RCTTypeSafety @@ -28,9 +28,9 @@ PODS: - ReactCodegen - ReactCommon/turbomodule/bridging - ReactCommon/turbomodule/core - - SquareMobilePaymentsSDK (~> 2.1.0) + - SquareMobilePaymentsSDK (~> 2.2.3) - Yoga - - MockReaderUI (2.1.0) + - MockReaderUI (2.2.3) - Permission-BluetoothPeripheral (3.10.1): - RNPermissions - Permission-LocationAccuracy (3.10.1): @@ -1581,7 +1581,7 @@ PODS: - ReactCommon/turbomodule/core - Yoga - SocketRocket (0.7.0) - - SquareMobilePaymentsSDK (2.1.0) + - SquareMobilePaymentsSDK (2.2.3) - Yoga (0.0.0) DEPENDENCIES: @@ -1823,8 +1823,8 @@ SPEC CHECKSUMS: fmt: 4c2741a687cc09f0634a2e2c72a838b99f1ff120 glog: 69ef571f3de08433d766d614c73a9838a06bf7eb hermes-engine: 8d2103d6c0176779aea4e25df6bb1410f9946680 - mobile-payments-sdk-react-native: 700d715727920468e9cb1af577b94d6b678f14e5 - MockReaderUI: 141fe6bb56f63d22e375800ee6a5c5da69ffb55a + mobile-payments-sdk-react-native: 5b23ebe5ea5fe3e91f64a7fcd596e002db06fdef + MockReaderUI: d88d35cb4926b38425c2ba9fa3ef11a4aaf39f21 Permission-BluetoothPeripheral: 34ab829f159c6cf400c57bac05f5ba1b0af7a86e Permission-LocationAccuracy: 30c5421911024b28d8916db5cbd728097da54434 Permission-LocationAlways: af165dee8a5a5888df6764f9f6ba98b112893709 @@ -1891,9 +1891,9 @@ SPEC CHECKSUMS: RNScreens: 35bb8e81aeccf111baa0ea01a54231390dbbcfd9 RNVectorIcons: 182892e7d1a2f27b52d3c627eca5d2665a22ee28 SocketRocket: abac6f5de4d4d62d24e11868d7a2f427e0ef940d - SquareMobilePaymentsSDK: b437afc89530142af80ed818f4db02e07c47457c + SquareMobilePaymentsSDK: 698333088d7200bba3e7991121ba245112390651 Yoga: 4ef80d96a5534f0e01b3055f17d1e19a9fc61b63 -PODFILE CHECKSUM: 439764333dadb7461aea4b653e55d92f832f43a0 +PODFILE CHECKSUM: 81d2f9e3393262e2bc7a99478a8e3a6741f0482e COCOAPODS: 1.16.2 diff --git a/ios/Mappers.swift b/ios/Mappers.swift index 1b4f15c..0be38eb 100644 --- a/ios/Mappers.swift +++ b/ios/Mappers.swift @@ -31,10 +31,17 @@ class Mappers { let amountMoney = Money(moneyParam) else { return .failure(.missingAmount) } + + guard let processingModeInt = paymentParameters["processingMode"] as? Int, + let processingMode = ProcessingMode(rawValue: processingModeInt) else { + return .failure(.missingProcessingMode) + } + guard let idempotencyKey = paymentParameters["idempotencyKey"] as? String else { return .failure(.missingIdempotencyKey) } - let paymentParams = PaymentParameters(idempotencyKey: idempotencyKey, amountMoney: amountMoney) + + let paymentParams = PaymentParameters(idempotencyKey: idempotencyKey, amountMoney: amountMoney, processingMode: processingMode) // Optional parameters if let partialAuth = paymentParameters["acceptPartialAuthorization"] as? Bool { @@ -176,6 +183,7 @@ extension SquareMobilePaymentsSDK.SourceType { enum PaymentParametersError: Error { case missingAmount case missingIdempotencyKey + case missingProcessingMode } enum PaymentPromptError: Error { diff --git a/ios/Podfile b/ios/Podfile index 00c46ea..b9d66e4 100644 --- a/ios/Podfile +++ b/ios/Podfile @@ -1,12 +1,13 @@ # Uncomment the next line to define a global platform for your project # platform :ios, '9.0' +platform :ios, 16 target 'RNMobilePaymentSDK' do # Comment the next line if you don't want to use dynamic frameworks use_frameworks! # Pods for RNMobilePaymentSDK - pod "SquareMobilePaymentsSDK", "~> 2.2.2" + pod "SquareMobilePaymentsSDK", "~> 2.2.3" target 'RNMobilePaymentSDKTests' do inherit! :search_paths # Pods for testing diff --git a/ios/Podfile.lock b/ios/Podfile.lock index d4f0c1e..4461d5f 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -1,16 +1,16 @@ PODS: - - SquareMobilePaymentsSDK (2.1.0) + - SquareMobilePaymentsSDK (2.2.3) DEPENDENCIES: - - SquareMobilePaymentsSDK (~> 2.1.0) + - SquareMobilePaymentsSDK (~> 2.2.3) SPEC REPOS: trunk: - SquareMobilePaymentsSDK SPEC CHECKSUMS: - SquareMobilePaymentsSDK: b437afc89530142af80ed818f4db02e07c47457c + SquareMobilePaymentsSDK: 698333088d7200bba3e7991121ba245112390651 -PODFILE CHECKSUM: 36ec71d8ea5709b9c8c2277616eae29f2769b341 +PODFILE CHECKSUM: 1d34f9a9e2d1b600f03743f8a2b0d0666a02192d COCOAPODS: 1.16.2 diff --git a/mobile-payments-sdk-react-native.podspec b/mobile-payments-sdk-react-native.podspec index 686ef04..aa32243 100644 --- a/mobile-payments-sdk-react-native.podspec +++ b/mobile-payments-sdk-react-native.podspec @@ -11,11 +11,11 @@ Pod::Spec.new do |s| s.license = package["license"] s.authors = package["author"] - s.platforms = { :ios => "15.0" } + s.platforms = { :ios => "16" } s.source = { :git => "https://github.com/square//mobile-payments-sdk-react-native.git", :tag => "#{s.version}" } - s.dependency "SquareMobilePaymentsSDK", "~> #{package["mobilePaymentsSdkVersion"]}" - s.dependency "MockReaderUI", "~> #{package["mobilePaymentsSdkVersion"]}" + s.dependency "MockReaderUI", "~> 2.2.3" + s.dependency "SquareMobilePaymentsSDK", "~> 2.2.3" s.source_files = "ios/**/*.{h,m,mm,swift}" diff --git a/package.json b/package.json index 36e5616..e90ee2c 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,7 @@ { "name": "mobile-payments-sdk-react-native", - "version": "2025.2.2", + "version": "2025.6.1", "description": "Mobile Payments SDK plug-in for React Native. Enables developers to build secure in-person payment solutions.", - "mobilePaymentsSdkVersion": "2.1.0", "source": "./src/index.tsx", "main": "./lib/commonjs/index.js", "module": "./lib/module/index.js",