mirror of
https://github.com/formbricks/formbricks.git
synced 2026-04-23 13:48:58 -05:00
e05cfaba5f
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com> Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com> Co-authored-by: Johannes <johannes@formbricks.com> Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
27 lines
802 B
TypeScript
27 lines
802 B
TypeScript
import rateLimit from "@/app/middleware/rateLimit";
|
|
|
|
import {
|
|
CLIENT_SIDE_API_RATE_LIMIT,
|
|
LOGIN_RATE_LIMIT,
|
|
SHARE_RATE_LIMIT,
|
|
SIGNUP_RATE_LIMIT,
|
|
} from "@formbricks/lib/constants";
|
|
|
|
export const signUpLimiter = rateLimit({
|
|
interval: SIGNUP_RATE_LIMIT.interval,
|
|
allowedPerInterval: SIGNUP_RATE_LIMIT.allowedPerInterval,
|
|
});
|
|
export const loginLimiter = rateLimit({
|
|
interval: LOGIN_RATE_LIMIT.interval,
|
|
allowedPerInterval: LOGIN_RATE_LIMIT.allowedPerInterval,
|
|
});
|
|
export const clientSideApiEndpointsLimiter = rateLimit({
|
|
interval: CLIENT_SIDE_API_RATE_LIMIT.interval,
|
|
allowedPerInterval: CLIENT_SIDE_API_RATE_LIMIT.allowedPerInterval,
|
|
});
|
|
|
|
export const shareUrlLimiter = rateLimit({
|
|
interval: SHARE_RATE_LIMIT.interval,
|
|
allowedPerInterval: SHARE_RATE_LIMIT.allowedPerInterval,
|
|
});
|