Skip to main content
Module

x/harmony/mod.ts>GatewayCache

An easy to use Discord API Library for Deno.
Latest
class GatewayCache
import { GatewayCache } from "https://deno.land/x/harmony@v2.9.0/mod.ts";

Cache Manager used for Caching values related to Gateway connection

In case of Redis, this will persistently cache session ID and seq for fast resumes.

Constructors

new
GatewayCache(client: Client, cacheName?: string)

Properties

cacheName: string
client: Client

Methods

delete(key: string): Promise<boolean>
get<T>(key: string): Promise<undefined | T>
set<T>(key: string, value: T): Promise<void>