Skip to main content
Uplink provides specialized methods for waiting for users to complete authentication on their devices. Since real users log themselves in on real mobile devices, authentication flows work naturally.
The Uplink Advantage: Users authenticate themselves on their own devices. No credential management needed. Simply wait for the user to complete authentication, then automate the rest.

Methods

page.authenticate()

Navigates to a URL and waits for authentication to complete.
Parameters:
  • startURL: URL to navigate to for authentication
  • authEvaluator: Function that checks if authentication is complete
  • options (optional): Authentication options
AuthEvaluator:
Options:
Returns: Promise<AuthStatus> - Either 'authenticated' or 'aborted' Examples:

page.waitForAuthentication()

Waits for authentication to complete without navigating.
Parameters:
  • authEvaluator: Function that checks if authentication is complete
  • options (optional): Authentication options
Returns: Promise<AuthStatus> - Either 'authenticated' or 'aborted' Example:

Complete examples

OAuth flow

Social login

Two-factor authentication

Session-based authentication

Mobile app authentication

Best practices

With Uplink, users authenticate themselves on their own devices:
Authentication often requires user interaction, so use longer timeouts:
Verify authentication using multiple methods:
Always handle the aborted case:
Extract and store authentication tokens for later use:

Cookies

Manage authentication cookies

Waiting

Wait for authentication indicators

Navigation

Navigate to auth pages

Page overview

Back to Page API overview