AniLink - v3.0.0
    Preparing search index...

    Function getRateLimitInfo

    • Parses the x-ratelimit-limit, x-ratelimit-remaining, and x-ratelimit-reset response headers into a RateLimitInfo.

      Returns undefined unless all three values are present and finite, so a partial or malformed header set reads as no rate-limit information rather than half-accounted quota.

      Parameters

      • headers: Record<string, unknown> | undefined

        The response headers, when available.

      Returns RateLimitInfo | undefined

      The parsed rate-limit accounting, or undefined when the required headers are missing or non-numeric.