Developer docs / Android SDK
API and integration guide · Updated 2026-09-23
Android states and errors
Every public state field and enum value. Branch on machine codes; display the localized message.
| Field / API | Type / default | Contract |
|---|
| deviceId | String · required | Server device UUID; display/log identifier, not a secret. |
| deviceCode | String · required | Code for dashboard pairing; available after registration. Do not infer format or validity from length. |
| Field / API | Type / default | Contract |
|---|
| phase | SupportPhase · IDLE | Lifecycle phase; enum values are listed below. |
| device | DeviceRegistration? · null | Registration snapshot. May remain populated after stop/error; not online status. |
| controlAvailable | Boolean · false | Accessibility service availability at the state update. |
| stopReason | StopReason? · null | Reason for the latest stop transition, otherwise null. |
| error | SupportError? · null | Sanitized error category, otherwise null. Never contains raw HTTP/token/SDP. |
| isActive | Boolean · computed | true in AWAITING_CONSENT, STARTING, WAITING_FOR_OPERATOR, CONNECTING, CONNECTED, RECONNECTING, STOPPING. REGISTERING is false. |
| Field / API | Type / default | Contract |
|---|
| support | SupportState · required | Underlying state; control availability is refreshed by the launcher. |
| message | String · required | Display-ready status or preparation error in en/ko/ja. Do not parse this text for logic. |
| isPreparing | Boolean · required | Registration/disclosure/permission preparation is in progress. |
| preparationError | SupportPreparationError? · required | null normally; recoverable failure opening settings/consent UI. A later start can retry. |
| canStart | Boolean · required | No preparation, active session or registration. start() additionally checks Activity RESUMED. |
| canStop | Boolean · required | Preparation, registration or an active support phase can be stopped. |
| deviceCode | String? · computed | support.device?.deviceCode; null before registration. |
| controlAvailable | Boolean · computed | Alias for support.controlAvailable. |
| Field / API | Type / default | Contract |
|---|
| IDLE | enum | Initialized, no active request. |
| REGISTERING | enum | Registering/authenticating the installation. |
| READY | enum | Registered; no sharing consent yet. |
| AWAITING_CONSENT | enum | Android capture consent is pending. |
| STARTING | enum | Foreground capture service starting. |
| WAITING_FOR_OPERATOR | enum | Approved sharing is waiting for an operator. |
| CONNECTING | enum | Peer negotiation in progress. |
| CONNECTED | enum | Authenticated peer connected. |
| RECONNECTING | enum | Connection recovery in progress; consent is retained. |
| STOPPING | enum | Explicit shutdown in progress. |
| STOPPED | enum | Sharing has stopped; inspect stopReason. |
| ERROR | enum | Failure; inspect error and optionally stopReason. |
| Field / API | Type / default | Contract |
|---|
| USER | enum | Host/person stopped support. |
| OPERATOR | enum | Remote operator ended support. |
| SYSTEM | enum | Android revoked capture or stopped service. |
| TIMEOUT | enum | Configured session lifetime expired. |
| PERMISSION_DENIED | enum | Capture consent denied/invalid or Activity unavailable. |
| ERROR | enum | Failure stopped support/preparation. |
| Field / API | Type / default | Contract |
|---|
| REGISTRATION_FAILED | enum | Registration/auth bootstrap failed; check config and connectivity, then retry. |
| AUTHENTICATION_FAILED | enum | Session/device authentication failed; inspect registration and account access. |
| NETWORK_UNAVAILABLE | enum | Network failure category; inspect connectivity. |
| CAPTURE_FAILED | enum | Screen capture could not be started/maintained; request fresh consent. |
| CONNECTION_FAILED | enum | Peer connection failure category; inspect signaling/TURN. |
| SERVICE_START_FAILED | enum | Android rejected foreground service start; use a visible Activity. |
| Field / API | Type / default | Contract |
|---|
| ACCEPTED | enum | Preparation accepted; not a connection guarantee. |
| ALREADY_ACTIVE | enum | Support is already active. |
| BUSY | enum | Preparation/registration already pending. |
| HOST_NOT_RESUMED | enum | Activity is not RESUMED, is finishing or destroyed. |
| Field / API | Type / default | Contract |
|---|
| SETTINGS_UNAVAILABLE | enum | Could not launch accessibility settings. |
| CAPTURE_CONSENT_UNAVAILABLE | enum | Could not launch Android capture consent. |