import { TpyKV } from "https://deno.land/x/tpy@v1.0.0-pre-release-9/mod.ts";
A KVNamespace interface that (almost) matches the Pylon KVNamespace SDK class.
Constructors
Properties
Methods
Clears the namespace. Returning the number of keys deleted.
This operation will delete all the data in the namespace. The data is irrecoverably deleted.
Use with caution!
Deletes a given key from the namespace. Throwing if the key does not exist,
or if options.prevValue
is set the previous value is not equal to the
value provided.
Gets a key's value - returning the value or undefined.
Gets a key's value - returning the value or undefined.
Lists the keys and values in a namespace, including their expiration date if applicable.
The maximum limit is 100, however.
Sets the value of a given key within the key-value store.
Sets the value of a given key within the key-value store.