Skip to content
masterclass Buddy

Arcjet · Function

detectBot

detectBot allows or denies detected bots by name or category. Pass exactly one of allow or deny; use LIVE to enforce blocking or DRY_RUN to log only.

Last updated

Syntax

detectBot({ mode?: "LIVE" | "DRY_RUN", allow?: Array<ArcjetWellKnownBot | ArcjetBotCategory>, deny?: Array<ArcjetWellKnownBot | ArcjetBotCategory> })

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • BotCategory
  • botCategories
  • BotOptionsAllow
  • BotOptionsDeny
  • decision.isDenied()
  • reason.isBot()
  • reason.allowed
  • reason.denied

Source: Bot protection reference for Node.js | Arcjet Docs. Checked 2026-11-03.