# checkAgeSignals

open fun checkAgeSignals(@NonNull context: Context, @NonNull request: GamebaseAgeSignalsRequest, @NonNull callback: GamebaseDataCallback<GamebaseAgeSignalsResult>)

Requests age verification information from the Google Play Service.

This method retrieves the user's age range and verification status as required by Texas SB 2420 and similar state laws.

On Android, this uses Google Play Age Signals API (requires Android API 23+).

The callback will be invoked with:

- Success: GamebaseAgeSignalsResult containing age range and verification status
- Failure: GamebaseException with error code and message

Example Usage:

    GamebaseAgeSignalsRequest ageSignalRequest = GamebaseAgeSignalsRequest.newBuilder().build()
    Gamebase.AgeVerification.checkAgeSignals(context, ageSignalRequest, new GamebaseDataCallback<GamebaseAgeSignalsResult>() {
        @Override
        public void onCallback(GamebaseAgeSignalsRequest result, GamebaseException exception) {
            if (Gamebase.isSuccess(exception)) {
                // Process age verification result
            } else {
                // Handle error
                Log.e(TAG, "Failed to get age verification: " + exception.getMessage());
            }
        }
    });

Content copied to clipboard

#### Since

Added 2.76.0

#### Parameters

context

The current context (must not be null)

request

Age verification request parameters (must not be null)

callback

Callback to receive the age verification information or error (must not be null)

#### See also

GamebaseAgeSignalsRequest
GamebaseAgeSignalsResult