2025-05-29 Changelog

Android
Mobile Payments SDK
Link to section

Details

  • The Mobile Payments SDK is launching in the United Kingdom as a private alpha. Please contact [email protected] for information.
Link to section

Android Mobile Payments SDK 2.3.0

Important

Deprecation notice:

  • readerInfo.state is deprecated. For a more descriptive representation of a reader's state, use the new readerInfo.status field. For more information, see Reader status.
  • idempotencyKey is deprecated. To handle idempotent payment requests, use the new paymentAttemptId field. For more information, see Idempotency and payment attempts.
  • readerInfo.status - A new sealed class with more descriptive reader representation. It replaces the deprecated state. The possible reader statuses are:
    • ConnectingToDevice
    • ConnectingToSquare
    • ReaderUnavailable
    • Faulty
    • Ready
  • ReaderUnavailableReason - A new enum with detailed error information for unavailable readers.
  • ConnectionType - A new enum in the ReaderInfo class describing the connection type of the reader. The possible connection types are:
    • USB
    • BLUETOOTH
    • AUDIO
    • EMBEDDED
  • paymentAttemptID - A new parameter representing a payment attempt. When included in the call to startPaymentActivity, an idempotency key is generated by Square and regenerated if multiple requests are made for a single payment attempt (for example, in markets with Strong Customer Authentication (SCA) requirements).
  • readerManager.retryConnection() - A new method for retrying the connection with Square servers in the event that a reader's status is ReaderUnavailable.
  • getIdempotencyKey(paymentAttemptId) - A new method to retrieve the final idempotency key used for a payment attempt.
  • getAllIdempotencyKeys - A new method for retrieving all payment attempt IDs from the last 24 hours and their idempotency keys from local storage.
  • currentPaymentHandle - A PaymentHandle for interacting with the currently active payment. null if no payment is in progress.