Loading
Code Deb

Code Deb AI Discovery

Classify AI assistant referrers and claimed/verified bot activity. Aggregate visits by source and evidence confidence. TypeScript examples, API reference and installation guidance.

Technical documentation for 27 Code Deb JavaScript and TypeScript SDKs, Verify and MCP APIs and the developer platform. Browse API references, authentic implementation examples and provider boundaries. Check actual npm availability before installing.

Target release: @codedeb/ai-discovery@0.1.0 passed isolated ESM installation and TypeScript consumer checks; public npm availability has not yet been independently verified.

AI search referrals and verified crawler evidence — intended for developers building reliable storefronts, search infrastructure and production applications. Unlike a hosted platform, the SDK does not require a Code Deb account for its pure functions.

Build, test and stage

npm ci
npm run test:nepal-sdks
npm run sdk:pack:verify
node scripts/sdk/stage-npm-package.mjs sdk-ai-discovery

These commands prepare the candidate without publishing it. Review the generated .sdk-artifacts/npm-stage/sdk-ai-discovery contents and all licenses. After a successful, independently verified npm release, the installation command will be npm install @codedeb/ai-discovery. Do not advertise this command as publicly working before release verification.

Quickstart using implemented exports

import {classifyAiVisit} from '@codedeb/ai-discovery';
const result=classifyAiVisit({timestamp:'2026-11-21',path:'/products',referrer:'https://chatgpt.com/'});
console.log(result.confidence,result.kind);

Public API contract

Entry point or functionResponsibility
classifyAiVisit(visit)Categorize AI referrers, claimed crawler UAs and caller-verified bots
summarizeAiDiscovery(visits)Aggregate source and evidence-confidence counts

Production integration

A User-Agent can be forged and a referral need not imply an LLM cited content. Verify crawlers using provider-published methods and avoid logging raw user queries or identifiers. Google-Extended is a robots control token, not a crawler.

The published SDK must have bounded resource use, correct authentication boundaries where applicable, and tests for malformed input. Caller-owned storage, OAuth, background jobs or hosted services must be configured explicitly rather than invented by the library.

Compatibility and release history

  • 0.1.0 candidate — 21 November 2026: First implementation of the documented independent module, subject to the complete release gate.
  • JavaScript ESM with generated TypeScript declarations; Node.js 20+ for Node execution.
  • No npm publication, hosted API, SLA, vendor certification, ranking guarantee or customer data access is implied by this candidate.
  • Code Deb-owned package code is intended for Apache-2.0 distribution. Third-party dependencies, data and trademarks retain their own terms.

Implementation workflow

  1. Collect privacy-reviewed first-party referrer and request evidence.
  2. Separate confirmed referrers from spoofable crawler User-Agent claims.
  3. Verify bot identity independently before marking it authenticated.
  4. Never equate a referral count with model citations or an answer-engine ranking.

Registry verification and installation

npm view @codedeb/ai-discovery@0.1.0 version
# Install when the target release is listed and its tarball is retrievable:
npm install @codedeb/ai-discovery@0.1.0

A valid local package is not automatically a live npm release. A verified publication must expose version metadata, a current dist-tag and a public tarball. Keep installation versions pinned and check the included distribution license.

Production acceptance criteria

  • Verify normal, corrupted, missing and boundary inputs with the actual package exports.
  • Keep any secrets, authorization and persistent state in application-owned server adapters.
  • Record explicit classifications, retry outcomes or regression evidence without turning unknown into verified.
  • Audit access limits, failure handling and operational monitoring independently of the SDK.

Troubleshooting

Registry 404: Confirm the intended version on npm, and do not assume publication from local test output. Unexpected classification or diff: Review the original evidence fields and source data. External processing problem: Inspect your event store, browser runner, authenticated client or queue; the SDK is a library, not a hosted processing service.

search console · seo · Developer SDKs · Technical resources

More from Code Deb

Read about our agency, explore available services, or contact the team for a project discussion.