API Reference

Nestack Rate Limiter API

A Node.js and Express API demonstrating custom, in-memory rate limiting based on user tier and endpoint category.

Available endpoints

POST AI category
/api/ai/generate

Generate AI content. Subject to the AI request limit for the selected user tier.

POST AI category
/api/ai/summarise

Summarise content. Subject to the AI request limit for the selected user tier.

GET Read category
/api/data/list

Retrieve the available data list.

GET Read category
/api/data/export

Access the data export endpoint.

Rate limits

Free · AI 5 requests / min
Free · Read 30 requests / min
Paid · AI 30 requests / min
Paid · Read 120 requests / min

Exceeding a limit returns HTTP 429 until the current 60-second window expires.

Request headers

Choose the user tier with this header:

X-User-Tier: free

X-User-Tier: paid

Missing or invalid tier values default to the free tier.

Allowed requests return a JSON response: {"ok":true}