Migration Guide
This guide covers all the changes needed to upgrade from ReadyRemitSDK (v10) to PayMittoSDK (v11). The update involves replacing the package dependency, updating the module import, and renaming a small set of SDK symbols.
Package Dependency
Swift Package Manager
Via Package.swift — replace the existing package reference with the new URL and version:
.package(
url: "https://github.com/PayMitto/paymitto-ios.git",
.exact("11.0.0")
)Also update the target dependency:
.product(name: "PayMittoSDK", package: "paymitto-ios")Via Xcode UI — if you manage SPM packages through Xcode instead:
- Open your
.xcodeprojin Xcode. - Go to your project settings → Package Dependencies.
- Remove the
ReadyRemitSDKentry (listed asreadyremit-sdk-ios). - Add a new package:
https://github.com/PayMitto/paymitto-ios.git - Select Exact Version
11.0.0. - Link
PayMittoSDKto your target.
CocoaPods
Add the PayMitto specs source and the new pod to your Podfile:
pod 'PayMittoSDK', :git => 'https://github.com/PayMitto/paymitto-ios.git', :tag => '11.0.0'Then run:
pod installImport
Replace the import in every file that used the old SDK:
import ReadyRemitSDKimport PayMittoSDKSDK Entry Point
The singleton accessor has been renamed:
ReadyRemit.shared.startSDK(
configuration: .init(environment: .sandbox),
fetchAccessTokenDetails: fetchAccessTokenDetails,
verifyFundsAndCreateTransfer: verifyFundsAndCreateTransfer,
onDismiss: { ... }
) { sdkView in ... }PayMitto.shared.startSDK(
configuration: .init(environment: .sandbox),
fetchAccessTokenDetails: fetchAccessTokenDetails,
verifyFundsAndCreateTransfer: verifyFundsAndCreateTransfer,
onDismiss: { ... }
) { sdkView in ... }Error Type
Update throw and catch sites:
throw ReadyRemitError(code: .none, message: "Something went wrong")
} catch let error as ReadyRemitError {
throw error
}throw PayMittoError(code: .none, message: "Something went wrong")
} catch let error as PayMittoError {
throw error
}Update typed throws signatures as well:
func verifyFundsAndCreateTransfer(...) async throws(ReadyRemitError) -> TransferDetailsfunc verifyFundsAndCreateTransfer(...) async throws(PayMittoError) -> TransferDetailsRenamed Symbols
| Old | New |
|---|---|
ReadyRemitSDK (module) | PayMittoSDK |
ReadyRemit.shared | PayMitto.shared |
ReadyRemitError | PayMittoError |
ReadyRemitConfiguration | PayMittoConfiguration |
ReadyRemitEnvironment | PayMittoEnvironment |
Updated about 24 hours ago
