@upstash/redis 0.0.0-ci.eb0d57e1-20231019 → 0.0.0-ci.ec86feafac6d95eed4e9c9d8a5ff13b74ed84a74-20240709145745

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 (512) hide show
  1. package/README.md +17 -5
  2. package/chunk-PXDAFHKP.js +1 -0
  3. package/chunk-SGK6FTNU.mjs +1 -0
  4. package/cloudflare.d.mts +51 -0
  5. package/cloudflare.d.ts +51 -0
  6. package/cloudflare.js +1 -0
  7. package/cloudflare.mjs +1 -0
  8. package/fastly.d.mts +44 -0
  9. package/fastly.d.ts +44 -0
  10. package/fastly.js +1 -0
  11. package/fastly.mjs +1 -0
  12. package/nodejs.d.mts +87 -0
  13. package/nodejs.d.ts +87 -0
  14. package/nodejs.js +1 -0
  15. package/nodejs.mjs +1 -0
  16. package/package.json +1 -96
  17. package/zmscore-09122379.d.ts +3522 -0
  18. package/.releaserc +0 -14
  19. package/esm/deps/deno.land/x/base64@v0.2.1/base.js +0 -100
  20. package/esm/deps/deno.land/x/base64@v0.2.1/base64url.js +0 -9
  21. package/esm/deps/deno.land/x/sha1@v1.0.3/deps.js +0 -1
  22. package/esm/deps/deno.land/x/sha1@v1.0.3/mod.js +0 -191
  23. package/esm/deps/denopkg.com/chiefbiiko/std-encoding@v1.0.0/mod.js +0 -50
  24. package/esm/package.json +0 -3
  25. package/esm/pkg/commands/append.js +0 -9
  26. package/esm/pkg/commands/bitcount.js +0 -16
  27. package/esm/pkg/commands/bitop.js +0 -9
  28. package/esm/pkg/commands/bitpos.js +0 -9
  29. package/esm/pkg/commands/command.js +0 -66
  30. package/esm/pkg/commands/dbsize.js +0 -9
  31. package/esm/pkg/commands/decr.js +0 -9
  32. package/esm/pkg/commands/decrby.js +0 -9
  33. package/esm/pkg/commands/del.js +0 -9
  34. package/esm/pkg/commands/echo.js +0 -9
  35. package/esm/pkg/commands/eval.js +0 -9
  36. package/esm/pkg/commands/evalsha.js +0 -9
  37. package/esm/pkg/commands/exists.js +0 -9
  38. package/esm/pkg/commands/expire.js +0 -9
  39. package/esm/pkg/commands/expireat.js +0 -9
  40. package/esm/pkg/commands/flushall.js +0 -13
  41. package/esm/pkg/commands/flushdb.js +0 -13
  42. package/esm/pkg/commands/geo_add.js +0 -27
  43. package/esm/pkg/commands/get.js +0 -9
  44. package/esm/pkg/commands/getbit.js +0 -9
  45. package/esm/pkg/commands/getdel.js +0 -9
  46. package/esm/pkg/commands/getrange.js +0 -9
  47. package/esm/pkg/commands/getset.js +0 -9
  48. package/esm/pkg/commands/hdel.js +0 -9
  49. package/esm/pkg/commands/hexists.js +0 -9
  50. package/esm/pkg/commands/hget.js +0 -9
  51. package/esm/pkg/commands/hgetall.js +0 -37
  52. package/esm/pkg/commands/hincrby.js +0 -9
  53. package/esm/pkg/commands/hincrbyfloat.js +0 -9
  54. package/esm/pkg/commands/hkeys.js +0 -9
  55. package/esm/pkg/commands/hlen.js +0 -9
  56. package/esm/pkg/commands/hmget.js +0 -35
  57. package/esm/pkg/commands/hmset.js +0 -13
  58. package/esm/pkg/commands/hrandfield.js +0 -39
  59. package/esm/pkg/commands/hscan.js +0 -16
  60. package/esm/pkg/commands/hset.js +0 -13
  61. package/esm/pkg/commands/hsetnx.js +0 -9
  62. package/esm/pkg/commands/hstrlen.js +0 -9
  63. package/esm/pkg/commands/hvals.js +0 -9
  64. package/esm/pkg/commands/incr.js +0 -9
  65. package/esm/pkg/commands/incrby.js +0 -9
  66. package/esm/pkg/commands/incrbyfloat.js +0 -9
  67. package/esm/pkg/commands/json_arrappend.js +0 -9
  68. package/esm/pkg/commands/json_arrindex.js +0 -9
  69. package/esm/pkg/commands/json_arrinsert.js +0 -9
  70. package/esm/pkg/commands/json_arrlen.js +0 -9
  71. package/esm/pkg/commands/json_arrpop.js +0 -9
  72. package/esm/pkg/commands/json_arrtrim.js +0 -12
  73. package/esm/pkg/commands/json_clear.js +0 -9
  74. package/esm/pkg/commands/json_del.js +0 -9
  75. package/esm/pkg/commands/json_forget.js +0 -9
  76. package/esm/pkg/commands/json_get.js +0 -30
  77. package/esm/pkg/commands/json_mget.js +0 -9
  78. package/esm/pkg/commands/json_numincrby.js +0 -9
  79. package/esm/pkg/commands/json_nummultby.js +0 -9
  80. package/esm/pkg/commands/json_objkeys.js +0 -9
  81. package/esm/pkg/commands/json_objlen.js +0 -9
  82. package/esm/pkg/commands/json_resp.js +0 -9
  83. package/esm/pkg/commands/json_set.js +0 -18
  84. package/esm/pkg/commands/json_strappend.js +0 -9
  85. package/esm/pkg/commands/json_strlen.js +0 -9
  86. package/esm/pkg/commands/json_toggle.js +0 -9
  87. package/esm/pkg/commands/json_type.js +0 -9
  88. package/esm/pkg/commands/keys.js +0 -9
  89. package/esm/pkg/commands/lindex.js +0 -6
  90. package/esm/pkg/commands/linsert.js +0 -6
  91. package/esm/pkg/commands/llen.js +0 -9
  92. package/esm/pkg/commands/lmove.js +0 -9
  93. package/esm/pkg/commands/lpop.js +0 -9
  94. package/esm/pkg/commands/lpos.js +0 -19
  95. package/esm/pkg/commands/lpush.js +0 -9
  96. package/esm/pkg/commands/lpushx.js +0 -9
  97. package/esm/pkg/commands/lrange.js +0 -6
  98. package/esm/pkg/commands/lrem.js +0 -6
  99. package/esm/pkg/commands/lset.js +0 -6
  100. package/esm/pkg/commands/ltrim.js +0 -6
  101. package/esm/pkg/commands/mget.js +0 -12
  102. package/esm/pkg/commands/mod.js +0 -144
  103. package/esm/pkg/commands/mset.js +0 -12
  104. package/esm/pkg/commands/msetnx.js +0 -9
  105. package/esm/pkg/commands/persist.js +0 -9
  106. package/esm/pkg/commands/pexpire.js +0 -9
  107. package/esm/pkg/commands/pexpireat.js +0 -9
  108. package/esm/pkg/commands/ping.js +0 -13
  109. package/esm/pkg/commands/psetex.js +0 -9
  110. package/esm/pkg/commands/pttl.js +0 -9
  111. package/esm/pkg/commands/publish.js +0 -9
  112. package/esm/pkg/commands/randomkey.js +0 -9
  113. package/esm/pkg/commands/rename.js +0 -9
  114. package/esm/pkg/commands/renamenx.js +0 -9
  115. package/esm/pkg/commands/rpop.js +0 -9
  116. package/esm/pkg/commands/rpush.js +0 -9
  117. package/esm/pkg/commands/rpushx.js +0 -9
  118. package/esm/pkg/commands/sadd.js +0 -9
  119. package/esm/pkg/commands/scan.js +0 -19
  120. package/esm/pkg/commands/scard.js +0 -9
  121. package/esm/pkg/commands/script_exists.js +0 -12
  122. package/esm/pkg/commands/script_flush.js +0 -16
  123. package/esm/pkg/commands/script_load.js +0 -9
  124. package/esm/pkg/commands/sdiff.js +0 -9
  125. package/esm/pkg/commands/sdiffstore.js +0 -9
  126. package/esm/pkg/commands/set.js +0 -36
  127. package/esm/pkg/commands/setbit.js +0 -9
  128. package/esm/pkg/commands/setex.js +0 -9
  129. package/esm/pkg/commands/setnx.js +0 -9
  130. package/esm/pkg/commands/setrange.js +0 -9
  131. package/esm/pkg/commands/sinter.js +0 -9
  132. package/esm/pkg/commands/sinterstore.js +0 -9
  133. package/esm/pkg/commands/sismember.js +0 -9
  134. package/esm/pkg/commands/smembers.js +0 -9
  135. package/esm/pkg/commands/smismember.js +0 -9
  136. package/esm/pkg/commands/smove.js +0 -9
  137. package/esm/pkg/commands/spop.js +0 -13
  138. package/esm/pkg/commands/srandmember.js +0 -13
  139. package/esm/pkg/commands/srem.js +0 -9
  140. package/esm/pkg/commands/sscan.js +0 -16
  141. package/esm/pkg/commands/strlen.js +0 -9
  142. package/esm/pkg/commands/sunion.js +0 -9
  143. package/esm/pkg/commands/sunionstore.js +0 -9
  144. package/esm/pkg/commands/time.js +0 -9
  145. package/esm/pkg/commands/touch.js +0 -9
  146. package/esm/pkg/commands/ttl.js +0 -9
  147. package/esm/pkg/commands/type.js +0 -9
  148. package/esm/pkg/commands/unlink.js +0 -9
  149. package/esm/pkg/commands/xadd.js +0 -26
  150. package/esm/pkg/commands/xrange.js +0 -36
  151. package/esm/pkg/commands/zadd.js +0 -26
  152. package/esm/pkg/commands/zcard.js +0 -9
  153. package/esm/pkg/commands/zcount.js +0 -9
  154. package/esm/pkg/commands/zdiffstore.js +0 -9
  155. package/esm/pkg/commands/zincrby.js +0 -9
  156. package/esm/pkg/commands/zinterstore.js +0 -27
  157. package/esm/pkg/commands/zlexcount.js +0 -9
  158. package/esm/pkg/commands/zmscore.js +0 -10
  159. package/esm/pkg/commands/zpopmax.js +0 -13
  160. package/esm/pkg/commands/zpopmin.js +0 -13
  161. package/esm/pkg/commands/zrange.js +0 -26
  162. package/esm/pkg/commands/zrank.js +0 -9
  163. package/esm/pkg/commands/zrem.js +0 -9
  164. package/esm/pkg/commands/zremrangebylex.js +0 -9
  165. package/esm/pkg/commands/zremrangebyrank.js +0 -9
  166. package/esm/pkg/commands/zremrangebyscore.js +0 -9
  167. package/esm/pkg/commands/zrevrank.js +0 -9
  168. package/esm/pkg/commands/zscan.js +0 -16
  169. package/esm/pkg/commands/zscore.js +0 -9
  170. package/esm/pkg/commands/zunion.js +0 -30
  171. package/esm/pkg/commands/zunionstore.js +0 -27
  172. package/esm/pkg/error.js +0 -9
  173. package/esm/pkg/http.js +0 -174
  174. package/esm/pkg/pipeline.js +0 -1307
  175. package/esm/pkg/redis.js +0 -1319
  176. package/esm/pkg/script.js +0 -77
  177. package/esm/pkg/types.js +0 -1
  178. package/esm/pkg/util.js +0 -31
  179. package/esm/platforms/cloudflare.js +0 -70
  180. package/esm/platforms/fastly.js +0 -46
  181. package/esm/platforms/node_with_fetch.js +0 -85
  182. package/esm/platforms/nodejs.js +0 -82
  183. package/esm/version.js +0 -1
  184. package/script/deps/deno.land/x/base64@v0.2.1/base.js +0 -104
  185. package/script/deps/deno.land/x/base64@v0.2.1/base64url.js +0 -13
  186. package/script/deps/deno.land/x/sha1@v1.0.3/deps.js +0 -6
  187. package/script/deps/deno.land/x/sha1@v1.0.3/mod.js +0 -196
  188. package/script/deps/denopkg.com/chiefbiiko/std-encoding@v1.0.0/mod.js +0 -55
  189. package/script/package.json +0 -3
  190. package/script/pkg/commands/append.js +0 -13
  191. package/script/pkg/commands/bitcount.js +0 -20
  192. package/script/pkg/commands/bitop.js +0 -13
  193. package/script/pkg/commands/bitpos.js +0 -13
  194. package/script/pkg/commands/command.js +0 -70
  195. package/script/pkg/commands/dbsize.js +0 -13
  196. package/script/pkg/commands/decr.js +0 -13
  197. package/script/pkg/commands/decrby.js +0 -13
  198. package/script/pkg/commands/del.js +0 -13
  199. package/script/pkg/commands/echo.js +0 -13
  200. package/script/pkg/commands/eval.js +0 -13
  201. package/script/pkg/commands/evalsha.js +0 -13
  202. package/script/pkg/commands/exists.js +0 -13
  203. package/script/pkg/commands/expire.js +0 -13
  204. package/script/pkg/commands/expireat.js +0 -13
  205. package/script/pkg/commands/flushall.js +0 -17
  206. package/script/pkg/commands/flushdb.js +0 -17
  207. package/script/pkg/commands/geo_add.js +0 -31
  208. package/script/pkg/commands/get.js +0 -13
  209. package/script/pkg/commands/getbit.js +0 -13
  210. package/script/pkg/commands/getdel.js +0 -13
  211. package/script/pkg/commands/getrange.js +0 -13
  212. package/script/pkg/commands/getset.js +0 -13
  213. package/script/pkg/commands/hdel.js +0 -13
  214. package/script/pkg/commands/hexists.js +0 -13
  215. package/script/pkg/commands/hget.js +0 -13
  216. package/script/pkg/commands/hgetall.js +0 -41
  217. package/script/pkg/commands/hincrby.js +0 -13
  218. package/script/pkg/commands/hincrbyfloat.js +0 -13
  219. package/script/pkg/commands/hkeys.js +0 -13
  220. package/script/pkg/commands/hlen.js +0 -13
  221. package/script/pkg/commands/hmget.js +0 -39
  222. package/script/pkg/commands/hmset.js +0 -17
  223. package/script/pkg/commands/hrandfield.js +0 -43
  224. package/script/pkg/commands/hscan.js +0 -20
  225. package/script/pkg/commands/hset.js +0 -17
  226. package/script/pkg/commands/hsetnx.js +0 -13
  227. package/script/pkg/commands/hstrlen.js +0 -13
  228. package/script/pkg/commands/hvals.js +0 -13
  229. package/script/pkg/commands/incr.js +0 -13
  230. package/script/pkg/commands/incrby.js +0 -13
  231. package/script/pkg/commands/incrbyfloat.js +0 -13
  232. package/script/pkg/commands/json_arrappend.js +0 -13
  233. package/script/pkg/commands/json_arrindex.js +0 -13
  234. package/script/pkg/commands/json_arrinsert.js +0 -13
  235. package/script/pkg/commands/json_arrlen.js +0 -13
  236. package/script/pkg/commands/json_arrpop.js +0 -13
  237. package/script/pkg/commands/json_arrtrim.js +0 -16
  238. package/script/pkg/commands/json_clear.js +0 -13
  239. package/script/pkg/commands/json_del.js +0 -13
  240. package/script/pkg/commands/json_forget.js +0 -13
  241. package/script/pkg/commands/json_get.js +0 -34
  242. package/script/pkg/commands/json_mget.js +0 -13
  243. package/script/pkg/commands/json_numincrby.js +0 -13
  244. package/script/pkg/commands/json_nummultby.js +0 -13
  245. package/script/pkg/commands/json_objkeys.js +0 -13
  246. package/script/pkg/commands/json_objlen.js +0 -13
  247. package/script/pkg/commands/json_resp.js +0 -13
  248. package/script/pkg/commands/json_set.js +0 -22
  249. package/script/pkg/commands/json_strappend.js +0 -13
  250. package/script/pkg/commands/json_strlen.js +0 -13
  251. package/script/pkg/commands/json_toggle.js +0 -13
  252. package/script/pkg/commands/json_type.js +0 -13
  253. package/script/pkg/commands/keys.js +0 -13
  254. package/script/pkg/commands/lindex.js +0 -10
  255. package/script/pkg/commands/linsert.js +0 -10
  256. package/script/pkg/commands/llen.js +0 -13
  257. package/script/pkg/commands/lmove.js +0 -13
  258. package/script/pkg/commands/lpop.js +0 -13
  259. package/script/pkg/commands/lpos.js +0 -23
  260. package/script/pkg/commands/lpush.js +0 -13
  261. package/script/pkg/commands/lpushx.js +0 -13
  262. package/script/pkg/commands/lrange.js +0 -10
  263. package/script/pkg/commands/lrem.js +0 -10
  264. package/script/pkg/commands/lset.js +0 -10
  265. package/script/pkg/commands/ltrim.js +0 -10
  266. package/script/pkg/commands/mget.js +0 -16
  267. package/script/pkg/commands/mod.js +0 -160
  268. package/script/pkg/commands/mset.js +0 -16
  269. package/script/pkg/commands/msetnx.js +0 -13
  270. package/script/pkg/commands/persist.js +0 -13
  271. package/script/pkg/commands/pexpire.js +0 -13
  272. package/script/pkg/commands/pexpireat.js +0 -13
  273. package/script/pkg/commands/ping.js +0 -17
  274. package/script/pkg/commands/psetex.js +0 -13
  275. package/script/pkg/commands/pttl.js +0 -13
  276. package/script/pkg/commands/publish.js +0 -13
  277. package/script/pkg/commands/randomkey.js +0 -13
  278. package/script/pkg/commands/rename.js +0 -13
  279. package/script/pkg/commands/renamenx.js +0 -13
  280. package/script/pkg/commands/rpop.js +0 -13
  281. package/script/pkg/commands/rpush.js +0 -13
  282. package/script/pkg/commands/rpushx.js +0 -13
  283. package/script/pkg/commands/sadd.js +0 -13
  284. package/script/pkg/commands/scan.js +0 -23
  285. package/script/pkg/commands/scard.js +0 -13
  286. package/script/pkg/commands/script_exists.js +0 -16
  287. package/script/pkg/commands/script_flush.js +0 -20
  288. package/script/pkg/commands/script_load.js +0 -13
  289. package/script/pkg/commands/sdiff.js +0 -13
  290. package/script/pkg/commands/sdiffstore.js +0 -13
  291. package/script/pkg/commands/set.js +0 -40
  292. package/script/pkg/commands/setbit.js +0 -13
  293. package/script/pkg/commands/setex.js +0 -13
  294. package/script/pkg/commands/setnx.js +0 -13
  295. package/script/pkg/commands/setrange.js +0 -13
  296. package/script/pkg/commands/sinter.js +0 -13
  297. package/script/pkg/commands/sinterstore.js +0 -13
  298. package/script/pkg/commands/sismember.js +0 -13
  299. package/script/pkg/commands/smembers.js +0 -13
  300. package/script/pkg/commands/smismember.js +0 -13
  301. package/script/pkg/commands/smove.js +0 -13
  302. package/script/pkg/commands/spop.js +0 -17
  303. package/script/pkg/commands/srandmember.js +0 -17
  304. package/script/pkg/commands/srem.js +0 -13
  305. package/script/pkg/commands/sscan.js +0 -20
  306. package/script/pkg/commands/strlen.js +0 -13
  307. package/script/pkg/commands/sunion.js +0 -13
  308. package/script/pkg/commands/sunionstore.js +0 -13
  309. package/script/pkg/commands/time.js +0 -13
  310. package/script/pkg/commands/touch.js +0 -13
  311. package/script/pkg/commands/ttl.js +0 -13
  312. package/script/pkg/commands/type.js +0 -13
  313. package/script/pkg/commands/unlink.js +0 -13
  314. package/script/pkg/commands/xadd.js +0 -30
  315. package/script/pkg/commands/xrange.js +0 -40
  316. package/script/pkg/commands/zadd.js +0 -30
  317. package/script/pkg/commands/zcard.js +0 -13
  318. package/script/pkg/commands/zcount.js +0 -13
  319. package/script/pkg/commands/zdiffstore.js +0 -13
  320. package/script/pkg/commands/zincrby.js +0 -13
  321. package/script/pkg/commands/zinterstore.js +0 -31
  322. package/script/pkg/commands/zlexcount.js +0 -13
  323. package/script/pkg/commands/zmscore.js +0 -14
  324. package/script/pkg/commands/zpopmax.js +0 -17
  325. package/script/pkg/commands/zpopmin.js +0 -17
  326. package/script/pkg/commands/zrange.js +0 -30
  327. package/script/pkg/commands/zrank.js +0 -13
  328. package/script/pkg/commands/zrem.js +0 -13
  329. package/script/pkg/commands/zremrangebylex.js +0 -13
  330. package/script/pkg/commands/zremrangebyrank.js +0 -13
  331. package/script/pkg/commands/zremrangebyscore.js +0 -13
  332. package/script/pkg/commands/zrevrank.js +0 -13
  333. package/script/pkg/commands/zscan.js +0 -20
  334. package/script/pkg/commands/zscore.js +0 -13
  335. package/script/pkg/commands/zunion.js +0 -34
  336. package/script/pkg/commands/zunionstore.js +0 -31
  337. package/script/pkg/error.js +0 -13
  338. package/script/pkg/http.js +0 -178
  339. package/script/pkg/pipeline.js +0 -1311
  340. package/script/pkg/redis.js +0 -1323
  341. package/script/pkg/script.js +0 -81
  342. package/script/pkg/types.js +0 -2
  343. package/script/pkg/util.js +0 -35
  344. package/script/platforms/cloudflare.js +0 -97
  345. package/script/platforms/fastly.js +0 -73
  346. package/script/platforms/node_with_fetch.js +0 -112
  347. package/script/platforms/nodejs.js +0 -109
  348. package/script/version.js +0 -4
  349. package/types/deps/deno.land/x/base64@v0.2.1/base.d.ts +0 -5
  350. package/types/deps/deno.land/x/base64@v0.2.1/base64url.d.ts +0 -1
  351. package/types/deps/deno.land/x/sha1@v1.0.3/deps.d.ts +0 -1
  352. package/types/deps/deno.land/x/sha1@v1.0.3/mod.d.ts +0 -26
  353. package/types/deps/denopkg.com/chiefbiiko/std-encoding@v1.0.0/mod.d.ts +0 -3
  354. package/types/pkg/commands/append.d.ts +0 -7
  355. package/types/pkg/commands/bitcount.d.ts +0 -8
  356. package/types/pkg/commands/bitop.d.ts +0 -12
  357. package/types/pkg/commands/bitpos.d.ts +0 -7
  358. package/types/pkg/commands/command.d.ts +0 -37
  359. package/types/pkg/commands/dbsize.d.ts +0 -7
  360. package/types/pkg/commands/decr.d.ts +0 -7
  361. package/types/pkg/commands/decrby.d.ts +0 -7
  362. package/types/pkg/commands/del.d.ts +0 -7
  363. package/types/pkg/commands/echo.d.ts +0 -7
  364. package/types/pkg/commands/eval.d.ts +0 -7
  365. package/types/pkg/commands/evalsha.d.ts +0 -7
  366. package/types/pkg/commands/exists.d.ts +0 -7
  367. package/types/pkg/commands/expire.d.ts +0 -7
  368. package/types/pkg/commands/expireat.d.ts +0 -7
  369. package/types/pkg/commands/flushall.d.ts +0 -9
  370. package/types/pkg/commands/flushdb.d.ts +0 -9
  371. package/types/pkg/commands/geo_add.d.ts +0 -25
  372. package/types/pkg/commands/get.d.ts +0 -7
  373. package/types/pkg/commands/getbit.d.ts +0 -7
  374. package/types/pkg/commands/getdel.d.ts +0 -7
  375. package/types/pkg/commands/getrange.d.ts +0 -7
  376. package/types/pkg/commands/getset.d.ts +0 -7
  377. package/types/pkg/commands/hdel.d.ts +0 -7
  378. package/types/pkg/commands/hexists.d.ts +0 -7
  379. package/types/pkg/commands/hget.d.ts +0 -7
  380. package/types/pkg/commands/hgetall.d.ts +0 -7
  381. package/types/pkg/commands/hincrby.d.ts +0 -7
  382. package/types/pkg/commands/hincrbyfloat.d.ts +0 -7
  383. package/types/pkg/commands/hkeys.d.ts +0 -7
  384. package/types/pkg/commands/hlen.d.ts +0 -7
  385. package/types/pkg/commands/hmget.d.ts +0 -15
  386. package/types/pkg/commands/hmset.d.ts +0 -9
  387. package/types/pkg/commands/hrandfield.d.ts +0 -9
  388. package/types/pkg/commands/hscan.d.ts +0 -24
  389. package/types/pkg/commands/hset.d.ts +0 -9
  390. package/types/pkg/commands/hsetnx.d.ts +0 -7
  391. package/types/pkg/commands/hstrlen.d.ts +0 -7
  392. package/types/pkg/commands/hvals.d.ts +0 -7
  393. package/types/pkg/commands/incr.d.ts +0 -7
  394. package/types/pkg/commands/incrby.d.ts +0 -7
  395. package/types/pkg/commands/incrbyfloat.d.ts +0 -7
  396. package/types/pkg/commands/json_arrappend.d.ts +0 -7
  397. package/types/pkg/commands/json_arrindex.d.ts +0 -13
  398. package/types/pkg/commands/json_arrinsert.d.ts +0 -7
  399. package/types/pkg/commands/json_arrlen.d.ts +0 -7
  400. package/types/pkg/commands/json_arrpop.d.ts +0 -7
  401. package/types/pkg/commands/json_arrtrim.d.ts +0 -7
  402. package/types/pkg/commands/json_clear.d.ts +0 -7
  403. package/types/pkg/commands/json_del.d.ts +0 -7
  404. package/types/pkg/commands/json_forget.d.ts +0 -7
  405. package/types/pkg/commands/json_get.d.ts +0 -15
  406. package/types/pkg/commands/json_mget.d.ts +0 -7
  407. package/types/pkg/commands/json_numincrby.d.ts +0 -7
  408. package/types/pkg/commands/json_nummultby.d.ts +0 -7
  409. package/types/pkg/commands/json_objkeys.d.ts +0 -7
  410. package/types/pkg/commands/json_objlen.d.ts +0 -7
  411. package/types/pkg/commands/json_resp.d.ts +0 -7
  412. package/types/pkg/commands/json_set.d.ts +0 -18
  413. package/types/pkg/commands/json_strappend.d.ts +0 -7
  414. package/types/pkg/commands/json_strlen.d.ts +0 -7
  415. package/types/pkg/commands/json_toggle.d.ts +0 -7
  416. package/types/pkg/commands/json_type.d.ts +0 -7
  417. package/types/pkg/commands/keys.d.ts +0 -7
  418. package/types/pkg/commands/lindex.d.ts +0 -4
  419. package/types/pkg/commands/linsert.d.ts +0 -9
  420. package/types/pkg/commands/llen.d.ts +0 -7
  421. package/types/pkg/commands/lmove.d.ts +0 -12
  422. package/types/pkg/commands/lpop.d.ts +0 -7
  423. package/types/pkg/commands/lpos.d.ts +0 -15
  424. package/types/pkg/commands/lpush.d.ts +0 -7
  425. package/types/pkg/commands/lpushx.d.ts +0 -7
  426. package/types/pkg/commands/lrange.d.ts +0 -4
  427. package/types/pkg/commands/lrem.d.ts +0 -4
  428. package/types/pkg/commands/lset.d.ts +0 -4
  429. package/types/pkg/commands/ltrim.d.ts +0 -4
  430. package/types/pkg/commands/mget.d.ts +0 -7
  431. package/types/pkg/commands/mod.d.ts +0 -144
  432. package/types/pkg/commands/mset.d.ts +0 -9
  433. package/types/pkg/commands/msetnx.d.ts +0 -9
  434. package/types/pkg/commands/persist.d.ts +0 -7
  435. package/types/pkg/commands/pexpire.d.ts +0 -7
  436. package/types/pkg/commands/pexpireat.d.ts +0 -7
  437. package/types/pkg/commands/ping.d.ts +0 -7
  438. package/types/pkg/commands/psetex.d.ts +0 -7
  439. package/types/pkg/commands/pttl.d.ts +0 -7
  440. package/types/pkg/commands/publish.d.ts +0 -7
  441. package/types/pkg/commands/randomkey.d.ts +0 -7
  442. package/types/pkg/commands/rename.d.ts +0 -7
  443. package/types/pkg/commands/renamenx.d.ts +0 -7
  444. package/types/pkg/commands/rpop.d.ts +0 -7
  445. package/types/pkg/commands/rpush.d.ts +0 -7
  446. package/types/pkg/commands/rpushx.d.ts +0 -7
  447. package/types/pkg/commands/sadd.d.ts +0 -7
  448. package/types/pkg/commands/scan.d.ts +0 -18
  449. package/types/pkg/commands/scard.d.ts +0 -7
  450. package/types/pkg/commands/script_exists.d.ts +0 -7
  451. package/types/pkg/commands/script_flush.d.ts +0 -14
  452. package/types/pkg/commands/script_load.d.ts +0 -7
  453. package/types/pkg/commands/sdiff.d.ts +0 -7
  454. package/types/pkg/commands/sdiffstore.d.ts +0 -7
  455. package/types/pkg/commands/set.d.ts +0 -55
  456. package/types/pkg/commands/setbit.d.ts +0 -7
  457. package/types/pkg/commands/setex.d.ts +0 -7
  458. package/types/pkg/commands/setnx.d.ts +0 -7
  459. package/types/pkg/commands/setrange.d.ts +0 -7
  460. package/types/pkg/commands/sinter.d.ts +0 -7
  461. package/types/pkg/commands/sinterstore.d.ts +0 -7
  462. package/types/pkg/commands/sismember.d.ts +0 -7
  463. package/types/pkg/commands/smembers.d.ts +0 -7
  464. package/types/pkg/commands/smismember.d.ts +0 -7
  465. package/types/pkg/commands/smove.d.ts +0 -7
  466. package/types/pkg/commands/spop.d.ts +0 -7
  467. package/types/pkg/commands/srandmember.d.ts +0 -7
  468. package/types/pkg/commands/srem.d.ts +0 -7
  469. package/types/pkg/commands/sscan.d.ts +0 -24
  470. package/types/pkg/commands/strlen.d.ts +0 -7
  471. package/types/pkg/commands/sunion.d.ts +0 -7
  472. package/types/pkg/commands/sunionstore.d.ts +0 -7
  473. package/types/pkg/commands/time.d.ts +0 -7
  474. package/types/pkg/commands/touch.d.ts +0 -7
  475. package/types/pkg/commands/ttl.d.ts +0 -7
  476. package/types/pkg/commands/type.d.ts +0 -8
  477. package/types/pkg/commands/unlink.d.ts +0 -7
  478. package/types/pkg/commands/xadd.d.ts +0 -31
  479. package/types/pkg/commands/xrange.d.ts +0 -9
  480. package/types/pkg/commands/zadd.d.ts +0 -35
  481. package/types/pkg/commands/zcard.d.ts +0 -7
  482. package/types/pkg/commands/zcount.d.ts +0 -7
  483. package/types/pkg/commands/zdiffstore.d.ts +0 -7
  484. package/types/pkg/commands/zincrby.d.ts +0 -7
  485. package/types/pkg/commands/zinterstore.d.ts +0 -30
  486. package/types/pkg/commands/zlexcount.d.ts +0 -7
  487. package/types/pkg/commands/zmscore.d.ts +0 -7
  488. package/types/pkg/commands/zpopmax.d.ts +0 -7
  489. package/types/pkg/commands/zpopmin.d.ts +0 -7
  490. package/types/pkg/commands/zrange.d.ts +0 -42
  491. package/types/pkg/commands/zrank.d.ts +0 -7
  492. package/types/pkg/commands/zrem.d.ts +0 -7
  493. package/types/pkg/commands/zremrangebylex.d.ts +0 -7
  494. package/types/pkg/commands/zremrangebyrank.d.ts +0 -7
  495. package/types/pkg/commands/zremrangebyscore.d.ts +0 -7
  496. package/types/pkg/commands/zrevrank.d.ts +0 -7
  497. package/types/pkg/commands/zscan.d.ts +0 -24
  498. package/types/pkg/commands/zscore.d.ts +0 -7
  499. package/types/pkg/commands/zunion.d.ts +0 -29
  500. package/types/pkg/commands/zunionstore.d.ts +0 -30
  501. package/types/pkg/error.d.ts +0 -6
  502. package/types/pkg/http.d.ts +0 -95
  503. package/types/pkg/pipeline.d.ts +0 -686
  504. package/types/pkg/redis.d.ts +0 -692
  505. package/types/pkg/script.d.ts +0 -42
  506. package/types/pkg/types.d.ts +0 -27
  507. package/types/pkg/util.d.ts +0 -1
  508. package/types/platforms/cloudflare.d.ts +0 -43
  509. package/types/platforms/fastly.d.ts +0 -41
  510. package/types/platforms/node_with_fetch.d.ts +0 -63
  511. package/types/platforms/nodejs.d.ts +0 -78
  512. package/types/version.d.ts +0 -1
