fix: reorder hunt endpoint params for SlowAPI
Some checks failed
CI / Frontend Lint & Type Check (push) Has been cancelled
CI / Frontend Build (push) Has been cancelled
CI / Backend Lint (push) Has been cancelled
CI / Backend Tests (push) Has been cancelled
CI / Docker Build (push) Has been cancelled
CI / Security Scan (push) Has been cancelled
Deploy / Build & Push Images (push) Has been cancelled
Deploy / Deploy to Server (push) Has been cancelled
Deploy / Notify (push) Has been cancelled
Some checks failed
CI / Frontend Lint & Type Check (push) Has been cancelled
CI / Frontend Build (push) Has been cancelled
CI / Backend Lint (push) Has been cancelled
CI / Backend Tests (push) Has been cancelled
CI / Docker Build (push) Has been cancelled
CI / Security Scan (push) Has been cancelled
Deploy / Build & Push Images (push) Has been cancelled
Deploy / Deploy to Server (push) Has been cancelled
Deploy / Notify (push) Has been cancelled
This commit is contained in:
@ -129,8 +129,8 @@ async def trends(
|
|||||||
@limiter.limit("30/minute")
|
@limiter.limit("30/minute")
|
||||||
async def keyword_availability(
|
async def keyword_availability(
|
||||||
request: Request,
|
request: Request,
|
||||||
_user: User = Depends(get_current_user),
|
|
||||||
payload: KeywordAvailabilityRequest,
|
payload: KeywordAvailabilityRequest,
|
||||||
|
_user: User = Depends(get_current_user),
|
||||||
):
|
):
|
||||||
# Normalize + cap work for UX/perf
|
# Normalize + cap work for UX/perf
|
||||||
keywords = []
|
keywords = []
|
||||||
@ -172,8 +172,8 @@ async def keyword_availability(
|
|||||||
@limiter.limit("20/minute")
|
@limiter.limit("20/minute")
|
||||||
async def typo_check(
|
async def typo_check(
|
||||||
request: Request,
|
request: Request,
|
||||||
_user: User = Depends(get_current_user),
|
|
||||||
payload: TypoCheckRequest,
|
payload: TypoCheckRequest,
|
||||||
|
_user: User = Depends(get_current_user),
|
||||||
):
|
):
|
||||||
brand = payload.brand.strip()
|
brand = payload.brand.strip()
|
||||||
typos = generate_typos(brand, limit=min(int(payload.limit) * 4, 400))
|
typos = generate_typos(brand, limit=min(int(payload.limit) * 4, 400))
|
||||||
@ -203,8 +203,8 @@ async def typo_check(
|
|||||||
@limiter.limit("15/minute")
|
@limiter.limit("15/minute")
|
||||||
async def brandables(
|
async def brandables(
|
||||||
request: Request,
|
request: Request,
|
||||||
_user: User = Depends(get_current_user),
|
|
||||||
payload: BrandableRequest,
|
payload: BrandableRequest,
|
||||||
|
_user: User = Depends(get_current_user),
|
||||||
):
|
):
|
||||||
pattern = payload.pattern.strip().lower()
|
pattern = payload.pattern.strip().lower()
|
||||||
if pattern not in ("cvcvc", "cvccv", "human"):
|
if pattern not in ("cvcvc", "cvccv", "human"):
|
||||||
|
|||||||
Reference in New Issue
Block a user