@upstash/redis 1.35.0-canary → 1.35.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{dist/chunk-Q4ZBDYYE.mjs → chunk-AIBLSL5D.mjs} +782 -89
- package/cloudflare.d.mts +55 -0
- package/cloudflare.d.ts +55 -0
- package/{dist/cloudflare.js → cloudflare.js} +796 -111
- package/{dist/cloudflare.mjs → cloudflare.mjs} +15 -13
- package/fastly.d.mts +48 -0
- package/fastly.d.ts +48 -0
- package/{dist/fastly.js → fastly.js} +792 -107
- package/{dist/fastly.mjs → fastly.mjs} +11 -9
- package/nodejs.d.mts +73 -0
- package/nodejs.d.ts +73 -0
- package/{dist/nodejs.js → nodejs.js} +799 -113
- package/{dist/nodejs.mjs → nodejs.mjs} +18 -15
- package/package.json +1 -1
- package/{dist/zmscore-BhX8yEQc.d.mts → zmscore-BshEAkn7.d.mts} +591 -46
- package/{dist/zmscore-BhX8yEQc.d.ts → zmscore-BshEAkn7.d.ts} +591 -46
- package/dist/cloudflare.d.mts +0 -55
- package/dist/cloudflare.d.ts +0 -55
- package/dist/fastly.d.mts +0 -48
- package/dist/fastly.d.ts +0 -48
- package/dist/nodejs.d.mts +0 -73
- package/dist/nodejs.d.ts +0 -73
package/cloudflare.d.mts
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { H as HttpClientConfig, R as RedisOptions, a as RequesterConfig, b as Redis$1 } from './zmscore-BshEAkn7.mjs';
|
|
2
|
+
export { A as AppendCommand, B as BitCountCommand, f as BitOpCommand, g as BitPosCommand, C as CopyCommand, D as DBSizeCommand, i as DecrByCommand, h as DecrCommand, j as DelCommand, E as EchoCommand, l as EvalCommand, k as EvalROCommand, n as EvalshaCommand, m as EvalshaROCommand, o as ExistsCommand, r as ExpireAtCommand, p as ExpireCommand, q as ExpireOption, F as FlushAllCommand, s as FlushDBCommand, G as GeoAddCommand, t as GeoAddCommandOptions, v as GeoDistCommand, w as GeoHashCommand, u as GeoMember, x as GeoPosCommand, y as GeoSearchCommand, z as GeoSearchStoreCommand, J as GetBitCommand, I as GetCommand, K as GetDelCommand, L as GetExCommand, M as GetRangeCommand, N as GetSetCommand, O as HDelCommand, Q as HExistsCommand, T as HExpireAtCommand, S as HExpireCommand, V as HExpireTimeCommand, a1 as HGetAllCommand, a0 as HGetCommand, a2 as HIncrByCommand, a3 as HIncrByFloatCommand, a4 as HKeysCommand, a5 as HLenCommand, a6 as HMGetCommand, a7 as HMSetCommand, Y as HPExpireAtCommand, X as HPExpireCommand, Z as HPExpireTimeCommand, _ as HPTtlCommand, $ as HPersistCommand, a8 as HRandFieldCommand, a9 as HScanCommand, aa as HSetCommand, ab as HSetNXCommand, ac as HStrLenCommand, W as HTtlCommand, ad as HValsCommand, af as IncrByCommand, ag as IncrByFloatCommand, ae as IncrCommand, ah as JsonArrAppendCommand, ai as JsonArrIndexCommand, aj as JsonArrInsertCommand, ak as JsonArrLenCommand, al as JsonArrPopCommand, am as JsonArrTrimCommand, an as JsonClearCommand, ao as JsonDelCommand, ap as JsonForgetCommand, aq as JsonGetCommand, as as JsonMGetCommand, ar as JsonMergeCommand, at as JsonNumIncrByCommand, au as JsonNumMultByCommand, av as JsonObjKeysCommand, aw as JsonObjLenCommand, ax as JsonRespCommand, ay as JsonSetCommand, az as JsonStrAppendCommand, aA as JsonStrLenCommand, aB as JsonToggleCommand, aC as JsonTypeCommand, aD as KeysCommand, aE as LIndexCommand, aF as LInsertCommand, aG as LLenCommand, aH as LMoveCommand, aI as LPopCommand, aJ as LPushCommand, aK as LPushXCommand, aL as LRangeCommand, aM as LRemCommand, aN as LSetCommand, aO as LTrimCommand, aP as MGetCommand, aQ as MSetCommand, aR as MSetNXCommand, aU as PExpireAtCommand, aT as PExpireCommand, aW as PSetEXCommand, aX as PTtlCommand, aS as PersistCommand, aV as PingCommand, P as Pipeline, aY as PublishCommand, b0 as RPopCommand, b1 as RPushCommand, b2 as RPushXCommand, aZ as RandomKeyCommand, a_ as RenameCommand, a$ as RenameNXCommand, d as Requester, b3 as SAddCommand, b6 as SCardCommand, ba as SDiffCommand, bb as SDiffStoreCommand, bi as SInterCommand, bj as SInterStoreCommand, bk as SIsMemberCommand, bm as SMIsMemberCommand, bl as SMembersCommand, bn as SMoveCommand, bo as SPopCommand, bp as SRandMemberCommand, bq as SRemCommand, br as SScanCommand, bt as SUnionCommand, bu as SUnionStoreCommand, b4 as ScanCommand, b5 as ScanCommandOptions, bD as ScoreMember, b7 as ScriptExistsCommand, b8 as ScriptFlushCommand, b9 as ScriptLoadCommand, be as SetBitCommand, bc as SetCommand, bd as SetCommandOptions, bf as SetExCommand, bg as SetNxCommand, bh as SetRangeCommand, bs as StrLenCommand, bv as TimeCommand, bw as TouchCommand, bx as TtlCommand, by as Type, bz as TypeCommand, bA as UnlinkCommand, U as UpstashRequest, c as UpstashResponse, bB as XAddCommand, bC as XRangeCommand, bF as ZAddCommand, bE as ZAddCommandOptions, bG as ZCardCommand, bH as ZCountCommand, bI as ZDiffStoreCommand, bJ as ZIncrByCommand, bK as ZInterStoreCommand, bL as ZInterStoreCommandOptions, bM as ZLexCountCommand, bN as ZMScoreCommand, bO as ZPopMaxCommand, bP as ZPopMinCommand, bQ as ZRangeCommand, bR as ZRangeCommandOptions, bS as ZRankCommand, bT as ZRemCommand, bU as ZRemRangeByLexCommand, bV as ZRemRangeByRankCommand, bW as ZRemRangeByScoreCommand, bX as ZRevRankCommand, bY as ZScanCommand, bZ as ZScoreCommand, b_ as ZUnionCommand, b$ as ZUnionCommandOptions, c0 as ZUnionStoreCommand, c1 as ZUnionStoreCommandOptions, e as errors } from './zmscore-BshEAkn7.mjs';
|
|
3
|
+
|
|
4
|
+
type Env = {
|
|
5
|
+
UPSTASH_DISABLE_TELEMETRY?: string;
|
|
6
|
+
};
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Connection credentials for upstash redis.
|
|
10
|
+
* Get them from https://console.upstash.com/redis/<uuid>
|
|
11
|
+
*/
|
|
12
|
+
type RedisConfigCloudflare = {
|
|
13
|
+
/**
|
|
14
|
+
* UPSTASH_REDIS_REST_URL
|
|
15
|
+
*/
|
|
16
|
+
url: string | undefined;
|
|
17
|
+
/**
|
|
18
|
+
* UPSTASH_REDIS_REST_TOKEN
|
|
19
|
+
*/
|
|
20
|
+
token: string | undefined;
|
|
21
|
+
/**
|
|
22
|
+
* The signal will allow aborting requests on the fly.
|
|
23
|
+
* For more check: https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal
|
|
24
|
+
*/
|
|
25
|
+
signal?: HttpClientConfig["signal"];
|
|
26
|
+
keepAlive?: boolean;
|
|
27
|
+
/**
|
|
28
|
+
* When this flag is enabled, any subsequent commands issued by this client are guaranteed to observe the effects of all earlier writes submitted by the same client.
|
|
29
|
+
*/
|
|
30
|
+
readYourWrites?: boolean;
|
|
31
|
+
} & RedisOptions & RequesterConfig & Env;
|
|
32
|
+
/**
|
|
33
|
+
* Serverless redis client for upstash.
|
|
34
|
+
*/
|
|
35
|
+
declare class Redis extends Redis$1 {
|
|
36
|
+
/**
|
|
37
|
+
* Create a new redis client
|
|
38
|
+
*
|
|
39
|
+
* @example
|
|
40
|
+
* ```typescript
|
|
41
|
+
* const redis = new Redis({
|
|
42
|
+
* url: "<UPSTASH_REDIS_REST_URL>",
|
|
43
|
+
* token: "<UPSTASH_REDIS_REST_TOKEN>",
|
|
44
|
+
* });
|
|
45
|
+
* ```
|
|
46
|
+
*/
|
|
47
|
+
constructor(config: RedisConfigCloudflare, env?: Env);
|
|
48
|
+
static fromEnv(env?: {
|
|
49
|
+
UPSTASH_REDIS_REST_URL: string;
|
|
50
|
+
UPSTASH_REDIS_REST_TOKEN: string;
|
|
51
|
+
UPSTASH_DISABLE_TELEMETRY?: string;
|
|
52
|
+
}, opts?: Omit<RedisConfigCloudflare, "url" | "token">): Redis;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export { Redis, type RedisConfigCloudflare };
|
package/cloudflare.d.ts
ADDED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { H as HttpClientConfig, R as RedisOptions, a as RequesterConfig, b as Redis$1 } from './zmscore-BshEAkn7.js';
|
|
2
|
+
export { A as AppendCommand, B as BitCountCommand, f as BitOpCommand, g as BitPosCommand, C as CopyCommand, D as DBSizeCommand, i as DecrByCommand, h as DecrCommand, j as DelCommand, E as EchoCommand, l as EvalCommand, k as EvalROCommand, n as EvalshaCommand, m as EvalshaROCommand, o as ExistsCommand, r as ExpireAtCommand, p as ExpireCommand, q as ExpireOption, F as FlushAllCommand, s as FlushDBCommand, G as GeoAddCommand, t as GeoAddCommandOptions, v as GeoDistCommand, w as GeoHashCommand, u as GeoMember, x as GeoPosCommand, y as GeoSearchCommand, z as GeoSearchStoreCommand, J as GetBitCommand, I as GetCommand, K as GetDelCommand, L as GetExCommand, M as GetRangeCommand, N as GetSetCommand, O as HDelCommand, Q as HExistsCommand, T as HExpireAtCommand, S as HExpireCommand, V as HExpireTimeCommand, a1 as HGetAllCommand, a0 as HGetCommand, a2 as HIncrByCommand, a3 as HIncrByFloatCommand, a4 as HKeysCommand, a5 as HLenCommand, a6 as HMGetCommand, a7 as HMSetCommand, Y as HPExpireAtCommand, X as HPExpireCommand, Z as HPExpireTimeCommand, _ as HPTtlCommand, $ as HPersistCommand, a8 as HRandFieldCommand, a9 as HScanCommand, aa as HSetCommand, ab as HSetNXCommand, ac as HStrLenCommand, W as HTtlCommand, ad as HValsCommand, af as IncrByCommand, ag as IncrByFloatCommand, ae as IncrCommand, ah as JsonArrAppendCommand, ai as JsonArrIndexCommand, aj as JsonArrInsertCommand, ak as JsonArrLenCommand, al as JsonArrPopCommand, am as JsonArrTrimCommand, an as JsonClearCommand, ao as JsonDelCommand, ap as JsonForgetCommand, aq as JsonGetCommand, as as JsonMGetCommand, ar as JsonMergeCommand, at as JsonNumIncrByCommand, au as JsonNumMultByCommand, av as JsonObjKeysCommand, aw as JsonObjLenCommand, ax as JsonRespCommand, ay as JsonSetCommand, az as JsonStrAppendCommand, aA as JsonStrLenCommand, aB as JsonToggleCommand, aC as JsonTypeCommand, aD as KeysCommand, aE as LIndexCommand, aF as LInsertCommand, aG as LLenCommand, aH as LMoveCommand, aI as LPopCommand, aJ as LPushCommand, aK as LPushXCommand, aL as LRangeCommand, aM as LRemCommand, aN as LSetCommand, aO as LTrimCommand, aP as MGetCommand, aQ as MSetCommand, aR as MSetNXCommand, aU as PExpireAtCommand, aT as PExpireCommand, aW as PSetEXCommand, aX as PTtlCommand, aS as PersistCommand, aV as PingCommand, P as Pipeline, aY as PublishCommand, b0 as RPopCommand, b1 as RPushCommand, b2 as RPushXCommand, aZ as RandomKeyCommand, a_ as RenameCommand, a$ as RenameNXCommand, d as Requester, b3 as SAddCommand, b6 as SCardCommand, ba as SDiffCommand, bb as SDiffStoreCommand, bi as SInterCommand, bj as SInterStoreCommand, bk as SIsMemberCommand, bm as SMIsMemberCommand, bl as SMembersCommand, bn as SMoveCommand, bo as SPopCommand, bp as SRandMemberCommand, bq as SRemCommand, br as SScanCommand, bt as SUnionCommand, bu as SUnionStoreCommand, b4 as ScanCommand, b5 as ScanCommandOptions, bD as ScoreMember, b7 as ScriptExistsCommand, b8 as ScriptFlushCommand, b9 as ScriptLoadCommand, be as SetBitCommand, bc as SetCommand, bd as SetCommandOptions, bf as SetExCommand, bg as SetNxCommand, bh as SetRangeCommand, bs as StrLenCommand, bv as TimeCommand, bw as TouchCommand, bx as TtlCommand, by as Type, bz as TypeCommand, bA as UnlinkCommand, U as UpstashRequest, c as UpstashResponse, bB as XAddCommand, bC as XRangeCommand, bF as ZAddCommand, bE as ZAddCommandOptions, bG as ZCardCommand, bH as ZCountCommand, bI as ZDiffStoreCommand, bJ as ZIncrByCommand, bK as ZInterStoreCommand, bL as ZInterStoreCommandOptions, bM as ZLexCountCommand, bN as ZMScoreCommand, bO as ZPopMaxCommand, bP as ZPopMinCommand, bQ as ZRangeCommand, bR as ZRangeCommandOptions, bS as ZRankCommand, bT as ZRemCommand, bU as ZRemRangeByLexCommand, bV as ZRemRangeByRankCommand, bW as ZRemRangeByScoreCommand, bX as ZRevRankCommand, bY as ZScanCommand, bZ as ZScoreCommand, b_ as ZUnionCommand, b$ as ZUnionCommandOptions, c0 as ZUnionStoreCommand, c1 as ZUnionStoreCommandOptions, e as errors } from './zmscore-BshEAkn7.js';
|
|
3
|
+
|
|
4
|
+
type Env = {
|
|
5
|
+
UPSTASH_DISABLE_TELEMETRY?: string;
|
|
6
|
+
};
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Connection credentials for upstash redis.
|
|
10
|
+
* Get them from https://console.upstash.com/redis/<uuid>
|
|
11
|
+
*/
|
|
12
|
+
type RedisConfigCloudflare = {
|
|
13
|
+
/**
|
|
14
|
+
* UPSTASH_REDIS_REST_URL
|
|
15
|
+
*/
|
|
16
|
+
url: string | undefined;
|
|
17
|
+
/**
|
|
18
|
+
* UPSTASH_REDIS_REST_TOKEN
|
|
19
|
+
*/
|
|
20
|
+
token: string | undefined;
|
|
21
|
+
/**
|
|
22
|
+
* The signal will allow aborting requests on the fly.
|
|
23
|
+
* For more check: https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal
|
|
24
|
+
*/
|
|
25
|
+
signal?: HttpClientConfig["signal"];
|
|
26
|
+
keepAlive?: boolean;
|
|
27
|
+
/**
|
|
28
|
+
* When this flag is enabled, any subsequent commands issued by this client are guaranteed to observe the effects of all earlier writes submitted by the same client.
|
|
29
|
+
*/
|
|
30
|
+
readYourWrites?: boolean;
|
|
31
|
+
} & RedisOptions & RequesterConfig & Env;
|
|
32
|
+
/**
|
|
33
|
+
* Serverless redis client for upstash.
|
|
34
|
+
*/
|
|
35
|
+
declare class Redis extends Redis$1 {
|
|
36
|
+
/**
|
|
37
|
+
* Create a new redis client
|
|
38
|
+
*
|
|
39
|
+
* @example
|
|
40
|
+
* ```typescript
|
|
41
|
+
* const redis = new Redis({
|
|
42
|
+
* url: "<UPSTASH_REDIS_REST_URL>",
|
|
43
|
+
* token: "<UPSTASH_REDIS_REST_TOKEN>",
|
|
44
|
+
* });
|
|
45
|
+
* ```
|
|
46
|
+
*/
|
|
47
|
+
constructor(config: RedisConfigCloudflare, env?: Env);
|
|
48
|
+
static fromEnv(env?: {
|
|
49
|
+
UPSTASH_REDIS_REST_URL: string;
|
|
50
|
+
UPSTASH_REDIS_REST_TOKEN: string;
|
|
51
|
+
UPSTASH_DISABLE_TELEMETRY?: string;
|
|
52
|
+
}, opts?: Omit<RedisConfigCloudflare, "url" | "token">): Redis;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export { Redis, type RedisConfigCloudflare };
|