Data Layer low complexity Shared Component mobile
1
Dependencies
2
Dependents
1
Entities
0
Integrations

Description

Secure persistent storage for JWT access and refresh tokens using Flutter Secure Storage, backed by iOS Keychain and Android Keystore. Passwords are never stored; only tokens are persisted. Provides typed read/write/delete operations for token lifecycle management.

Feature: Email & Password Login

token-storage

Responsibilities

  • Store JWT access token and refresh token using platform secure storage (Keychain/Keystore)
  • Retrieve stored tokens for injection into API request headers
  • Delete tokens on logout or session expiry
  • Provide synchronous availability check for token presence

Interfaces

saveTokens(String accessToken, String refreshToken) Future<void>
getAccessToken() Future<String?>
getRefreshToken() Future<String?>
deleteTokens() Future<void>
hasValidTokens() Future<bool>

Relationships

Dependencies (1)

Components this component depends on

Dependents (2)

Components that depend on this component

Related Data Entities (1)

Data entities managed by this component