Quick Start Guide
This guide will help you get up and running with DarkForest Protocol in just a few minutes.
Getting an API Key
Before implementing DarkForest Protocol, you'll need to register for an API key:
- Visit https://darkestforest.xyz
- Enter your email address and website domain on the Protocol page
- Click "Register" to receive your API key
Your API key will be shown immediately. This key is used to authenticate your requests to the DarkForest API and track analytics for your website.
Choosing an Integration Method
DarkForest Protocol offers three integration methods:
1. Reverse Proxy Integration (Simplest)
If you're using Nginx, Apache, Cloudflare, or another proxy server, this is the easiest way to implement DarkForest Protocol. You'll add a few lines to your server configuration to detect and redirect AI bots.
View Reverse Proxy Integration Guide
2. Middleware Integration (Recommended)
If you're using a supported web framework like Express, Next.js, or Vercel Edge, you can use our middleware package for a clean integration.
Install the DarkForest blocker package:
npm install darkforest-blocker
Then add the middleware to your application:
// Express example
const { createExpressBlocker } = require('darkforest-blocker/express');
const darkforestMiddleware = createExpressBlocker({
apiKey: 'your-api-key',
presetCategories: ['ai-search-bots', 'ai-crawl-bots']
});
app.use(darkforestMiddleware);
View Middleware Integration Guide
3. Universal Integration (Advanced)
For custom implementations in any language or framework, you can use our universal integration approach.
View Universal Integration Guide
Verifying Your Implementation
To verify that DarkForest Protocol is working correctly:
- Use a tool like cURL to simulate an AI bot request:
curl -A "GPTBot" https://your-website.com
-
You should be redirected to the DarkForest API with a message for AI bots.
-
Check your DarkForest analytics dashboard to see the recorded visit.
Next Steps
- Learn about bot patterns to understand which AI systems are detected
- Explore configuration options to customize your implementation
- View your analytics dashboard to track AI bot visits