Skip to content

Conversation

@codedsultan
Copy link

What
Add an opt-in flag to skip inserting analytics rows for obvious bots. Uses isbot to detect common crawlers.

Default
SKIP_BOTS=false (no behaviour change).

How

  • Add SKIP_BOTS to central env (server/env.js) and .example.env.
  • In the visit logging path, if SKIP_BOTS=true and UA is a bot, only increment the link hit counter (no visit row).

Normal user traffic unchanged.

Why
Reduces analytics noise without affecting redirects or link counters.

Note: This PR branch off PR #937 (ua-parser swap).

@poeti8
Copy link
Member

poeti8 commented Sep 27, 2025

I don't want to increment visits count if it's a visit by a bot. It's already done in links.handler.js:533.

@poeti8 poeti8 closed this Sep 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants