API reference

Serge API

Scan any domain for agent readiness and retrieve detailed results programmatically. Two endpoints. Anonymous access at 10 scans/hr, or authenticate with a secret key for 60 scans/hr.

Base URL

https://serge.ai

Authentication

The Serge API works without authentication at 10 scans/hr. For higher limits, pass a secret key via the Authorization header:

Authorization: Bearer sk_serge_your_key_here

Create secret keys in your account settings. Keys use the sk_serge_ prefix. Treat them like passwords.

Rate limits

All API responses include rate limit headers:

HeaderDescription
X-RateLimit-LimitMax requests per window
X-RateLimit-RemainingRequests remaining
X-RateLimit-ResetUnix timestamp when window resets
Retry-AfterSeconds until reset (429 responses only)
TierRate limitAuth
Anonymous10 scans/hr per IPNone
Authenticated60 scans/hr per workspaceAuthorization: Bearer sk_serge_...

Domain rate limit: 5 scans per hour per target domain (shared across tiers).

Endpoints

POST/api/scan

Initiate a domain scan. Returns a Server-Sent Events stream with real-time progress as each of the 6 layers is scanned.

Request body
{
  "domain": "stripe.com"
}
SSE events
statusScan phase update — includes current phase description
crawlCrawl progress — includes URL being crawled and status
layerLayer scan completed — includes layer number, score, and check results
completeScan finished — includes scan ID, overall score, and per-layer breakdown
errorScan failed — includes error message
Example (anonymous)
curl -N -X POST https://serge.ai/api/scan \
  -H "Content-Type: application/json" \
  -d '{"domain": "stripe.com"}'
Example (authenticated — 60 scans/hr)
curl -N -X POST https://serge.ai/api/scan \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer sk_serge_your_key_here" \
  -d '{"domain": "stripe.com"}'
GET/api/scan/{id}

Retrieve the full results for a completed scan. Responses are cached for 1 hour.

Path parameters
idUUID of the scan (returned by the complete SSE event)
Response
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "domain": "stripe.com",
  "overallScore": 72,
  "layerScores": {
    "discovery": 83,
    "schema": 90,
    "protocol": 65,
    "auth": 60,
    "behavior": 55,
    "pricing": 40
  },
  "checkResults": [
    {
      "layer": 1,
      "key": "llms_txt",
      "status": "pass",
      "message": "llms.txt found with 15 lines",
      "fix": null,
      "evidence": { "lineCount": 15 }
    }
  ],
  "createdAt": "2026-03-24T10:00:00Z",
  "lastSeenAt": "2026-03-24T10:00:00Z",
  "seenCount": 1
}
Error responses
400Invalid scan ID format
404Scan not found
Example
curl https://serge.ai/api/scan/550e8400-e29b-41d4-a716-446655440000

Webhook events

Serge can notify you when a monitored domain's score changes. Subscribe to score change notifications via the email gate on any scan result page.

score.changed
{
  "event": "score.changed",
  "domain": "example.com",
  "oldScore": 31,
  "newScore": 45,
  "timestamp": "2026-03-24T06:00:00Z"
}

Machine-readable resources

/openapi.jsonOpenAPI 3.1 specification
/llms.txtProduct description for LLMs
/llms-full.txtExtended documentation for LLMs
/.well-known/agent.jsonA2A agent card with capabilities
/docs/mcp-serverMCP server (Claude Desktop extension) documentation
/sitemap.xmlXML sitemap
/robots.txtCrawler permissions