THAMER
Sovereign Bitcoin Wallet

WALLET AI BITCOIN

Your Bitcoin Wallet. Your Keys. Your Engine.

Self-hosted Bitcoin software built for developers, applications, and AI agents.

CREATE WALLET

Designing Mobile Bitcoin SDKs for iOS and Android

permalink THAMER
#application-development#bitcoin#sdk#wab

Research status: Theoretical SDK design. Examples are illustrative and have not been built or tested against the live engine.

Mobile trust boundaries

A mobile SDK should expose typed payment and wallet views rather than assume that every device is a trusted engine operator. Two deployment models are possible: a personal wallet client connecting to an authorized engine, and a merchant application calling its own backend. In the second model the backend retains the BTC KEY and maps authenticated users to orders. A customer must never receive the merchant credential. Neither model implies that the engine provides mobile user accounts or scoped tokens.

Proposed interface

interface MobilePayments {
  createInvoice(orderId: string): Promise<InvoiceView>;
  refreshInvoice(invoiceId: string): Promise<InvoiceView>;
}

These are application-facing methods, not engine endpoints. The backend creates a WATCH record using the documented contract and stores the association with the order. The mobile client renders the returned address and amount, including the network. Use integer satoshis; never calculate settlement amounts using floating-point BTC values.

Lifecycle and transport

A mobile process can be suspended after submitting a request but before receiving its response. Persist the order identifier before submission and query the existing order after resuming. The server should own payment monitoring and fulfillment, because background execution and connectivity are not guaranteed. Treat push notifications as refresh hints, not payment evidence. Require TLS and distinguish an unavailable engine from a zero balance or an unpaid invoice.

Acceptance plan

Mock airplane mode, process termination, duplicate taps, expired invoices and delayed confirmations. Verify that a resumed session does not create a second invoice or send. Compare testnet observations with the engine and transaction evidence. Mobile platform payment rules must be reviewed separately for each distribution channel and product category; SDK capability does not imply store approval.

Primary reference

https://thamer.org/api

Related reading

https://thamer.org/docs/wab-sdk-api-engine-application-boundaries
https://thamer.org/docs/wab-sdk-authentication-credential-management
https://thamer.org/docs/wab-sdk-idempotency-retry-strategies
https://thamer.org/docs/wab-sdk-payment-reconciliation
https://thamer.org/docs/wab-sdk-swift-bitcoin-payments
https://thamer.org/docs/wab-sdk-kotlin-bitcoin-applications
https://thamer.org/docs/wab-sdk-flutter-cross-platform
https://thamer.org/docs/wab-sdk-mobile-secure-backend
https://thamer.org/docs/wab-sdk-desktop-applications

Questions & Answers

Explore all questions →

Latest from the Lab

THAMER illustrated developer portrait and signature

ABOUT THE DEVELOPER

Independent Software Developer specializing in Bitcoin Script, Golang, and AI Agents.

Software engineering · Independent research · Open-source projects