grammyjs / storages

Storage adapters for grammY sessions.
48 stars 23 forks source link

docs: Vercel KV example for Redis #180

Closed PonomareVlad closed 1 year ago

PonomareVlad commented 1 year ago

Redis setup example for Vercel KV

Complete example

Satont commented 1 year ago

Thanks for contribution.

Does kv satisfies expected type for storage? I think it should since kv extends bare resis class, but just to be sure.

PonomareVlad commented 1 year ago

@Satont It looks like that

I checked all the methods of the session plugin and found only one incompatibility related to JSON automatic deserialization

Therefore, without changing the plugin code, you can disable this parameter in the Redis instance:

instance.opts.automaticDeserialization = false;
Satont commented 1 year ago

Ok, thanks.