package/nodejs.d.mts ADDED
@@ -0,0 +1,87 @@
1
+ import { R as RedisOptions, a as RequesterConfig, b as Redis$1, c as Requester } from './zmscore-09122379.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, k as EvalCommand, l as EvalshaCommand, m as ExistsCommand, o as ExpireAtCommand, n as ExpireCommand, F as FlushAllCommand, p as FlushDBCommand, G as GeoAddCommand, q as GeoAddCommandOptions, s as GeoDistCommand, t as GeoHashCommand, r as GeoMember, u as GeoPosCommand, v as GeoSearchCommand, w as GeoSearchStoreCommand, y as GetBitCommand, x as GetCommand, z as GetDelCommand, H as GetRangeCommand, I as GetSetCommand, J as HDelCommand, K as HExistsCommand, M as HGetAllCommand, L as HGetCommand, N as HIncrByCommand, O as HIncrByFloatCommand, Q as HKeysCommand, S as HLenCommand, T as HMGetCommand, V as HMSetCommand, W as HRandFieldCommand, X as HScanCommand, Y as HSetCommand, Z as HSetNXCommand, _ as HStrLenCommand, $ as HValsCommand, a1 as IncrByCommand, a2 as IncrByFloatCommand, a0 as IncrCommand, a3 as JsonArrAppendCommand, a4 as JsonArrIndexCommand, a5 as JsonArrInsertCommand, a6 as JsonArrLenCommand, a7 as JsonArrPopCommand, a8 as JsonArrTrimCommand, a9 as JsonClearCommand, aa as JsonDelCommand, ab as JsonForgetCommand, ac as JsonGetCommand, ad as JsonMGetCommand, ae as JsonNumIncrByCommand, af as JsonNumMultByCommand, ag as JsonObjKeysCommand, ah as JsonObjLenCommand, ai as JsonRespCommand, aj as JsonSetCommand, ak as JsonStrAppendCommand, al as JsonStrLenCommand, am as JsonToggleCommand, an as JsonTypeCommand, ao as KeysCommand, ap as LIndexCommand, aq as LInsertCommand, ar as LLenCommand, as as LMoveCommand, at as LPopCommand, au as LPushCommand, av as LPushXCommand, aw as LRangeCommand, ax as LRemCommand, ay as LSetCommand, az as LTrimCommand, aA as MGetCommand, aB as MSetCommand, aC as MSetNXCommand, aF as PExpireAtCommand, aE as PExpireCommand, aH as PSetEXCommand, aI as PTtlCommand, aD as PersistCommand, aG as PingCommand, P as Pipeline, aJ as PublishCommand, aN as RPopCommand, aO as RPushCommand, aP as RPushXCommand, aK as RandomKeyCommand, aL as RenameCommand, aM as RenameNXCommand, aQ as SAddCommand, aT as SCardCommand, aX as SDiffCommand, aY as SDiffStoreCommand, b3 as SInterCommand, b4 as SInterStoreCommand, b5 as SIsMemberCommand, b7 as SMIsMemberCommand, b6 as SMembersCommand, b8 as SMoveCommand, b9 as SPopCommand, ba as SRandMemberCommand, bb as SRemCommand, bc as SScanCommand, be as SUnionCommand, bf as SUnionStoreCommand, aR as ScanCommand, aS as ScanCommandOptions, bo as ScoreMember, aU as ScriptExistsCommand, aV as ScriptFlushCommand, aW as ScriptLoadCommand, a$ as SetBitCommand, aZ as SetCommand, a_ as SetCommandOptions, b0 as SetExCommand, b1 as SetNxCommand, b2 as SetRangeCommand, bd as StrLenCommand, bg as TimeCommand, bh as TouchCommand, bi as TtlCommand, bj as Type, bk as TypeCommand, bl as UnlinkCommand, U as UpstashRequest, d as UpstashResponse, bm as XAddCommand, bn as XRangeCommand, bq as ZAddCommand, bp as ZAddCommandOptions, br as ZCardCommand, bs as ZCountCommand, bt as ZDiffStoreCommand, bu as ZIncrByCommand, bv as ZInterStoreCommand, bw as ZInterStoreCommandOptions, bx as ZLexCountCommand, by as ZMScoreCommand, bz as ZPopMaxCommand, bA as ZPopMinCommand, bB as ZRangeCommand, bC as ZRangeCommandOptions, bD as ZRankCommand, bE as ZRemCommand, bF as ZRemRangeByLexCommand, bG as ZRemRangeByRankCommand, bH as ZRemRangeByScoreCommand, bI as ZRevRankCommand, bJ as ZScanCommand, bK as ZScoreCommand, bL as ZUnionCommand, bM as ZUnionCommandOptions, bN as ZUnionStoreCommand, bO as ZUnionStoreCommandOptions, e as errors } from './zmscore-09122379.js';
3
+
4
+ /**
5
+ * Connection credentials for upstash redis.
6
+ * Get them from https://console.upstash.com/redis/<uuid>
7
+ */
8
+ type RedisConfigNodejs = {
9
+ /**
10
+ * UPSTASH_REDIS_REST_URL
11
+ */
12
+ url: string | undefined;
13
+ /**
14
+ * UPSTASH_REDIS_REST_TOKEN
15
+ */
16
+ token: string | undefined;
17
+ /**
18
+ * An agent allows you to reuse connections to reduce latency for multiple sequential requests.
19
+ *
20
+ * This is a node specific implementation and is not supported in various runtimes like Vercel
21
+ * edge functions.
22
+ *
23
+ * @example
24
+ * ```ts
25
+ * import https from "https"
26
+ *
27
+ * const options: RedisConfigNodejs = {
28
+ * agent: new https.Agent({ keepAlive: true })
29
+ * }
30
+ * ```
31
+ */
32
+ /**
33
+ * The signal will allow aborting requests on the fly.
34
+ * For more check: https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal
35
+ */
36
+ signal?: AbortSignal;
37
+ latencyLogging?: boolean;
38
+ agent?: any;
39
+ keepAlive?: boolean;
40
+ } & RedisOptions & RequesterConfig;
41
+ /**
42
+ * Serverless redis client for upstash.
43
+ */
44
+ declare class Redis extends Redis$1 {
45
+ /**
46
+ * Create a new redis client by providing the url and token
47
+ *
48
+ * @example
49
+ * ```typescript
50
+ * const redis = new Redis({
51
+ * url: "<UPSTASH_REDIS_REST_URL>",
52
+ * token: "<UPSTASH_REDIS_REST_TOKEN>",
53
+ * });
54
+ * ```
55
+ */
56
+ constructor(config: RedisConfigNodejs);
57
+ /**
58
+ * Create a new redis client by providing a custom `Requester` implementation
59
+ *
60
+ * @example
61
+ * ```ts
62
+ *
63
+ * import { UpstashRequest, Requester, UpstashResponse, Redis } from "@upstash/redis"
64
+ *
65
+ * const requester: Requester = {
66
+ * request: <TResult>(req: UpstashRequest): Promise<UpstashResponse<TResult>> => {
67
+ * // ...
68
+ * }
69
+ * }
70
+ *
71
+ * const redis = new Redis(requester)
72
+ * ```
73
+ */
74
+ constructor(requesters: Requester);
75
+ /**
76
+ * Create a new Upstash Redis instance from environment variables.
77
+ *
78
+ * Use this to automatically load connection secrets from your environment
79
+ * variables. For instance when using the Vercel integration.
80
+ *
81
+ * This tries to load `UPSTASH_REDIS_REST_URL` and `UPSTASH_REDIS_REST_TOKEN` from
82
+ * your environment using `process.env`.
83
+ */
84
+ static fromEnv(config?: Omit<RedisConfigNodejs, "url" | "token">): Redis;
85
+ }
86
+
87
+ export { Redis, RedisConfigNodejs, Requester };
package/nodejs.d.ts ADDED
@@ -0,0 +1,87 @@
1
+ import { R as RedisOptions, a as RequesterConfig, b as Redis$1, c as Requester } from './zmscore-09122379.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, k as EvalCommand, l as EvalshaCommand, m as ExistsCommand, o as ExpireAtCommand, n as ExpireCommand, F as FlushAllCommand, p as FlushDBCommand, G as GeoAddCommand, q as GeoAddCommandOptions, s as GeoDistCommand, t as GeoHashCommand, r as GeoMember, u as GeoPosCommand, v as GeoSearchCommand, w as GeoSearchStoreCommand, y as GetBitCommand, x as GetCommand, z as GetDelCommand, H as GetRangeCommand, I as GetSetCommand, J as HDelCommand, K as HExistsCommand, M as HGetAllCommand, L as HGetCommand, N as HIncrByCommand, O as HIncrByFloatCommand, Q as HKeysCommand, S as HLenCommand, T as HMGetCommand, V as HMSetCommand, W as HRandFieldCommand, X as HScanCommand, Y as HSetCommand, Z as HSetNXCommand, _ as HStrLenCommand, $ as HValsCommand, a1 as IncrByCommand, a2 as IncrByFloatCommand, a0 as IncrCommand, a3 as JsonArrAppendCommand, a4 as JsonArrIndexCommand, a5 as JsonArrInsertCommand, a6 as JsonArrLenCommand, a7 as JsonArrPopCommand, a8 as JsonArrTrimCommand, a9 as JsonClearCommand, aa as JsonDelCommand, ab as JsonForgetCommand, ac as JsonGetCommand, ad as JsonMGetCommand, ae as JsonNumIncrByCommand, af as JsonNumMultByCommand, ag as JsonObjKeysCommand, ah as JsonObjLenCommand, ai as JsonRespCommand, aj as JsonSetCommand, ak as JsonStrAppendCommand, al as JsonStrLenCommand, am as JsonToggleCommand, an as JsonTypeCommand, ao as KeysCommand, ap as LIndexCommand, aq as LInsertCommand, ar as LLenCommand, as as LMoveCommand, at as LPopCommand, au as LPushCommand, av as LPushXCommand, aw as LRangeCommand, ax as LRemCommand, ay as LSetCommand, az as LTrimCommand, aA as MGetCommand, aB as MSetCommand, aC as MSetNXCommand, aF as PExpireAtCommand, aE as PExpireCommand, aH as PSetEXCommand, aI as PTtlCommand, aD as PersistCommand, aG as PingCommand, P as Pipeline, aJ as PublishCommand, aN as RPopCommand, aO as RPushCommand, aP as RPushXCommand, aK as RandomKeyCommand, aL as RenameCommand, aM as RenameNXCommand, aQ as SAddCommand, aT as SCardCommand, aX as SDiffCommand, aY as SDiffStoreCommand, b3 as SInterCommand, b4 as SInterStoreCommand, b5 as SIsMemberCommand, b7 as SMIsMemberCommand, b6 as SMembersCommand, b8 as SMoveCommand, b9 as SPopCommand, ba as SRandMemberCommand, bb as SRemCommand, bc as SScanCommand, be as SUnionCommand, bf as SUnionStoreCommand, aR as ScanCommand, aS as ScanCommandOptions, bo as ScoreMember, aU as ScriptExistsCommand, aV as ScriptFlushCommand, aW as ScriptLoadCommand, a$ as SetBitCommand, aZ as SetCommand, a_ as SetCommandOptions, b0 as SetExCommand, b1 as SetNxCommand, b2 as SetRangeCommand, bd as StrLenCommand, bg as TimeCommand, bh as TouchCommand, bi as TtlCommand, bj as Type, bk as TypeCommand, bl as UnlinkCommand, U as UpstashRequest, d as UpstashResponse, bm as XAddCommand, bn as XRangeCommand, bq as ZAddCommand, bp as ZAddCommandOptions, br as ZCardCommand, bs as ZCountCommand, bt as ZDiffStoreCommand, bu as ZIncrByCommand, bv as ZInterStoreCommand, bw as ZInterStoreCommandOptions, bx as ZLexCountCommand, by as ZMScoreCommand, bz as ZPopMaxCommand, bA as ZPopMinCommand, bB as ZRangeCommand, bC as ZRangeCommandOptions, bD as ZRankCommand, bE as ZRemCommand, bF as ZRemRangeByLexCommand, bG as ZRemRangeByRankCommand, bH as ZRemRangeByScoreCommand, bI as ZRevRankCommand, bJ as ZScanCommand, bK as ZScoreCommand, bL as ZUnionCommand, bM as ZUnionCommandOptions, bN as ZUnionStoreCommand, bO as ZUnionStoreCommandOptions, e as errors } from './zmscore-09122379.js';
3
+
4
+ /**
5
+ * Connection credentials for upstash redis.
6
+ * Get them from https://console.upstash.com/redis/<uuid>
7
+ */
8
+ type RedisConfigNodejs = {
9
+ /**
10
+ * UPSTASH_REDIS_REST_URL
11
+ */
12
+ url: string | undefined;
13
+ /**
14
+ * UPSTASH_REDIS_REST_TOKEN
15
+ */
16
+ token: string | undefined;
17
+ /**
18
+ * An agent allows you to reuse connections to reduce latency for multiple sequential requests.
19
+ *
20
+ * This is a node specific implementation and is not supported in various runtimes like Vercel
21
+ * edge functions.
22
+ *
23
+ * @example
24
+ * ```ts
25
+ * import https from "https"
26
+ *
27
+ * const options: RedisConfigNodejs = {
28
+ * agent: new https.Agent({ keepAlive: true })
29
+ * }
30
+ * ```
31
+ */
32
+ /**
33
+ * The signal will allow aborting requests on the fly.
34
+ * For more check: https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal
35
+ */
36
+ signal?: AbortSignal;
37
+ latencyLogging?: boolean;
38
+ agent?: any;
39
+ keepAlive?: boolean;
40
+ } & RedisOptions & RequesterConfig;
41
+ /**
42
+ * Serverless redis client for upstash.
43
+ */
44
+ declare class Redis extends Redis$1 {
45
+ /**
46
+ * Create a new redis client by providing the url and token
47
+ *
48
+ * @example
49
+ * ```typescript
50
+ * const redis = new Redis({
51
+ * url: "<UPSTASH_REDIS_REST_URL>",
52
+ * token: "<UPSTASH_REDIS_REST_TOKEN>",
53
+ * });
54
+ * ```
55
+ */
56
+ constructor(config: RedisConfigNodejs);
57
+ /**
58
+ * Create a new redis client by providing a custom `Requester` implementation
59
+ *
60
+ * @example
61
+ * ```ts
62
+ *
63
+ * import { UpstashRequest, Requester, UpstashResponse, Redis } from "@upstash/redis"
64
+ *
65
+ * const requester: Requester = {
66
+ * request: <TResult>(req: UpstashRequest): Promise<UpstashResponse<TResult>> => {
67
+ * // ...
68
+ * }
69
+ * }
70
+ *
71
+ * const redis = new Redis(requester)
72
+ * ```
73
+ */
74
+ constructor(requesters: Requester);
75
+ /**
76
+ * Create a new Upstash Redis instance from environment variables.
77
+ *
78
+ * Use this to automatically load connection secrets from your environment
79
+ * variables. For instance when using the Vercel integration.
80
+ *
81
+ * This tries to load `UPSTASH_REDIS_REST_URL` and `UPSTASH_REDIS_REST_TOKEN` from
82
+ * your environment using `process.env`.
83
+ */
84
+ static fromEnv(config?: Omit<RedisConfigNodejs, "url" | "token">): Redis;
85
+ }
86
+
87
+ export { Redis, RedisConfigNodejs, Requester };
package/nodejs.js ADDED
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }var _chunkPXDAFHKPjs = require('./chunk-PXDAFHKP.js');typeof atob>"u"&&(global.atob=o=>Buffer.from(o,"base64").toString("utf-8"));var a=class o extends _chunkPXDAFHKPjs.c{constructor(e){if("request"in e){super(e);return}if(!e.url)throw new Error("[Upstash Redis] The 'url' property is missing or undefined in your Redis config.");if(!e.token)throw new Error("[Upstash Redis] The 'token' property is missing or undefined in your Redis config.");(e.url.startsWith(" ")||e.url.endsWith(" ")||/\r|\n/.test(e.url))&&console.warn("The redis url contains whitespace or newline, which can cause errors!"),(e.token.startsWith(" ")||e.token.endsWith(" ")||/\r|\n/.test(e.token))&&console.warn("The redis token contains whitespace or newline, which can cause errors!");let n=new (0, _chunkPXDAFHKPjs.b)({baseUrl:e.url,retry:e.retry,headers:{authorization:`Bearer ${e.token}`},agent:e.agent,responseEncoding:e.responseEncoding,cache:e.cache||"no-store",signal:e.signal,keepAlive:e.keepAlive});if(super(n,{automaticDeserialization:e.automaticDeserialization,enableTelemetry:!process.env.UPSTASH_DISABLE_TELEMETRY,latencyLogging:e.latencyLogging,enableAutoPipelining:e.enableAutoPipelining}),this.addTelemetry({runtime:typeof EdgeRuntime=="string"?"edge-light":`node@${process.version}`,platform:process.env.VERCEL?"vercel":process.env.AWS_REGION?"aws":"unknown",sdk:`@upstash/redis@${_chunkPXDAFHKPjs.d}`}),this.enableAutoPipelining)return this.autoPipeline()}static fromEnv(e){if(typeof _optionalChain([process, 'optionalAccess', _ => _.env])>"u")throw new Error('Unable to get environment variables, `process.env` is undefined. If you are deploying to cloudflare, please import from "@upstash/redis/cloudflare" instead');let n=_optionalChain([process, 'optionalAccess', _2 => _2.env, 'access', _3 => _3.UPSTASH_REDIS_REST_URL]);if(!n)throw new Error("Unable to find environment variable: `UPSTASH_REDIS_REST_URL`");let t=_optionalChain([process, 'optionalAccess', _4 => _4.env, 'access', _5 => _5.UPSTASH_REDIS_REST_TOKEN]);if(!t)throw new Error("Unable to find environment variable: `UPSTASH_REDIS_REST_TOKEN`");return new o({...e,url:n,token:t})}};exports.Redis = a; exports.errors = _chunkPXDAFHKPjs.a;
package/nodejs.mjs ADDED
@@ -0,0 +1 @@
1
+ import{a as l,b as s,c as i,d as r}from"./chunk-SGK6FTNU.mjs";typeof atob>"u"&&(global.atob=o=>Buffer.from(o,"base64").toString("utf-8"));var a=class o extends i{constructor(e){if("request"in e){super(e);return}if(!e.url)throw new Error("[Upstash Redis] The 'url' property is missing or undefined in your Redis config.");if(!e.token)throw new Error("[Upstash Redis] The 'token' property is missing or undefined in your Redis config.");(e.url.startsWith(" ")||e.url.endsWith(" ")||/\r|\n/.test(e.url))&&console.warn("The redis url contains whitespace or newline, which can cause errors!"),(e.token.startsWith(" ")||e.token.endsWith(" ")||/\r|\n/.test(e.token))&&console.warn("The redis token contains whitespace or newline, which can cause errors!");let n=new s({baseUrl:e.url,retry:e.retry,headers:{authorization:`Bearer ${e.token}`},agent:e.agent,responseEncoding:e.responseEncoding,cache:e.cache||"no-store",signal:e.signal,keepAlive:e.keepAlive});if(super(n,{automaticDeserialization:e.automaticDeserialization,enableTelemetry:!process.env.UPSTASH_DISABLE_TELEMETRY,latencyLogging:e.latencyLogging,enableAutoPipelining:e.enableAutoPipelining}),this.addTelemetry({runtime:typeof EdgeRuntime=="string"?"edge-light":`node@${process.version}`,platform:process.env.VERCEL?"vercel":process.env.AWS_REGION?"aws":"unknown",sdk:`@upstash/redis@${r}`}),this.enableAutoPipelining)return this.autoPipeline()}static fromEnv(e){if(typeof process?.env>"u")throw new Error('Unable to get environment variables, `process.env` is undefined. If you are deploying to cloudflare, please import from "@upstash/redis/cloudflare" instead');let n=process?.env.UPSTASH_REDIS_REST_URL;if(!n)throw new Error("Unable to find environment variable: `UPSTASH_REDIS_REST_URL`");let t=process?.env.UPSTASH_REDIS_REST_TOKEN;if(!t)throw new Error("Unable to find environment variable: `UPSTASH_REDIS_REST_TOKEN`");return new o({...e,url:n,token:t})}};export{a as Redis,l as errors};
package/package.json CHANGED
@@ -1,96 +1 @@
1
- {
2
- "module": "./esm/platforms/nodejs.js",
3
- "main": "./script/platforms/nodejs.js",
4
- "types": "./types/platforms/nodejs.d.ts",
5
- "name": "@upstash/redis",
6
- "version": "v0.0.0-ci.eb0d57e1-20231019",
7
- "description": "An HTTP/REST based Redis client built on top of Upstash REST API.",
8
- "repository": {
9
- "type": "git",
10
- "url": "git+https://github.com/upstash/upstash-redis.git"
11
- },
12
- "keywords": [
13
- "redis",
14
- "database",
15
- "serverless",
16
- "edge",
17
- "upstash"
18
- ],
19
- "author": "Andreas Thomas <dev@chronark.com>",
20
- "license": "MIT",
21
- "bugs": {
22
- "url": "https://github.com/upstash/upstash-redis/issues"
23
- },
24
- "homepage": "https://github.com/upstash/upstash-redis#readme",
25
- "dependencies": {
26
- "isomorphic-fetch": "^3.0.0"
27
- },
28
- "typesVersions": {
29
- "*": {
30
- "nodejs": [
31
- "./types/platforms/nodejs.d.ts"
32
- ],
33
- "cloudflare": [
34
- "./types/platforms/cloudflare.d.ts"
35
- ],
36
- "fastly": [
37
- "./types/platforms/fastly.d.ts"
38
- ],
39
- "with-fetch": [
40
- "./types/platforms/node_with_fetch.d.ts"
41
- ]
42
- }
43
- },
44
- "exports": {
45
- ".": {
46
- "import": {
47
- "types": "./types/platforms/nodejs.d.ts",
48
- "default": "./esm/platforms/nodejs.js"
49
- },
50
- "require": {
51
- "types": "./types/platforms/nodejs.d.ts",
52
- "default": "./script/platforms/nodejs.js"
53
- }
54
- },
55
- "./nodejs": {
56
- "import": {
57
- "types": "./types/platforms/nodejs.d.ts",
58
- "default": "./esm/platforms/nodejs.js"
59
- },
60
- "require": {
61
- "types": "./types/platforms/nodejs.d.ts",
62
- "default": "./script/platforms/nodejs.js"
63
- }
64
- },
65
- "./cloudflare": {
66
- "import": {
67
- "types": "./types/platforms/cloudflare.d.ts",
68
- "default": "./esm/platforms/cloudflare.js"
69
- },
70
- "require": {
71
- "types": "./types/platforms/cloudflare.d.ts",
72
- "default": "./script/platforms/cloudflare.js"
73
- }
74
- },
75
- "./fastly": {
76
- "import": {
77
- "types": "./types/platforms/fastly.d.ts",
78
- "default": "./esm/platforms/fastly.js"
79
- },
80
- "require": {
81
- "types": "./types/platforms/fastly.d.ts",
82
- "default": "./script/platforms/fastly.js"
83
- }
84
- },
85
- "./with-fetch": {
86
- "import": {
87
- "types": "./types/platforms/node_with_fetch.d.ts",
88
- "default": "./esm/platforms/node_with_fetch.js"
89
- },
90
- "require": {
91
- "types": "./types/platforms/node_with_fetch.d.ts",
92
- "default": "./script/platforms/node_with_fetch.js"
93
- }
94
- }
95
- }
96
- }
1
+ {"name":"@upstash/redis","version":"v0.0.0-ci.ec86feafac6d95eed4e9c9d8a5ff13b74ed84a74-20240709145745","main":"./nodejs.js","module":"./nodejs.mjs","exports":{".":{"import":"./nodejs.mjs","require":"./nodejs.js"},"./node":{"import":"./nodejs.mjs","require":"./nodejs.js"},"./node.js":"./node.js","./node.mjs":"./node.mjs","./cloudflare":{"import":"./cloudflare.mjs","require":"./cloudflare.js"},"./cloudflare.js":"./cloudflare.js","./cloudflare.mjs":"./cloudflare.mjs","./fastly":{"import":"./fastly.mjs","require":"./fastly.js"},"./fastly.js":"./fastly.js","./fastly.mjs":"./fastly.mjs"},"types":"./nodejs.d.ts","description":"An HTTP/REST based Redis client built on top of Upstash REST API.","repository":{"type":"git","url":"git+https://github.com/upstash/upstash-redis.git"},"keywords":["redis","database","serverless","edge","upstash"],"files":["./**"],"scripts":{"build":"tsup && cp README.md ./dist/ && cp package.json ./dist/ && cp LICENSE ./dist/","test":"bun test pkg --coverage --timeout 20000","fmt":"bunx @biomejs/biome check --apply ./pkg"},"author":"Andreas Thomas <dev@chronark.com>","license":"MIT","bugs":{"url":"https://github.com/upstash/upstash-redis/issues"},"homepage":"https://github.com/upstash/upstash-redis#readme","typesVersions":{"*":{"nodejs":["./nodejs.d.ts"],"cloudflare":["./cloudflare.d.ts"],"fastly":["./fastly.d.ts"]}},"devDependencies":{"@biomejs/biome":"latest","@types/crypto-js":"^4.1.3","bun-types":"1.0.33","husky":"^8.0.3","tsup":"^7.2.0","typescript":"latest"},"dependencies":{"crypto-js":"^4.2.0"}}