AniLink - v3.0.0
    Preparing search index...

    Function resolveCacheAuthKey

    • Computes the auth-scoping cache key for a cacheable request, or undefined when the request must not touch the cache.

      The cache applies only to cacheable reads with a configured cache: GET calls, and GraphQL query documents dispatched as POST (the AniList transport's only read shape: every GraphQL operation is a POST, so a GET-only gate would leave the cache inert for the primary provider). Mutations, GraphQL mutation documents and REST POST/PUT/DELETE calls, stay excluded. When effective credential headers are present but not captured by the cache key (for example a custom Authorization or X-API-Key header), buildCacheAuthKey returns undefined to fail closed: the cache is skipped entirely instead of risking a cross-identity disclosure.

      Parameters

      • cache: ResponseCache | undefined

        The configured response cache, or undefined when the request runs cache-less (the default).

      • method: string

        The HTTP method.

      • data: string | object | undefined

        The request body, when present.

      • isRestCall: boolean

        Whether the call resolved to the REST protocol; REST POST bodies are never treated as GraphQL query documents even when a body field is named query.

      • auth: CacheAuthFacts

        The resolved auth facts of the request.

      Returns string | undefined

      The cache key fragment, or undefined to skip the cache.