9 lines
245 B
Python
9 lines
245 B
Python
"""
|
|
slowapi rate limiter setup.
|
|
Import `limiter` here and attach it to the FastAPI app in main.py.
|
|
"""
|
|
from slowapi import Limiter
|
|
from slowapi.util import get_remote_address
|
|
|
|
limiter = Limiter(key_func=get_remote_address, headers_enabled=True)
|