{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-platform/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"GlomoPay React Native SDK v1","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-react-native-sdk-v1","__idx":0},"children":["GlomoPay React Native SDK v1"]},{"$$mdtype":"Tag","name":"blockquote","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Archived"]}," - This documentation is for React Native SDK ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["v1.x"]}," (LRS-only). v1 is no longer the recommended version."," ","For the latest version, see ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/react-native-sdk/v3"},"children":["React Native SDK v3"]},"."," ","To upgrade, see the ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/react-native-sdk/migration"},"children":["Migration Guide"]},"."]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Official React Native SDK for integrating GlomoPay payment checkout flows into your mobile applications."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"features","__idx":1},"children":["Features"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Cross-Platform"]}," - Works seamlessly on both iOS and Android"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["TypeScript Support"]}," - Full type definitions included"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Simple Integration"]}," - Minimal configuration required"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Secure"]}," - WebView-based checkout with signature verification"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Device Security Compliance"]}," - Prevents unsafe/non-compliant devices from initiating checkouts as per regulatory policies"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Flexible"]}," - Support for multiple payment methods through GlomoPay"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"prerequisites","__idx":2},"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":"Heading","attributes":{"level":2,"id":"system-requirements","__idx":3},"children":["System Requirements"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["React Native >= 0.68.0"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["React >= 17.0.0"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Node.js >= 16.0.0"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["npm >= 8.0.0"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"installation","__idx":4},"children":["Installation"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"1-standard-react-native-cli-project","__idx":5},"children":["1. Standard React Native CLI project"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For standard installations, this SDK requires ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["react-native-webview"]}," as a peer dependency. Install it first:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"npm install react-native-webview\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Then install the SDK"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"npm install @glomopay/react-native-sdk@1.3.5\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Recommended: Enhanced Security Compliance"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For enhanced device security compliance (rooted/jailbroken device detection), we HIGHLY recommend installing the peer dependency ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"npm install jail-monkey\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Note:"]}," The SDK works without ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]},", but installing it enables automatic device security compliance checks that help meet regulatory requirements. See ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"#device-security-compliance"},"children":["Device Security Compliance"]}," section for more details."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"2-expo-projects","__idx":6},"children":["2. Expo Projects"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["This SDK is compatible with Expo projects. Install with:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"npx expo install react-native-webview\nnpx expo install @glomopay/react-native-sdk@1.3.5\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Note"]},": Requires custom dev client or EAS Build. Not compatible with Expo Go app."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For Expo Go limitations, see ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://docs.expo.dev/workflow/customizing/"},"children":["Expo documentation"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"quick-start","__idx":7},"children":["Quick Start"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Before starting the checkout flow, you'll need to create an LRS order using other Glomo SDKs and obtain the Order ID (Alphanumeric, starts with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["order_"]},")."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"1-import-the-sdk","__idx":8},"children":["1. Import the SDK"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"import {\n  GlomoLrsCheckout,\n  type GlomoLrsCheckoutRef,\n  type SdkError,\n} from '@glomopay/react-native-sdk';\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"2-add-the-component-to-your-app","__idx":9},"children":["2. Add the Component to Your App"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"import React, { useState, useRef } from 'react';\nimport { View } from 'react-native';\nimport {\n  GlomoLrsCheckout,\n  type GlomoLrsCheckoutRef,\n} from '@glomopay/react-native-sdk';\n\nfunction CheckoutScreen()\n{\n  const [orderId, setOrderId] = useState('YOUR_ORDER_ID');\n  const checkoutRef = useRef<GlomoLrsCheckoutRef>(null);\n\n  const startLrsCheckout = () => {\n    const started = checkoutRef.current?.start();\n    if (!started) {\n      const status = checkoutRef.current?.getStatus();\n      console.log('Checkout could not be started. Current status:', status);\n    }\n  };\n\n  return (\n    <View>\n      <GlomoLrsCheckout\n        ref={checkoutRef}\n        publicKey={'YOUR_PUBLIC_KEY'}\n        orderId={orderId}\n        onPaymentSuccess={(payload) => {\n          console.log('Payment successful!', payload);\n          // Handle successful payment\n        }}\n        onPaymentFailure={(payload) => {\n          console.log('Payment failed!', payload);\n          // Handle failed payment\n        }}\n        onConnectionError={(error) => {\n          console.log('Could not open LRS checkout!', error);\n          // Handle connection/network errors\n        }}\n        onSdkError={(errors) => {\n          errors.forEach((error) => {\n            console.error('SDK Error:', error.message);\n            // Handle validation errors\n          });\n        }}\n      />\n    </View>\n  );\n}\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"api-reference","__idx":10},"children":["API Reference"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"glomolrscheckout-component","__idx":11},"children":["GlomoLrsCheckout Component"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"props","__idx":12},"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":["publicKey"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Your public key. If it starts with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["test_"]},", mock mode will be enabled automatically. Otherwise, live mode is used."]}]},{"$$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":["Yes"]},{"$$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":"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":["(payload: GlomoLrsCheckoutPayload) => void"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Callback function called when the payment is successful"]}]},{"$$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":["(payload: GlomoLrsCheckoutPayload) => void"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Callback function called when the payment fails"]}]},{"$$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":["(error: unknown) => void"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["No"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Will be called on network connection problems. The checkout modal will automatically close before this is triggered."]}]},{"$$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":["() => void"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["No"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Callback called when checkout is terminated. Triggered when the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["checkout.closed"]}," event is received from the WebView or when the user dismisses the modal (iOS swipe down) or presses the back button (Android)"]}]},{"$$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":["(errors: SdkError[]) => void"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["No"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Callback for SDK validation errors and configuration issues. Receives an array of ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["SdkError"]}," objects when validation fails."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["visible"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["boolean"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["No"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Control modal visibility manually (advanced usage only). It is HIGHLY recommended to not use this prop directly."]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"ref-methods","__idx":13},"children":["Ref Methods"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"interface GlomoLrsCheckoutRef {\n  /**\n   * Starts the checkout flow.\n   * Returns true if started, false if it cannot be started.\n   */\n  start: () => boolean;\n  /**\n   * Returns the current checkout status.\n   */\n  getStatus: () => LrsCheckoutStatus;\n}\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Usage:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"const checkoutRef = useRef<GlomoLrsCheckoutRef>(null);\n\n// Start checkout - returns true if successful, false otherwise\nconst started = checkoutRef.current?.start();\nif (started) {\n  console.log('Checkout started successfully');\n} else {\n  console.log('Checkout could not be started. Check the status.');\n}\n\n// Check status\nconst currentStatus = checkoutRef.current?.getStatus();\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Note:"]}]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," method returns ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["true"]}," if the checkout was started successfully, ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["false"]}," otherwise"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," method performs device compliance checks first (before any other validation) ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["if ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]}," is installed"]},".",{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["If the device is rooted or jailbroken and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]}," is available, it will return ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["false"]}," and trigger the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}," callback with a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["device_forbidden"]}," error."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["If ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]}," is not installed, compliance checks are skipped and checkout proceeds normally."]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," method may be used to restart an LRS checkout for an existing order,",{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["If the user cancelled the payment midway (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_cancelled\""]}," status) by pressing the back button on Android, or dismissing the modal on iOS"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Or if the payment failed or timed-out (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_failed\""]}," status)"]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["After an LRS checkout for an ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]}," is successful, further calls to the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," method will return false, and will not re-trigger an LRS checkout (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_successful\""]}," status)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Changing the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]},"/",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["publicKey"]}," props resets the flow, and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," can be triggered again"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"glomolrscheckoutpayload","__idx":14},"children":["GlomoLrsCheckoutPayload"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"typescript","header":{"controls":{"copy":{}}},"source":"interface GlomoLrsCheckoutPayload {\n  orderId: string;    // Order identifier (e.g., \"order_abc123\")\n  paymentId: string;  // Payment id from GlomoPay\n  signature: string;  // Signature for verification\n}\n","lang":"typescript"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The payload is returned for both successful and failed LRS payments."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"sdkerror","__idx":15},"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":"typescript","header":{"controls":{"copy":{}}},"source":"interface SdkError {\n  type: \"validation_error\" | \"device_forbidden\";\n  message: string;\n  field?: \"publicKey\" | \"orderId\";\n}\n","lang":"typescript"},"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":["validation_error"]},": Input validation failed (invalid publicKey or orderId)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["device_forbidden"]},": Device does not meet compliance requirements (LRS checkout is not permitted on compromised/rooted devices per regulatory policies)."]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Example:"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"<GlomoLrsCheckout\n  onSdkError={(errors) => {\n    errors.forEach((error) => {\n      console.error(`SDK Error [${error.type}]:`, error.message);\n      if (error.field) {\n        console.error(`Field: ${error.field}`);\n      }\n    });\n    // Handle validation errors appropriately\n  }}\n  // ... other props\n/>\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Note:"]}," The SDK validates all inputs when ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," is called. Validation errors are reported through ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}," and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," will return ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["false"]}," if validation fails."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"checkout-status-system","__idx":16},"children":["Checkout Status System"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The SDK provides a status system to track the checkout lifecycle. Access the current status using the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["getStatus()"]}," method on the component ref:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"const checkoutRef = useRef<GlomoLrsCheckoutRef>(null);\nconst currentStatus = checkoutRef.current?.getStatus();\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"status-values","__idx":17},"children":["Status Values"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["LrsCheckoutStatus"]}," type includes the following values:"]},{"$$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":["\"ready\""]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Checkout is ready to be started"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_in_progress\""]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Checkout flow is active and ongoing"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_successful\""]}]},{"$$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":["\"payment_failed\""]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Payment failed (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["glomoLrsCheckoutRef.current?.start()"]}," can be reused with the same ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]},")"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_cancelled\""]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["User cancelled the checkout midway (",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["glomoLrsCheckoutRef.current?.start()"]}," can be reused with the same ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]},")"]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"status-lifecycle","__idx":18},"children":["Status Lifecycle"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"ready → payment_in_progress → payment_successful (order complete)\n         ↓                           ↑                    ↑\n  payment_cancelled (can call start() again to restart)   |\n         ↓                           ↑                    ↑\n  payment_failed (can call start() again to retry) → _____⌟\n"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"platform-specific-behavior","__idx":19},"children":["Platform-Specific Behavior"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"ios","__idx":20},"children":["iOS"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Checkout appears inside a modal within a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["pageSheet"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Users can dismiss ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["GlomoLrsCheckout"]}," component by swiping down"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentTerminate"]}," is called when modal is dismissed"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"android","__idx":21},"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":["Users can press the hardware back button to close the full-screen ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["GlomoLrsCheckout"]}," component"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Back button triggers ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentTerminate"]}," and closes checkout"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"troubleshooting","__idx":22},"children":["Troubleshooting"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"common-issues","__idx":23},"children":["Common Issues"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"1-checkout-not-appearing","__idx":24},"children":["1. Checkout not appearing"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Solution"]},":"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Ensure ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," is called via ref and check its return value"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["If ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," returns ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["false"]},", check the current status using ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["getStatus()"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The checkout status must be ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"ready\""]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_cancelled\""]},", or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_failed\""]}," for ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," to succeed"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The checkout status must NOT be ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["\"payment_successful\""]}," (successful payments cannot be restarted)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Device Security Compliance"]},": If peer dependency ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]}," is installed and the device does not meet compliance requirements (the device is rooted/jailbroken), ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," will return ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["false"]},". Check ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}," callback for ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["device_forbidden"]}," errors.",{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["However, if ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]}," has not been installed, security compliance checks will be skipped."]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Check that ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]}," is provided and valid (must start with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["order_"]},")"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Ensure ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["publicKey"]}," is valid (must start with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["live_"]},")"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Implement ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}," callback to receive validation and device compliance error details"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"2-expo-go-invariant-violation-error","__idx":25},"children":["2. Expo Go \"Invariant Violation\" error"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Solution"]},":"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Expo Go doesn't support native modules"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Use custom dev client: ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["npx expo prebuild"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Or use EAS Build for testing"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"mock-mode-testing","__idx":26},"children":["Mock Mode Testing"]},{"$$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 your ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["publicKey"]}," starts with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["test_"]}," (case-insensitive), mock mode is automatically enabled and the checkout URL will include ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mode=mock"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Otherwise, live mode is used and the checkout URL will include ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mode=live"]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Example:"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"// Mock mode (publicKey starts with \"test_\")\n<GlomoLrsCheckout\n  publicKey=\"test_abc123...\"\n  // ... other props\n/>\n\n// Live mode (publicKey does not start with \"test_\")\n<GlomoLrsCheckout\n  publicKey=\"live_xyz789...\"\n  // ... other props\n/>\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"connection-handling","__idx":27},"children":["Connection Handling"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The SDK provides an (optional) ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onConnectionError"]}," callback for connection error events. The checkout modal/page will be dismissed/closed, before this callback is triggered."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Scenarios:"]}]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Connection failures"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Internet unavailability"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["DNS resolution failures"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Note:"]}," HTTP ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["4xx"]},"/",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["5xx"]}," errors will not be captured as connection errors."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Example:"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"<GlomoLrsCheckout\n  onConnectionError={(error) => {\n    // Handle connection/network errors\n    // The modal will be automatically closed before this callback is triggered\n    Alert.alert('Connection Error', 'Unable to connect to the GlomoPay servers. Please check your internet connection.');\n  }}\n  // ... other props\n/>\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Note:"]}," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onConnectionError"]}," is for network/connection errors only. Payment-specific failures should be handled by ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onPaymentFailure"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"device-security-compliance","__idx":28},"children":["Device Security Compliance"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Important:"]}," The SDK provides automatic device security compliance checking via the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]}," library. For enhanced security compliance and to meet regulatory requirements, we ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["strongly recommend"]}," installing the optional peer dependency ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"installation-1","__idx":29},"children":["Installation"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"npm install jail-monkey\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"how-it-works","__idx":30},"children":["How It Works"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["With ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]}," installed:"]}," The SDK automatically performs device security compliance checks before allowing an LRS checkout to start. Rooted (Android) or jailbroken (iOS) devices are prevented from starting checkouts."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Without ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["jail-monkey"]},":"]}," The SDK skips automatic compliance checks, and allows checkout to proceed normally. Regulatory compliance would have to be enforced manually."]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"features-1","__idx":31},"children":["Features"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["An automatic device security compliance check:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Runs synchronously as the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["first validation step"]}," in the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," method"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Blocks checkout on non-compliant devices to meet regulatory requirements"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Works on both iOS and Android platforms"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Triggers the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}," callback with a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["device_forbidden"]}," error if a non-compliant device is detected"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Example:"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"<GlomoLrsCheckout\n  onSdkError={(errors) => {\n    errors.forEach((error) => {\n      if (error.type === 'device_forbidden') {\n        Alert.alert(\n          'Device Unsafe',\n          'LRS checkout is not permitted on rooted or jailbroken devices per regulatory compliance requirements.'\n        );\n      }\n    });\n  }}\n  // ... other props\n/>\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"input-validation","__idx":32},"children":["Input Validation"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The SDK automatically validates all inputs:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["publicKey"]}]},": Must start with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["live_"]}," and have a minimum length of 6 characters"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["orderId"]}]},": Must start with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["order_"]}," and have a minimum length of 7 characters"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Validation errors are reported through the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onSdkError"]}," callback. The SDK validates inputs when ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["start()"]}," is called:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Device security compliance check (first, before any other validation)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Input validation (publicKey, orderId)"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Example:"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"tsx","header":{"controls":{"copy":{}}},"source":"<GlomoLrsCheckout\n  onSdkError={(errors) => {\n    if (errors.length > 0) {\n      // Handle validation errors\n      Alert.alert(\n        'Configuration Error',\n        errors.map(e => e.message).join('\\n')\n      );\n    }\n  }}\n  // ... other props\n/>\n","lang":"tsx"},"children":[]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"next-steps","__idx":33},"children":["Next steps"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/react-native-sdk/migration"},"children":["Upgrade to v3"]}," - migration guide with before/after code examples"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/react-native-sdk/v3"},"children":["React Native SDK v3 documentation"]}," - latest version"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/platform/sdk/react-native-sdk/changelog"},"children":["Changelog"]}," - all versions"]}]}]},"headings":[{"value":"GlomoPay React Native SDK v1","id":"glomopay-react-native-sdk-v1","depth":1},{"value":"Features","id":"features","depth":2},{"value":"Prerequisites","id":"prerequisites","depth":2},{"value":"System Requirements","id":"system-requirements","depth":2},{"value":"Installation","id":"installation","depth":2},{"value":"1. Standard React Native CLI project","id":"1-standard-react-native-cli-project","depth":3},{"value":"2. Expo Projects","id":"2-expo-projects","depth":3},{"value":"Quick Start","id":"quick-start","depth":2},{"value":"1. Import the SDK","id":"1-import-the-sdk","depth":3},{"value":"2. Add the Component to Your App","id":"2-add-the-component-to-your-app","depth":3},{"value":"API Reference","id":"api-reference","depth":2},{"value":"GlomoLrsCheckout Component","id":"glomolrscheckout-component","depth":3},{"value":"Props","id":"props","depth":4},{"value":"Ref Methods","id":"ref-methods","depth":3},{"value":"GlomoLrsCheckoutPayload","id":"glomolrscheckoutpayload","depth":4},{"value":"SdkError","id":"sdkerror","depth":4},{"value":"Checkout Status System","id":"checkout-status-system","depth":4},{"value":"Status Values","id":"status-values","depth":4},{"value":"Status Lifecycle","id":"status-lifecycle","depth":4},{"value":"Platform-Specific Behavior","id":"platform-specific-behavior","depth":2},{"value":"iOS","id":"ios","depth":3},{"value":"Android","id":"android","depth":3},{"value":"Troubleshooting","id":"troubleshooting","depth":2},{"value":"Common Issues","id":"common-issues","depth":3},{"value":"1. Checkout not appearing","id":"1-checkout-not-appearing","depth":4},{"value":"2. Expo Go \"Invariant Violation\" error","id":"2-expo-go-invariant-violation-error","depth":4},{"value":"Mock Mode Testing","id":"mock-mode-testing","depth":3},{"value":"Connection Handling","id":"connection-handling","depth":3},{"value":"Device Security Compliance","id":"device-security-compliance","depth":3},{"value":"Installation","id":"installation-1","depth":4},{"value":"How It Works","id":"how-it-works","depth":4},{"value":"Features","id":"features-1","depth":4},{"value":"Input Validation","id":"input-validation","depth":3},{"value":"Next steps","id":"next-steps","depth":2}],"frontmatter":{"title":"React Native SDK v1 (Archived)","seo":{"title":"GlomoPay React Native SDK v1"}},"lastModified":"2026-09-22T05:15:29.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/platform/sdk/react-native-sdk/v1","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}