how to rate limit in trpc express/nodejs server (not nextjs)

?
4 Replies
test_1
test_1OP2y ago
each prodecure will have different rate limit for IP or sometthing idk maybe whole database will have same limit for now if there is no simple solution
Keef
Keef2y ago
I’ve done it using redis before
z
z2y ago
npm
express-rate-limit
Basic IP rate-limiting middleware for Express. Use to limit repeated requests to public APIs and/or endpoints such as password reset.. Latest version: 6.7.0, last published: 7 months ago. Start using express-rate-limit in your project by running npm i express-rate-limit. There are 733 other projects in the npm registry using express-rate-limit.
Keef
Keef2y ago
Looks like itll work 😄
Want results from more Discord servers?
Add your server