{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"Android SDK","description":"Znajdziesz tutaj wszystkie niezbędne informacje dotyczące integracji i obsługi systemu płatności SimPay.pl","siteUrl":"https://docs.simpay.pl","llmstxt":{"hide":false,"sections":[{"title":"Table of contents","includeFiles":["**/*"],"excludeFiles":[]}],"excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"android-sdk","__idx":0},"children":["Android SDK"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["SimPay Checkout Android SDK wyświetla arkusz płatności w aplikacji. Pobiera kanały, tworzy transakcję, obsługuje BLIK Level 0 i kanały z przekierowaniem w Custom Tab, a następnie sprawdza status przez API. To biblioteka interfejsu Android, nie ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://github.com/SimPaypl/SimPay-API-java"},"children":["Java SDK do integracji backendowej"]},"."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Kod i aplikacja demonstracyjna są w repozytorium ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://github.com/SimPaypl/simpay-android"},"children":["simpay-android"]},". Ten SDK nie udostępnia obsługi OneClick, płatności cyklicznych BLIK, zwrotów, SMS ani DirectBilling."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"przygotowanie","__idx":1},"children":["Przygotowanie"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["W panelu akceptanta otwórz ustawienia usługi i włącz obsługę w zakładce \"Mobilne SDK\"."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Zapisz krótki, 8-znakowy identyfikator usługi, np. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["a1b2c3d4"]},". To pierwszy segment UUID usługi, nie cały UUID. Backend i aplikacja muszą używać tej samej wartości."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Zarejestruj schemat powrotu, np. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["pl.example.shop"]},". Musi być identyczny w panelu, manifeście Androida i ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["TransactionReturns"]},"."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Przygotuj backend do wydawania sesji i weryfikacji IPN. Klucz API akceptanta pozostaje wyłącznie na backendzie. Nie umieszczaj go w APK, zasobach ani ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["BuildConfig"]},"."]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["SDK wymaga ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["minSdk"]}," 21, ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["compileSdk"]}," co najmniej 34 i zgodności kodu Java 11. Wersja JDK uruchamiająca Gradle zależy od używanego Android Gradle Plugin, nie od ustawienia zgodności Java 11. Hostem arkusza musi być ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["FragmentActivity"]}," lub jej podklasa, np. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["AppCompatActivity"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"zależność-gradle","__idx":2},"children":["Zależność Gradle"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["W ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["settings.gradle.kts"]}," aplikacji:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"kotlin","header":{"controls":{"copy":{}}},"source":"dependencyResolutionManagement {\n    repositories {\n        google()\n        mavenCentral()\n    }\n}\n","lang":"kotlin"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["W ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["build.gradle.kts"]}," modułu aplikacji:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"kotlin","header":{"controls":{"copy":{}}},"source":"android {\n    compileSdk = 34\n    defaultConfig { minSdk = 21 }\n    compileOptions {\n        sourceCompatibility = JavaVersion.VERSION_11\n        targetCompatibility = JavaVersion.VERSION_11\n    }\n}\n\ndependencies {\n    implementation(\"pl.simpay:checkout-android:1.0.0\")\n}\n","lang":"kotlin"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Wersja ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["1.0.0"]}," jest dostępna w ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://central.sonatype.com/artifact/pl.simpay/checkout-android/1.0.0"},"children":["Maven Central"]},". Pakiet zawiera AAR, źródła i dokumentację Javadoc. Nie wymaga dodatkowego repozytorium Maven poza ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mavenCentral()"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"sesja-z-backendu","__idx":3},"children":["Sesja z backendu"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Aplikacja prosi Twój uwierzytelniony backend o sesję. Backend wywołuje ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["POST https://api.simpay.pl/payment/{serviceId}/mobile-sdk/session"]}," z kluczem akceptanta w ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Authorization: Bearer <klucz API>"]},". Zwraca aplikacji krótko ważny token, zwykle około 15 minut, jego termin ważności, jeśli dostępny, oraz publiczny IP płatnika zaobserwowany przy żądaniu. Za proxy korzystaj wyłącznie z zaufanej konfiguracji przekazywania IP, nie z dowolnego nagłówka od klienta."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["MyBackendClient"]}," i ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["BackendSessionResponse"]}," poniżej to abstrakcje dostarczane przez integratora, nie klasy SDK. Zaimplementuj klienta HTTP swojego backendu. Nie wywołuj endpointu sesji z kluczem akceptanta z aplikacji."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"kotlin","header":{"controls":{"copy":{}}},"source":"import pl.simpay.android.checkout.mobile.MobileSdkSession\nimport pl.simpay.android.checkout.mobile.MobileSessionProvider\n\ndata class BackendSessionResponse(\n    val token: String,\n    val expiresAt: String?,\n    val payerIp: String\n)\n\ninterface MyBackendClient {\n    suspend fun createPaymentSession(): BackendSessionResponse\n}\n\nclass BackendSessionProvider(private val client: MyBackendClient) : MobileSessionProvider {\n    override suspend fun provideSession(): MobileSdkSession {\n        val response = client.createPaymentSession()\n        return MobileSdkSession(\n            token = response.token,\n            expiresAt = response.expiresAt,\n            payerIp = response.payerIp\n        )\n    }\n}\n","lang":"kotlin"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Przekaż cały token z prefiksem ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mobsdk_"]},". SDK dodaje ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Bearer"]}," i używa stałego hosta ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["https://api.simpay.pl"]},". Provider powinien zwracać aktualną sesję, także przy ponownym wywołaniu. Nie loguj tokenów. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["payerIp"]}," to publiczny adres płatnika, nie adres serwera backendu ani lokalnego interfejsu telefonu. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["payerIpOverride"]}," w zamówieniu jest tylko wartością zapasową, gdy sesja nie zawiera IP, i podlega tym samym zasadom."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"zamówienie-i-otwarcie-arkusza","__idx":4},"children":["Zamówienie i otwarcie arkusza"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Poniższa funkcja przyjmuje klienta Twojego backendu. Wywołaj ją z aktywnej ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["FragmentActivity"]},", np. po naciśnięciu przycisku płatności. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["onResult"]}," aktualizuje interfejs aplikacji, nie realizuje zamówienia."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"kotlin","header":{"controls":{"copy":{}}},"source":"import androidx.fragment.app.FragmentActivity\nimport java.math.BigDecimal\nimport pl.simpay.android.checkout.mobile.CheckoutResult\nimport pl.simpay.android.checkout.mobile.SimPayMobileCheckout\nimport pl.simpay.android.checkout.mobile.SimPayMobileConfiguration\nimport pl.simpay.android.checkout.mobile.TransactionOrder\nimport pl.simpay.android.checkout.mobile.TransactionReturns\n\nfun pay(\n    activity: FragmentActivity,\n    client: MyBackendClient,\n    onResult: (CheckoutResult) -> Unit\n) {\n    val checkout = SimPayMobileCheckout(\n        configuration = SimPayMobileConfiguration(\n            serviceId = \"a1b2c3d4\",\n            merchantDisplayName = \"Example Shop\"\n        ),\n        sessionProvider = BackendSessionProvider(client)\n    )\n    val order = TransactionOrder(\n        amount = BigDecimal(\"49.99\"),\n        currency = \"PLN\",\n        description = \"Order 2451\",\n        control = \"order-2451\",\n        customerEmail = \"buyer@example.com\",\n        customerCountryCode = \"PL\",\n        returns = TransactionReturns(\n            success = \"pl.example.shop://payment-return?result=success\",\n            failure = \"pl.example.shop://payment-return?result=failure\"\n        )\n    )\n    checkout.present(activity, order, onResult)\n}\n","lang":"kotlin"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Kwota musi wynosić co najmniej ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["1"]},". Używaj ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["BigDecimal"]}," z tekstu, nie z ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Double"]},". Opis ma limit 64 znaków, ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["control"]}," 255. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["control"]}," powinno wskazywać zamówienie zapisane w Twoim backendzie. E-mail jest wymagany. Kraj to dwie wielkie litery ISO 3166-1 alpha-2 zgodne z walutą. SDK może ustalić kraj z waluty, ale dla niejednoznacznej waluty, np. EUR, podaj go jawnie."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"powrót-z-przeglądarki","__idx":5},"children":["Powrót z przeglądarki"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Dodaj do ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["<application>"]}," w ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["AndroidManifest.xml"]},". Zastąp nazwy klas i schemat wartościami swojej aplikacji. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["CheckoutActivity"]}," musi dziedziczyć po ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["FragmentActivity"]},"."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"xml","header":{"controls":{"copy":{}}},"source":"<activity\n    android:name=\".CheckoutActivity\"\n    android:exported=\"false\"\n    android:launchMode=\"singleTop\" />\n<activity\n    android:name=\".PaymentReturnActivity\"\n    android:exported=\"true\"\n    android:theme=\"@android:style/Theme.Translucent.NoTitleBar\">\n    <intent-filter>\n        <action android:name=\"android.intent.action.VIEW\" />\n        <category android:name=\"android.intent.category.DEFAULT\" />\n        <category android:name=\"android.intent.category.BROWSABLE\" />\n        <data android:scheme=\"pl.example.shop\" android:host=\"payment-return\" />\n    </intent-filter>\n</activity>\n","lang":"xml"},"children":[]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"kotlin","header":{"controls":{"copy":{}}},"source":"import android.app.Activity\nimport android.content.Intent\nimport android.os.Bundle\n\nclass PaymentReturnActivity : Activity() {\n    override fun onCreate(savedInstanceState: Bundle?) {\n        super.onCreate(savedInstanceState)\n        startActivity(\n            Intent(this, CheckoutActivity::class.java)\n                .addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP or Intent.FLAG_ACTIVITY_SINGLE_TOP)\n        )\n        finish()\n    }\n}\n","lang":"kotlin"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Nie traktuj parametru ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["result=success"]}," jako potwierdzenia płatności. Schematy niestandardowe nie gwarantują wyłączności aplikacji. Powrót ma jedynie przywrócić ekran, a SDK ponownie sprawdza status transakcji. Nie zakładaj odtworzenia callbacku i całego checkoutu po zabiciu procesu. Po ponownym uruchomieniu pobierz stan zamówienia z backendu zamiast automatycznie tworzyć nową płatność."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"wynik-i-realizacja-zamówienia","__idx":6},"children":["Wynik i realizacja zamówienia"]},{"$$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":"CheckoutResult"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["CheckoutResult"]}]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Działanie aplikacji"},"children":["Działanie aplikacji"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Succeeded"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["SDK odczytał ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_paid"]},". Pokaż wynik i pobierz stan zamówienia z backendu."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Pending"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Wynik pozostaje otwarty, np. trwa weryfikacja lub skończył się czas odpytywania. Nie oznaczaj jako opłacone ani definitywnie odrzucone. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transactionId"]}," może być ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["null"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Failed"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Obsłuż ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["error"]},"; ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["message"]}," zawiera szczegóły techniczne. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transactionId"]}," i ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["rawStatus"]}," mogą być ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["null"]},". Sprawdź stan zamówienia przed ponowieniem."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Cancelled"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Użytkownik zamknął arkusz. Nie jest to dowód anulowania zamówienia na backendzie."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Żaden wynik SDK nie uprawnia do wydania towaru. Zmodyfikowana aplikacja może zmienić kwotę, walutę i ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["control"]},", a token sesji nie wiąże tych wartości z zamówieniem."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Backend musi zweryfikować ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/notifications/payment/signature"},"children":["sygnaturę IPN"]}," i obsłużyć ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/notifications/payment/events/transaction_status_changed"},"children":["zmianę statusu transakcji"]},". Przed realizacją porównaj status opłacenia, identyfikator usługi, ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["control"]}," i powiązanie transakcji z zamówieniem, kwotę oraz walutę z własnym rekordem zamówienia. Obsłuż powtórzone IPN idempotentnie. Przeglądarka i aplikacja nie są źródłem potwierdzenia. Zobacz ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/notifications/payment"},"children":["wprowadzenie do IPN"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"rozwiązywanie-problemów","__idx":7},"children":["Rozwiązywanie problemów"]},{"$$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":"Objaw"},"children":["Objaw"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Co sprawdzić"},"children":["Co sprawdzić"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Gradle nie znajduje ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["1.0.0"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Sprawdź współrzędne ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["pl.simpay:checkout-android:1.0.0"]}," i obecność ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mavenCentral()"]}," w repozytoriach."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Błąd metadanych AAR"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["compileSdk"]}," musi wynosić co najmniej 34."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["present"]}," nie przyjmuje Activity"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Wymagana jest ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["FragmentActivity"]},", nie sama ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ComponentActivity"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["SessionFailed"]}," lub ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Unauthorized"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Włączenie Mobilnego SDK, krótki service ID, zgodność usługi i klucza na backendzie, ważność tokenu i pełny prefiks ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mobsdk_"]},"."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["MissingPayerIp"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Backend musi zwrócić publiczny IP płatnika w sesji."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["MissingCountryCode"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Podaj ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["customerCountryCode"]},", zwłaszcza dla EUR."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Płatnik zostaje w przeglądarce"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Porównaj schemat w panelu, manifeście i obu adresach ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["TransactionReturns"]},", a także host filtra."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["RateLimited"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Odczekaj przed ponowieniem, nie pobieraj sesji w pętli."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["BrowserUnavailable"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Na urządzeniu musi być przeglądarka obsługująca przekierowanie."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Indeterminate"]},", timeout lub ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Pending"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Sprawdź stan na backendzie. Nie ponawiaj automatycznie operacji, która mogła już utworzyć transakcję."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Do diagnostyki używaj ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["CheckoutResult.Failed.error"]}," i ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["message"]},", bez tokenów i danych płatnika w logach. Demo z fałszywym API sprawdza interfejs, nie rzeczywistą płatność. Przed wdrożeniem sprawdź na przygotowanej usłudze BLIK, przekierowanie i powrót, przerwanie płatności, opóźnione IPN i zgodność danych zamówienia na backendzie."]}]},"headings":[{"value":"Android SDK","id":"android-sdk","depth":1},{"value":"Przygotowanie","id":"przygotowanie","depth":2},{"value":"Zależność Gradle","id":"zależność-gradle","depth":2},{"value":"Sesja z backendu","id":"sesja-z-backendu","depth":2},{"value":"Zamówienie i otwarcie arkusza","id":"zamówienie-i-otwarcie-arkusza","depth":2},{"value":"Powrót z przeglądarki","id":"powrót-z-przeglądarki","depth":2},{"value":"Wynik i realizacja zamówienia","id":"wynik-i-realizacja-zamówienia","depth":2},{"value":"Rozwiązywanie problemów","id":"rozwiązywanie-problemów","depth":2}],"frontmatter":{"seo":{"title":"Android SDK"}},"lastModified":"2026-10-14T21:00:41.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/sdks/android","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}