@upstash/redis 0.0.0-ci.9cbc6e25-20230504 → 0.0.0-ci.9d88b94d-20231018

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.
Files changed (38) hide show
  1. package/esm/pkg/commands/geo_add.js +27 -0
  2. package/esm/pkg/commands/geo_pos.js +26 -0
  3. package/esm/pkg/commands/hgetall.js +9 -1
  4. package/esm/pkg/commands/mod.js +5 -0
  5. package/esm/pkg/commands/set.js +1 -1
  6. package/esm/pkg/commands/xadd.js +26 -0
  7. package/esm/pkg/commands/xrange.js +36 -0
  8. package/esm/pkg/commands/zunion.js +30 -0
  9. package/esm/pkg/http.js +16 -9
  10. package/esm/pkg/pipeline.js +28 -8
  11. package/esm/pkg/redis.js +36 -1
  12. package/esm/platforms/nodejs.js +1 -1
  13. package/esm/version.js +1 -1
  14. package/package.json +13 -5
  15. package/script/pkg/commands/geo_add.js +31 -0
  16. package/script/pkg/commands/geo_pos.js +30 -0
  17. package/script/pkg/commands/hgetall.js +9 -1
  18. package/script/pkg/commands/mod.js +5 -0
  19. package/script/pkg/commands/set.js +1 -1
  20. package/script/pkg/commands/xadd.js +30 -0
  21. package/script/pkg/commands/xrange.js +40 -0
  22. package/script/pkg/commands/zunion.js +34 -0
  23. package/script/pkg/http.js +16 -9
  24. package/script/pkg/pipeline.js +27 -7
  25. package/script/pkg/redis.js +35 -0
  26. package/script/platforms/nodejs.js +1 -1
  27. package/script/version.js +1 -1
  28. package/types/pkg/commands/geo_add.d.ts +25 -0
  29. package/types/pkg/commands/geo_pos.d.ts +12 -0
  30. package/types/pkg/commands/mod.d.ts +5 -0
  31. package/types/pkg/commands/set.d.ts +2 -2
  32. package/types/pkg/commands/xadd.d.ts +31 -0
  33. package/types/pkg/commands/xrange.d.ts +9 -0
  34. package/types/pkg/commands/zunion.d.ts +29 -0
  35. package/types/pkg/http.d.ts +5 -1
  36. package/types/pkg/pipeline.d.ts +237 -150
  37. package/types/pkg/redis.d.ts +40 -3
  38. package/types/version.d.ts +1 -1
@@ -1,4 +1,4 @@
1
- import { CommandOptions, DelCommand, ExistsCommand, FlushAllCommand, JsonGetCommand, MGetCommand, PingCommand, ScoreMember, ScriptExistsCommand, SetCommandOptions, TouchCommand, UnlinkCommand, ZAddCommandOptions, ZAddCommandOptionsWithIncr, ZRangeCommandOptions } from "./commands/mod.js";
1
+ import { CommandOptions, DelCommand, ExistsCommand, FlushAllCommand, GeoPosCommand, JsonGetCommand, MGetCommand, PingCommand, ScoreMember, ScriptExistsCommand, SetCommandOptions, TouchCommand, UnlinkCommand, ZAddCommandOptions, ZAddCommandOptionsWithIncr, ZRangeCommandOptions } from "./commands/mod.js";
2
2
  import { Requester, UpstashRequest, UpstashResponse } from "./http.js";
3
3
  import { Pipeline } from "./pipeline.js";
4
4
  import type { CommandArgs } from "./types.js";
@@ -61,6 +61,14 @@ export declare class Redis {
61
61
  * @see https://redis.io/commands/json.forget
62
62
  */
63
63
  forget: (key: string, path?: string | undefined) => Promise<number>;
64
+ /**
65
+ * @see https://redis.io/commands/geoadd
66
+ */
67
+ geoadd: (args_0: string, args_1: import("./commands/geo_add.js").GeoAddCommandOptions | import("./commands/geo_add.js").GeoMember<unknown>, ...args_2: import("./commands/geo_add.js").GeoMember<unknown>[]) => Promise<number | null>;
68
+ /**
69
+ * @see https://redis.io/commands/geopos
70
+ */
71
+ geopos: (...args: CommandArgs<typeof GeoPosCommand>) => Promise<any>;
64
72
  /**
65
73
  * @see https://redis.io/commands/json.get
66
74
  */
@@ -130,7 +138,7 @@ export declare class Redis {
130
138
  *
131
139
  * @see {@link Pipeline}
132
140
  */
133
- pipeline: () => Pipeline;
141
+ pipeline: () => Pipeline<[]>;
134
142
  /**
135
143
  * Create a new transaction to allow executing multiple steps atomically.
136
144
  *
@@ -140,7 +148,7 @@ export declare class Redis {
140
148
  *
141
149
  * @see {@link Pipeline}
142
150
  */
143
- multi: () => Pipeline;
151
+ multi: () => Pipeline<[]>;
144
152
  /**
145
153
  * @see https://redis.io/commands/append
146
154
  */
@@ -562,6 +570,31 @@ export declare class Redis {
562
570
  * @see https://redis.io/commands/unlink
563
571
  */
564
572
  unlink: (...args: CommandArgs<typeof UnlinkCommand>) => Promise<number>;
573
+ /**
574
+ * @see https://redis.io/commands/xadd
575
+ */
576
+ xadd: (key: string, id: string, entries: {
577
+ [field: string]: unknown;
578
+ }, opts?: {
579
+ nomkStream?: boolean | undefined;
580
+ trim?: (({
581
+ type: "MAXLEN" | "maxlen";
582
+ threshold: number;
583
+ } | {
584
+ type: "MINID" | "minid";
585
+ threshold: string;
586
+ }) & ({
587
+ comparison: "~";
588
+ limit?: number | undefined;
589
+ } | {
590
+ comparison: "=";
591
+ limit?: undefined;
592
+ })) | undefined;
593
+ } | undefined) => Promise<string>;
594
+ /**
595
+ * @see https://redis.io/commands/xrange
596
+ */
597
+ xrange: (key: string, start: string, end: string, count?: number | undefined) => Promise<Record<string, Record<string, unknown>>>;
565
598
  /**
566
599
  * @see https://redis.io/commands/zadd
567
600
  */
@@ -652,6 +685,10 @@ export declare class Redis {
652
685
  * @see https://redis.io/commands/zscore
653
686
  */
654
687
  zscore: <TData>(key: string, member: TData) => Promise<number | null>;
688
+ /**
689
+ * @see https://redis.io/commands/zunion
690
+ */
691
+ zunion: (numKeys: number, keys: string[], opts?: import("./commands/zunion.js").ZUnionCommandOptions | undefined) => Promise<any>;
655
692
  /**
656
693
  * @see https://redis.io/commands/zunionstore
657
694
  */
@@ -1 +1 @@
1
- export declare const VERSION = "v0.0.0-ci.9cbc6e25-20230504";
1
+ export declare const VERSION = "v0.0.0-ci.9d88b94d-20231018";