Rate Limiting Endpoint
The core of RateShield is the /per/endpointAPI. You call this endpoint in your application's middleware before fulfilling user requests.
Endpoint: POST /per/endpoint
Payload
Pass the unique identifier for the user (e.g., IP address or User ID) and the increment amount.
{
"rate": {
"key": "user_ip_123.45.67.89"
},
"counter_addition": 1
}Integration Flow
- Step 1: Your API receives a request.
- Step 2: Your API makes a fast POST to RateShield passing the client IP.
- Step 3: If RateShield returns 200, fulfill the request. If it returns 429, reject the request.