Overview
Scan to PayKit — the Scan to Pay iOS in-app payment SDK. What it is, what you'll need, and how the pieces fit together.
Scan to PayKit is the iOS in-app payment SDK from EFT Corporation. Distributed as an .xcframework, it embeds the full Scan to Pay checkout experience inside your view controller — your app calls one Swift method, the SDK handles the rest, and a delegate callback returns the result.
For the cross-platform context, see In-App Payments overview.
What the SDK gives you
| Component | Purpose |
|---|---|
MPScanToPay | The main entry point. Calls like checkout(...), preRegister(...), walletManagement(...). |
MPScanToPayDelegate | Protocol your view controller adopts to receive results. |
MPSystem | Enum: .live or .test — switches between sandbox and production. |
MPError | Enum of error types. |
MPPayByApp | Drop-in UIView subclass that lets the customer hand off to a supported bank app. |
MPPayByCard | Drop-in UIView subclass that triggers the in-SDK checkout. |
| Loading dialog | Pre-built progress UI you can show while creating a code server-side. |
Prerequisites
| Requirement | Why |
|---|---|
| Active merchant account | You can't accept payments without one. See Merchant Onboarding. |
| Lib Lite API token | Generated in the Portal: log in → email dropdown → Lib Lite Tokens → Generate. |
| A backend that can create codes | The SDK consumes codes; it doesn't create them. See Managing QR codes. |
| A webhook receiver or polling integration | The SDK's success callback isn't authoritative. Confirm server-side via Webhooks or Querying transactions. |
Codes must be fixed-amount. Variable-amount codes are rejected. Set the amount when you create the code.
How the SDK is wired
┌─────────────────────────────────┐
│ Your app │
│ │
│ ┌──────────────────────────┐ │
│ │ UIViewController │ │
│ │ ↓ calls .checkout(...) │ │
│ └──────────────────────────┘ │
│ ↓ │
│ ┌──────────────────────────┐ │
│ │ ScanToPayKit │ │
│ │ • MPScanToPay │ │
│ │ • MPPayByApp │ │
│ │ • MPPayByCard │ │
│ │ • Loading dialog │ │
│ └──────────────────────────┘ │
│ ↓ │
└────────────────│────────────────┘
│
↓ HTTPS
┌─────────────────────────────────┐
│ Scan to Pay platform │
│ (QA: qa.scantopay.io/pluto) │
│ (Live: scantopay.live/pluto) │
└─────────────────────────────────┘
The SDK presents its UI as a modal-style view stack on your supplied controller — no separate windows or off-process work.
A complete payment
import ScanToPayKit
let code = "6799782555"
let apiKey = "YOUR_API_KEY"
let system = MPSystem.test
let scanToPay = MPScanToPay()
scanToPay.checkout(withCode: code,
apiKey: apiKey,
system: system,
controller: self,
delegate: self)Step-by-step in Payments.
What the SDK does NOT do
| Create codes | Your backend does this via /code |
| Verify final payment status | You confirm via webhook or /transactionState |
| Reconcile | Settlement and reconciliation are merchant-side |
| Refund | Use the Refunds and reversals API server-side |
What's next
- Install the SDK → Installation
- First payment → Payments
- Use the drop-in button → Pay-by-Card button
- App-to-app handoff → Pay-by-App button
- Card management → Manage Card
Updated 2 days ago
