AnswerEngine · API Reference
API Reference
REST API for AnswerEngine. Available on the Scale plan and above. Authenticate with an API key generated at /platform/dashboard/api-keys.
Authentication
Every request must include an Authorization header with a Bearer API key.
Authorization: Bearer ae_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Keys are SHA-256 hashed at rest. The plaintext is shown once at creation and never recoverable — store it in your secret manager.
Rate limits
600 requests per hour per organization across all v1 endpoints. 429 with Retry-After header on overflow.
Endpoints
/api/v1/sitesList all sites owned by the authenticated org with summary stats.
curl -H "Authorization: Bearer ae_xxxxx" \ https://bacwaterdepot.com/api/v1/sites
/api/v1/citations?siteId=&engine=&from=&to=&limit=List AI citation results. All query params optional. siteId and engine filter results; from/to are ISO date strings; limit max 500.
curl -H "Authorization: Bearer ae_xxxxx" \ "https://bacwaterdepot.com/api/v1/citations?engine=perplexity&limit=50"
/api/v1/keywords?siteId=List keywords. Optional siteId filter.
curl -H "Authorization: Bearer ae_xxxxx" \ "https://bacwaterdepot.com/api/v1/keywords?siteId=42"
/api/v1/keywordsAdd a keyword to a site. siteId + query required. intent: informational | commercial | transactional | branded.
{
"siteId": 42,
"query": "best CRM for startups",
"intent": "commercial",
"priority": 80
}Webhooks
Subscribe to events at /platform/dashboard/webhooks. Every delivery includes X-AnswerEngine-Signature — HMAC-SHA256 of the body using your webhook secret.
citation.winFired the first time a tracked query gets cited by an AI engine.
scan.completeFired when a site scan finishes.
page.publishedFired when content-engine drafts a new page.
page.liveFired when a customer marks a page as live (and CMS push succeeds).
reddit.draftFired when the Reddit answer-radar generates a new draft for review.
Verify in Node.js:
import { createHmac } from "node:crypto";
const expected = createHmac("sha256", WEBHOOK_SECRET).update(rawBody).digest("hex");
if (expected !== req.headers["x-answerengine-signature"]) {
return res.status(401).end();
}