{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-platform/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"GlomoPay Flutter SDK v0.0.15","llmstxt":{"title":"Glomopay developer documentation","description":"Cross-border payments APIs, organised by product. Each product section carries both the explanation of its objects and the job-shaped integration guides that set them up.","details":{"content":"How to use these docs:\n\n- Get started is the front door. It carries a routing table from\n  \"what are you building\" to the page that builds it, plus how to get\n  API keys.\n- The product sections - Payin, Payout, Multi-currency accounts,\n  Verification, Request for Information (RFI) - each hold two kinds of page.\n  Pages titled as a noun (\"Subscriptions\", \"Bank Transfer\") explain what\n  an object is. Pages titled as a job (\"Set up recurring subscriptions\",\n  \"Collect LRS remittances from India\") are complete integration flows\n  and live one level under the object they set up. Match a user's goal\n  against the job-shaped titles first.\n- Reports and Identity and Access Management are the two subjects with no\n  API counterpart. There are no endpoints for reports, users, roles or\n  invites; both pages document the merchant dashboard. A dashboard\n  procedure for something the API also does (a refund, a payout) is NOT\n  here - it stays in the product that owns it.\n- API reference is generated from OpenAPI and carries endpoint detail.\n- The OpenAPI description itself is published as a single self-contained\n  document at /openapi.yaml, and the same document as JSON at\n  /openapi.json. Every $ref is resolved into it, so one fetch is the\n  whole contract: 61 paths, 81 operations, 68 schemas - the same\n  endpoints the API reference pages render. Fetch that instead of\n  reading the 129 pages under /api-reference/.\n- Developer resources covers what every integration touches and no single\n  product owns: auth, errors, pagination, rate limits, webhooks,\n  versioning, supported countries, quotes, and the client SDKs.\n"},"sections":[{"title":"Get started","description":"The front door. The routing table from a merchant's goal to the flow that delivers it, how to obtain API keys, and the platform glossary.","includeFiles":["**/get-started/**"]},{"title":"Payin","description":"Collecting money: customers, orders, checkout, payment links, payment methods (cards, bank transfer, pay via bank), refunds, disputes, purpose codes, fee models, custom fields, subscriptions, and resident India remittance under LRS. Includes the flows that set each up - bank transfers, subscriptions, LRS remittances, and server-to-server card payments.","includeFiles":["**/payin/**"]},{"title":"Payout","description":"Sending money: the payout life cycle, queued payouts, creating and cancelling a payout, rails, beneficiaries, purpose codes, and the action required state.","includeFiles":["**/payout/**"]},{"title":"Multi-currency accounts","description":"Holding money: balances, balance conversion, adding balance, withdrawing balance, and the settlement holiday calendar - the Indian and US bank and FX holidays on which settlement to the merchant's bank account, and money movement generally, is affected.","includeFiles":["**/multi-currency-account/**"]},{"title":"Verification","description":"Proving who someone is and that an account is theirs: KYC, bank account validation, and third-party verification (TPV) with the flow that verifies a payer's bank account.","includeFiles":["**/verification/**"]},{"title":"Request for Information (RFI)","description":"Responding to a compliance request for information, per object - payment link, order, payment, payout - plus compliance reviews and RFIs raised on already-successful payments.","includeFiles":["**/request-for-information/**"]},{"title":"Reports","description":"The downloadable and scheduled reports a merchant pulls from the dashboard for reconciliation, compliance and treasury: payment, subscription, settlement breakup, balance statement and KYC reports, plus scheduling one for recurring email delivery. Dashboard only - there is no reports API.","includeFiles":["**/reports/**"]},{"title":"Identity and Access Management","description":"Administering who can use a merchant account: one set of credentials across multiple MIDs, switching between them without logging out, the Admin / Member / Sales Partner roles and what each may see and do, and inviting a new member. Dashboard only - there is no users, roles or invites API.","includeFiles":["**/access-management/**"]},{"title":"API reference","description":"Endpoint reference generated from the Glomopay OpenAPI description.","includeFiles":["**/api-reference/**"]},{"title":"Developer resources","description":"What every integration touches and no single product owns: auth, errors, pagination, rate limits, webhooks, versioning, API validations, security, supported countries, quotes, and the client SDKs - React Native, Flutter, Android and the Unified Web SDK, with per-version references and changelogs. Reports and Identity and Access Management used to be listed here and are now their own sections.","includeFiles":["**/platform/**"]}]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"glomopay-flutter-sdk-v0015","__idx":0},"children":["GlomoPay Flutter SDK v0.0.15"]},{"$$mdtype":"Tag","name":"blockquote","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Deprecated"]}," - This documentation is for Flutter SDK ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["v0.0.15"]},", which is past end of life and is no longer supported. Versions ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["1.0.3"]}," and below are deprecated."," ","For the latest version, see ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/flutter-sdk/v2"},"children":["Flutter SDK v2"]},"."]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The GlomoPay Flutter SDK provides a seamless, secure, and customizable payment checkout experience for your Flutter applications. Supports all Glomo payment flows (like 3DS auth or bank redirects), built-in security compliance checks, and error handling."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"prerequisites","__idx":1},"children":["Prerequisites"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Before using this SDK, you need:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["API credentials (Public Key) from your GlomoPay dashboard"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Flutter >= 3.7.0"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Dart SDK >= 3.0.0"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"system-requirements","__idx":2},"children":["System Requirements"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Platform"},"children":["Platform"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Minimum Version"},"children":["Minimum Version"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Android"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["API 21+"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["iOS"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["13.0+"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Flutter"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["3.7.0+"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Dart"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["3.0.0+"]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"installation","__idx":3},"children":["Installation"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"1-add-dependency","__idx":4},"children":["1. Add Dependency"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Add to your ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["pubspec.yaml"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"dependencies:\n  flutter:\n    sdk: flutter\n  glomopay_sdk: ^0.0.15\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Or run:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"flutter pub add glomopay_sdk\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"2-import","__idx":5},"children":["2. Import"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"dart","header":{"controls":{"copy":{}}},"source":"import 'package:glomopay_sdk/glomopay_sdk.dart';\n","lang":"dart"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"platform-setup","__idx":6},"children":["Platform Setup"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"android-permissions","__idx":7},"children":["Android Permissions"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Add the following to ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["android/app/src/main/AndroidManifest.xml"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"xml","header":{"controls":{"copy":{}}},"source":"<manifest xmlns:android=\"http://schemas.android.com/apk/res/android\">\n    <!-- Required for the checkout flow -->\n    <uses-permission android:name=\"android.permission.INTERNET\"/>\n\n    <!-- Required if you need users to upload images/documents during checkout -->\n    <uses-permission android:name=\"android.permission.CAMERA\" />\n    <uses-permission android:name=\"android.permission.READ_EXTERNAL_STORAGE\"\n        android:maxSdkVersion=\"32\" />\n    <uses-permission android:name=\"android.permission.WRITE_EXTERNAL_STORAGE\"\n        android:maxSdkVersion=\"29\" />\n</manifest>\n","lang":"xml"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"ios-permissions","__idx":8},"children":["iOS Permissions"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Add the following to ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ios/Runner/Info.plist"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"xml","header":{"controls":{"copy":{}}},"source":"<dict>\n    <key>NSCameraUsageDescription</key>\n    <string>This app requires access to the camera to upload documents required\n    for payment verification.</string>\n    <key>NSPhotoLibraryUsageDescription</key>\n    <string>This app requires access to the photo library to select documents\n    for payment verification.</string>\n</dict>\n","lang":"xml"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"quick-start","__idx":9},"children":["Quick Start"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Before starting the checkout flow, you need to create an order and obtain the Order ID (starts with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["order_"]},")."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"dart","header":{"controls":{"copy":{}}},"source":"import 'package:flutter/material.dart';\nimport 'package:glomopay_sdk/glomopay_sdk.dart';\n\nclass PaymentScreen extends StatelessWidget {\n  @override\n  Widget build(BuildContext context) {\n    return Scaffold(\n      appBar: AppBar(title: const Text('Complete Payment')),\n      body: GlomoPayCheckout(\n        config: const GlomoPayConfig(\n          publicKey: 'test_pk_12345',\n          orderId: 'order_abc123',\n        ),\n        onPaymentSuccess: (GlomoPayPayload payload) {\n          print('Payment succeeded! Payment ID: ${payload.paymentId}');\n          // Navigate to success screen\n        },\n        onPaymentFailure: (GlomoPayPayload payload) {\n          print('Payment failed with Order ID: ${payload.orderId}');\n          // Show error message\n        },\n        onSdkError: (List<SdkError> errors) {\n          print('SDK Error: ${errors.first.message}');\n        },\n        onConnectionError: (ConnectionError error) {\n          print('Connection error: ${error.message}');\n        },\n        onPaymentTerminate: (TerminationSource source) {\n          print('User cancelled checkout via $source');\n          Navigator.pop(context);\n        },\n      ),\n    );\n  }\n}\n","lang":"dart"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"features","__idx":10},"children":["Features"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Glomo Payment Stack Support"]}," - Handles standard checkout flows and overlay redirects (3DS, bank pages) seamlessly."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Robust Security"]}," - Built-in jailbreak and root detection to ensure transactions happen on secure devices."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Error Monitoring"]}," - Built-in error tracking and diagnostics."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Comprehensive Error Handling"]}," - Handles connection drops, DNS issues, HTTP errors, and validation errors gracefully."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Native Support"]}," - Full support for Android and iOS native features like the camera and file pickers required by certain payment methods."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Mock Mode"]}," - Easy testing with test keys (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["test_..."]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mock_..."]},")."]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"api-reference","__idx":11},"children":["API Reference"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"glomopaycheckout-widget","__idx":12},"children":["GlomoPayCheckout Widget"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"props","__idx":13},"children":["Props"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Prop"},"children":["Prop"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Type"},"children":["Type"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Required"},"children":["Required"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["config"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["GlomoPayConfig"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Configuration details for the checkout session"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentSuccess"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Function(GlomoPayPayload)"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Called when payment completes successfully"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentFailure"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Function(GlomoPayPayload)"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Called when the transaction declines or fails"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Function(List<SdkError>)"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Called on SDK-level validation or configuration errors"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onConnectionError"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Function(ConnectionError)"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Called on internet drops, DNS failures, or HTTP errors"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentTerminate"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Function(TerminationSource)?"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["No"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Called when the user dismisses the modal or presses back"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["autoCloseOnConnectionError"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["bool"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["No"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Auto-close widget on connection error (default: ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["true"]},")"]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"glomopayconfig","__idx":14},"children":["GlomoPayConfig"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Property"},"children":["Property"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Type"},"children":["Type"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Default"},"children":["Default"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["publicKey"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["String"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["-"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Your GlomoPay public key. If it starts with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["test_"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mock_"]},", mock mode is enabled automatically"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["String"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["-"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["The order ID for this transaction. Must start with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["order_"]}]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"glomopaypayload","__idx":15},"children":["GlomoPayPayload"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Returned via ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentSuccess"]}," and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentFailure"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"dart","header":{"controls":{"copy":{}}},"source":"class GlomoPayPayload {\n  final String orderId;      // The order ID (e.g., \"order_abc123\")\n  final String? paymentId;   // The transaction reference, if generated\n  final String? signature;   // Validation signature for backend verification\n}\n","lang":"dart"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"sdkerror","__idx":16},"children":["SdkError"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The SDK provides validation and error reporting through the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}," callback:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"dart","header":{"controls":{"copy":{}}},"source":"class SdkError {\n  final SdkErrorType type;   // validationError, deviceForbidden, networkError, or unknown\n  final String message;      // Human-readable description of the error\n  final String? field;       // Field name that caused the error (e.g., \"orderId\")\n}\n","lang":"dart"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Error Types:"]}]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["validationError"]}," - Input validation failed (invalid ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["publicKey"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]},")"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["deviceForbidden"]}," - Device does not meet compliance requirements (rooted or jailbroken devices are not permitted)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["networkError"]}," - A network-level error occurred before reaching the checkout"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["unknown"]}," - An unclassified error"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"connectionerror","__idx":17},"children":["ConnectionError"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"dart","header":{"controls":{"copy":{}}},"source":"class ConnectionError {\n  final ConnectionErrorType type;  // noInternet, timeout, dnsFailure, sslError, etc.\n  final String message;            // Error description or HTTP status phrase\n  final int? errorCode;            // Internal WebKit/Android error code\n  final int? statusCode;           // HTTP status code, if applicable\n  final bool isRecoverable;        // Whether it is safe to offer a retry option\n}\n","lang":"dart"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Connection Error Types:"]}]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["noInternet"]}," - No internet connectivity"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["timeout"]}," - Request timed out"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["dnsFailure"]}," - DNS resolution failed"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["sslError"]}," - SSL/TLS certificate error"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["httpClientError"]}," - HTTP 4xx error"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["httpServerError"]}," - HTTP 5xx error"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["webResourceError"]}," - WebView resource loading error"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["unknown"]}," - Unclassified connection error"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"terminationsource","__idx":18},"children":["TerminationSource"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Indicates how the user exited the checkout:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["userDismiss"]}," - User swiped down or tapped a close button"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["backButton"]}," - User pressed the Android back button"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"checkout-status","__idx":19},"children":["Checkout Status"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The SDK tracks the checkout lifecycle through the following states:"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Status"},"children":["Status"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["validating"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Input keys and device compliance are being checked"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ready"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Validation passed; loading the checkout UI"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["paymentInProgress"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["User is actively completing the payment"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["paymentSuccessful"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Payment completed successfully"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["paymentFailed"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Payment was declined or failed"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["paymentCancelled"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["User dismissed or cancelled the checkout"]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"platform-specific-behavior","__idx":20},"children":["Platform-Specific Behavior"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"ios","__idx":21},"children":["iOS"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Checkout appears inside a modal"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Users can dismiss by swiping down, which triggers ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentTerminate"]}," with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["TerminationSource.userDismiss"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The SDK intercepts iOS swipe gestures to ensure the termination callback fires correctly"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"android","__idx":22},"children":["Android"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Checkout appears in full-screen mode"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Pressing the hardware back button triggers ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentTerminate"]}," with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["TerminationSource.backButton"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The SDK checks if the overlay WebView (e.g., 3DS bank page) can go back before closing the checkout entirely"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"mock-mode","__idx":23},"children":["Mock Mode"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Mock mode is automatically enabled based on your ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["publicKey"]},":"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["If ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["publicKey"]}," starts with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["test_"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mock_"]}," (case-insensitive), mock mode is enabled"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Otherwise, live mode is used"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["In mock mode:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Connection heuristics allow mock traffic"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["You can simulate transactions without real money movement"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"dart","header":{"controls":{"copy":{}}},"source":"// Mock mode\nGlomoPayConfig(\n  publicKey: 'test_pk_12345',\n  orderId: 'order_abc123',\n)\n\n// Live mode\nGlomoPayConfig(\n  publicKey: 'live_pk_xyz789',\n  orderId: 'order_abc123',\n)\n","lang":"dart"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"troubleshooting","__idx":24},"children":["Troubleshooting"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"invalid-order-id-format","__idx":25},"children":["Invalid Order ID format"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Ensure ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]}," starts with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"order_\""]}," and meets the minimum length requirement."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"sdk-errors-on-launch","__idx":26},"children":["SDK errors on launch"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Verify ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["config.publicKey"]}," is set correctly and starts with the expected prefix (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["live_"]}," for production or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["test_"]}," for mock mode)."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"file-upload-buttons-not-working","__idx":27},"children":["File upload buttons not working"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Run ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["flutter clean"]}," and ensure Camera and Storage permissions are granted in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["AndroidManifest.xml"]}," and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Info.plist"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"device-forbidden-error","__idx":28},"children":["Device Forbidden error"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Rooted or jailbroken devices trigger ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}," with a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["deviceForbidden"]}," error. Use an emulator or a non-rooted/jailbroken device for testing."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"security","__idx":29},"children":["Security"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The SDK enforces several security measures:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Device integrity checks"]}," - Root/jailbreak detection runs before loading the checkout. Compromised devices receive a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["deviceForbidden"]}," error via ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]},"."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Secure WebView"]}," - JavaScript is sandboxed within the WebView. The SDK validates all bridge messages before processing."]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"exports","__idx":30},"children":["Exports"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The SDK exports all types from a single entry point:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"dart","header":{"controls":{"copy":{}}},"source":"import 'package:glomopay_sdk/glomopay_sdk.dart';\n","lang":"dart"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["This gives you access to:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["GlomoPayCheckout"]}," - The checkout widget"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["GlomoPayConfig"]}," - Configuration class"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["GlomoPayPayload"]}," - Payment result payload"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["SdkError"]}," / ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["SdkErrorType"]}," - SDK error types"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ConnectionError"]}," / ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ConnectionErrorType"]}," - Connection error types"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["TerminationSource"]}," - Checkout termination source enum"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["LrsCheckoutStatus"]}," - Checkout lifecycle status enum"]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"related","__idx":31},"children":["Related"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/flutter-sdk/v2"},"children":["Flutter SDK v2 (Latest)"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/flutter-sdk/v1"},"children":["Flutter SDK v1 (Archived)"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/flutter-sdk/changelog"},"children":["Changelog"]}," - all release notes"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/react-native-sdk"},"children":["React Native SDK"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/unified-sdk"},"children":["Unified SDK (Web)"]}]}]}]},"headings":[{"value":"GlomoPay Flutter SDK v0.0.15","id":"glomopay-flutter-sdk-v0015","depth":1},{"value":"Prerequisites","id":"prerequisites","depth":2},{"value":"System Requirements","id":"system-requirements","depth":2},{"value":"Installation","id":"installation","depth":2},{"value":"1. Add Dependency","id":"1-add-dependency","depth":3},{"value":"2. Import","id":"2-import","depth":3},{"value":"Platform Setup","id":"platform-setup","depth":2},{"value":"Android Permissions","id":"android-permissions","depth":3},{"value":"iOS Permissions","id":"ios-permissions","depth":3},{"value":"Quick Start","id":"quick-start","depth":2},{"value":"Features","id":"features","depth":2},{"value":"API Reference","id":"api-reference","depth":2},{"value":"GlomoPayCheckout Widget","id":"glomopaycheckout-widget","depth":3},{"value":"Props","id":"props","depth":4},{"value":"GlomoPayConfig","id":"glomopayconfig","depth":3},{"value":"GlomoPayPayload","id":"glomopaypayload","depth":3},{"value":"SdkError","id":"sdkerror","depth":3},{"value":"ConnectionError","id":"connectionerror","depth":3},{"value":"TerminationSource","id":"terminationsource","depth":3},{"value":"Checkout Status","id":"checkout-status","depth":3},{"value":"Platform-Specific Behavior","id":"platform-specific-behavior","depth":2},{"value":"iOS","id":"ios","depth":3},{"value":"Android","id":"android","depth":3},{"value":"Mock Mode","id":"mock-mode","depth":2},{"value":"Troubleshooting","id":"troubleshooting","depth":2},{"value":"Invalid Order ID format","id":"invalid-order-id-format","depth":3},{"value":"SDK errors on launch","id":"sdk-errors-on-launch","depth":3},{"value":"File upload buttons not working","id":"file-upload-buttons-not-working","depth":3},{"value":"Device Forbidden error","id":"device-forbidden-error","depth":3},{"value":"Security","id":"security","depth":2},{"value":"Exports","id":"exports","depth":2},{"value":"Related","id":"related","depth":2}],"frontmatter":{"title":"Flutter SDK v0.0.15 (Deprecated)","seo":{"title":"GlomoPay Flutter SDK v0.0.15"}},"lastModified":"2026-09-22T05:15:29.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/platform/sdk/flutter-sdk/v0.0.15","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}