Skip to main content
The AuthenticationToken class represents an authentication token received from iOS Limited Login. It wraps an OpenID Connect token that can be used to verify a user’s identity but cannot access the Graph API.
AuthenticationToken is iOS only and is used with Limited Login. For traditional login, use AccessToken instead.

Import

Static Methods

getAuthenticationTokenIOS

Retrieves the current authentication token (iOS only).

Returns

Promise<AuthenticationToken | null> - Resolves with an AuthenticationToken instance if Limited Login was used, or null otherwise. Platform: iOS only (returns null on Android)

Example

Checking Login Type

Instance Properties

authenticationToken

The raw OpenID Connect token string from the authentication response.
This token cannot be used to access the Facebook Graph API. Attempting to do so will result in an error: “Invalid OAuth access token - Cannot parse access token”

Example


nonce

The nonce from the decoded authentication response. Used for validating the authentication attempt.
The nonce is a unique string that prevents replay attacks. You should verify that this nonce matches the one you provided (or was generated) during login.

Example


graphDomain

The graph domain where the user is authenticated.
Typically this will be "facebook" for standard Facebook users.

Example

Types

AuthenticationTokenMap

Represents the raw authentication token data returned from the native SDK.

Server-Side Validation

Authentication Tokens must be validated on your server. Here’s how to implement it:

Client Side: Send Token to Server

Server Side: Validate Token (Node.js Example)

See Facebook’s validation documentation for complete details.

Complete Usage Example

Limitations

Important Limitations of Authentication Tokens:
  1. Cannot access Graph API - Authentication Tokens cannot be used to make Graph API requests
  2. iOS only - This feature is not available on Android
  3. Limited user data - You can only get basic profile information through the Profile API
  4. Server validation required - Tokens must be validated on your backend
  5. No permission scopes - Cannot request extended permissions like user_photos, user_posts, etc.

See Also

Limited Login

Learn about iOS Limited Login

AccessToken

Traditional login access tokens

Authentication Concepts

Understand authentication in React Native FBSDK

Login Methods

Different ways to implement Facebook Login