feat: Add zones for rate limiting by ip, user, session, global (#8508)

This commit is contained in:
Daniel
2023-06-09 21:27:56 +10:00
committed by GitHub
parent e2a7218f74
commit 03fba97e05
9 changed files with 161 additions and 3 deletions

View File

@@ -0,0 +1,19 @@
const ParseServer = {};
/**
* ...
*
* @memberof Parse.Server
* @property {String} global Rate limit based on the number of requests made by all users.
* @property {String} session Rate limit based on the sessionToken.
* @property {String} user Rate limit based on the user ID.
* @property {String} ip Rate limit based on the request ip.
* ...
*/
ParseServer.RateLimitZone = Object.freeze({
global: 'global',
session: 'session',
user: 'user',
ip: 'ip',
});
module.exports = ParseServer;