FoxHat
    FoxHat
    • 👋Introduction
    • 🌐Browser SDK
    • 🤖Android SDK
    • 😀Flutter SDK
    • 🍎Ios SDK (Soon!)
    • BackEnd APIs
      • Verify Token
        POST
      • Link
        POST

    🤖Android SDK

    Integrating FoxHat Android#

    This guide will explain how to integrate FoxHat AntiSpam into your Android application .

    Features#

    Emulator detection
    Rooting detection
    Detection of debugging activities
    Detection of frameworks (e.g., Frida, Xposed, Shadow)
    Secure Api

    Adding FoxHat to Your Project#

    INFO
    Download FoxHat.aar

    Step 1: Add the .aar File to Your Project#

    1.
    Copy the downloaded .aar file into the libs directory of your Android project.
    2.
    Open your build.gradle file (usually located in the app module) and add the following dependency:

    Initializing FoxHat#

    Once installed, the SDK needs to be configured using your Publishable Key, which can be found in the Dashboard .
    📌
    Emulator and Root Detection enabled by default

    Creating tokens#

    The SDK generates a token, which is a required field in the Risk and Filter APIs.
    📌
    It's recommended that you forward the request token as a request header to every request to your API, since then you won't need to update the app whenever you're adding new server-side calls to Castle. The default value of the header is X-FoxHat-Token, but you can specify the header name in the SDK configuration.

    Token Expiration#

    A new token value should to be generated for each request to your backend. A request token will expire after 60 seconds and should only be used during a single request to your backend. It's recommended that you implement the token generation as a client-side middleware which generates a new request token with each request to your backend.
    Modified at 8 months ago
    Previous
    🌐Browser SDK
    Next
    😀Flutter SDK
    Built with
    On this page
    Integrating FoxHat Android
    Features
    Adding FoxHat to Your Project
    Step 1: Add the .aar File to Your Project
    Initializing FoxHat
    Creating tokens
    Token Expiration