Prerequisites: Visitor mode must be enabled for your network and the SDK must be logged in as a visitor before UIKit renders. See SDK Visitor Mode for login setup.
Tab Visibility
UIKit adjusts which tabs are visible based on user type. Visitors see a read-only subset of the navigation:| Tab | Visitor | Signed-In |
|---|---|---|
| Communities / Explore | ✅ Visible (default) | ✅ Visible |
| Events | ✅ Visible | ✅ Visible |
| Clips | Configurable (can_view_tab) | ✅ Visible |
| Newsfeed / Following | ❌ Hidden | ✅ Visible |
Restricted Action Handling
When a visitor attempts a write action (react, comment, reply, follow), UIKit shows a sign-in prompt by default. OverridehandleVisitorUserAction in AmityGlobalBehavior to navigate to your own sign-in screen instead.
- iOS
- Android
- TypeScript
Daily Usage Limit Page
When a visitor exceeds their 100 read requests/day quota, the backend returns error400323. UIKit automatically subscribes to the SDK’s visitorUsageLimitReached event and shows a full-screen VisitorUsageLimitPage that blocks further navigation until the user signs in.
Default Page
Back gestures and the system back button are disabled while the page is shown:
- Web: Navigation stack unmounted at root
- Android: Activity back stack cleared, back press swallowed
- iOS: Presented modally, swipe-back disabled
Platform Availability
| Platform | UIKit Version | Notes |
|---|---|---|
| Android | 4.18.0+ | AmityGlobalBehavior overrides available |
| iOS | 4.22.0+ | AmityGlobalBehavior overrides available |
| Web | 4.17.0+ | AmityGlobalBehavior overrides available |
Customizing the Error Page
Use two newAmityGlobalBehavior handlers to replace the default experience:
| Handler | Default behaviour | Override use case |
|---|---|---|
handleVisitorUsageLimitReached | Show VisitorUsageLimitPage full-screen | Show your own branded error UI |
handleVisitorUsageLimitSignIn | Show toast: “Create an account or sign in to continue.” | Navigate to your own sign-in screen |
- iOS
- Android
- TypeScript
The usage limit state is in-memory only. It resets automatically when the app restarts or when
registerDevice() is called with a signed-in userId. Never persist the state to local storage — this ensures users see the normal UI again after signing in or after the daily quota resets.Related
SDK Visitor Mode
Visitor login, device fingerprinting, secure mode, and SDK error codes
Error Handling
Full server error reference including 400323, 403999, 403998