Skip to main content

Overview

Errors in SeamSDK fall into two categories:
  • SeamError — Thrown for SDK initialization, configuration, or API-level failures (for example, invalid token or no network).
  • SeamCredentialError — Returned when a specific credential has an issue (for example, expired, unsupported device, or user action required).
Handling both types ensures your app can provide resilient, user-friendly access flows.
SeamComponents includes a complete reference implementation that presents UI and messaging for all SeamError and SeamCredentialError cases. You can use it as a guide or drop it in directly. See UI Components.

SeamError Cases


SeamCredentialError Cases


Resolving Required User Interactions

When you encounter .userInteractionRequired(let action), inspect the action to guide the user: Example:

Handling Errors in Code

Using Combine

Using async/await

Generic Helper Function


Best Practices

  • Map errors to UI states — Show loading, success, or error screens based on the error type.
  • Provide actionable feedback — For credential expiration, guide the user to renew or reissue their credential.
  • Check credentials before unlocking — If unlock(using:) would throw .credentialErrors([...]), present the top error to the user and wait until it is resolved before attempting the unlock.

See Also

  • Quickstart — How to initialize SeamSDK and perform your first unlock.
  • Architecture — How SeamSDK integrates with your app, cloud services, and hardware.
  • UI Components — SeamComponents handles error presentation automatically.