kinetex - v1.0.0-rc.1
    Preparing search index...

    Function authLink

    • Auth link: injects an authorization header into every request.

      Parameters

      • getToken: () => string | Promise<string | null> | null

        Function that returns the token (sync or async). Return null to skip header injection.

      • scheme: string = "Bearer"

        Authorization scheme (default: "Bearer")

      Returns GraphQLLink

      A GraphQLLink that adds the authorization header