Build on Prompted
Pull AI visibility, citations and opportunities into your own dashboards, BI tools and workflows. One REST API, JSON everywhere, and an MCP server for your AI assistant.
api.promptedbrand.comQuickstart
From zero to your first visibility number in about five minutes.
- 1Create an API keyIn the app, open Settings › API keys and create a key (you need API access: admins have it, others get it from an admin in Settings › Team). Keys start with
pb_live_. Agencies create keys in Agency settings; one key reads every client.Create API key - 2Make your first requestSend the key as a Bearer token. Every response is JSON; lists are paginated with a cursor.
- 3Or try it without a keySigned in with API access? Every reference page has a Try it panel that runs real requests on your own data.
curl https://api.promptedbrand.com/brands \
-H "Authorization: Bearer $PB_API_KEY"{
"object": "list",
"data": [
{
"id": "brd_8f2kq1d9a0e44b6c9a1f0e2d3c4b5a69",
"object": "brand",
"name": "Northwind",
"domain": "northwind.com",
"engines": [
"chatgpt",
"perplexity",
"gemini"
],
"markets": [
"US"
],
"created": "2026-09-19T16:52:37Z"
}
],
"has_more": false,
"next_cursor": null
}Explore the API
Base URL https://api.promptedbrand.com. All endpoints return JSON, use ISO 8601 dates and are versioned by date. Ids are prefixed by type: brd_, prm_, ans_, scn_, top_, cmp_, opp_, cnt_, whk_. Changes take a JSON body with Content-Type: application/json.
Authentication
Send your secret key in the Authorization header on every request. Keep it on your server. When you create a key you choose what it can do: Read only, or Read & write (needed to add prompts, start scans and manage webhooks). Revoke a key in Settings › API keys at any time.
Authorization: Bearer pb_live_••••••••••••3f9aA workspace key reads that brand. An agency key reads every active client; pass brand_id to choose one (list them with GET /brands).
Errors
Errors use standard HTTP codes and a JSON body with a machine-readable code, a message and a request_id to quote if you contact us.
| Status | Code | Meaning |
|---|---|---|
| 400 | invalid_request | A parameter is missing or malformed. |
| 401 | unauthorized | The API key is missing, revoked or wrong. |
| 403 | forbidden | Your role or the key doesn’t include this. |
| 402 | out_of_credits | The brand has used this month’s AI credits. They reset on the 1st (UTC), or add credits in Settings › Billing. |
| 404 | not_found | The resource doesn’t exist, or the key can’t see it. |
| 409 | conflict | The change can’t be made right now: a limit is reached or a scan is running. `code` says which. |
| 429 | rate_limited | Too many requests. Retry after the seconds in Retry-After. |
{
"error": {
"type": "authentication_error",
"code": "unauthorized",
"message": "No valid API key provided.",
"request_id": "req_9Qm2xA1b"
}
}Rate limits
60 requests a minute per key (and per person trying the API signed in), on every plan. Every response carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset (seconds). A 429 includes Retry-After.
Pagination
Lists return { object: "list", data, has_more, next_cursor }. Pass limit (1 to 100) and, for the next page, cursor=next_cursor. Prompts, answers and scans use cursors; shorter lists come in one page.
Versioning
The API is versioned by date: 2026-10-01 (sent back in the Prompted-Version header). We only add fields and endpoints within a version; anything that would break your code gets a new dated version and notice in the changelog. The full spec is at /openapi.json (OpenAPI 3.1).
Webhooks
Get events as they happen instead of polling. Add an endpoint in Settings › API keys (agencies: Agency settings, for every client at once) or with POST /webhooks. We POST a JSON event to your https URL; answer with any 2xx within 10 seconds.
scan.completedScan finishedA scan run closed: the first scan, a daily scan or one you started. status is done, partial (some answers failed) or failed; visibility is this run’s score, 0 to 100.{
"id": "evt_q3Lx…",
"object": "event",
"type": "scan.completed",
"created": "2026-10-14T04:06:42Z",
"data": {
"brand_id": "brd_8f2kq1…",
"scan_id": "scn_71bd…",
"kind": "daily",
"status": "done",
"answers": 50,
"visibility": 42.5
}
}competitor.overtookCompetitor overtook youIn a daily scan, a competitor was named ahead of you on a prompt where you were in the top 3. One event per prompt and engine, up to 10 per scan. Positions are 1-based; your_position_now is null when you’re no longer named.{
"id": "evt_q3Lx…",
"object": "event",
"type": "competitor.overtook",
"created": "2026-10-14T04:06:42Z",
"data": {
"brand_id": "brd_8f2kq1…",
"competitor": "Trailhead Co",
"engine": "chatgpt",
"prompt_id": "prm_5c1e…",
"prompt": "best trail running shoes for beginners",
"answer_id": "ans_0f4a…",
"your_position_before": 1,
"your_position_now": 2,
"competitor_position": 1
}
}opportunity.createdNew opportunityA scan found something new to fix or win: a content gap, a citation gap, a crawl block or a wrong fact. Up to 10 per scan; the rest are in List opportunities.{
"id": "evt_q3Lx…",
"object": "event",
"type": "opportunity.created",
"created": "2026-10-14T04:06:42Z",
"data": {
"brand_id": "brd_8f2kq1…",
"opportunity_id": "opp_6b3d…",
"type": "content",
"subject": "Trail running shoes for wide feet",
"impact": "high",
"gain": 6.5
}
}Each request carries PB-Event-Id, PB-Event-Type and PB-Signature: t=<unix time>,v1=<hex>, an HMAC SHA-256 of <t>.<raw body> with your endpoint’s whsec_… secret. Check it, and reject old timestamps, before trusting the event.
import crypto from "node:crypto";
// raw = the request body exactly as received (a string, before JSON.parse)
export function verify(raw, header, secret) {
const parts = Object.fromEntries(header.split(",").map((p) => p.split("=")));
if (Math.abs(Date.now() / 1000 - Number(parts.t)) > 300) return false; // older than 5 minutes
const expected = crypto.createHmac("sha256", secret).update(`${parts.t}.${raw}`).digest("hex");
const given = Buffer.from(parts.v1 ?? "");
return given.length === expected.length && crypto.timingSafeEqual(Buffer.from(expected), given);
}A delivery that fails (no 2xx, a timeout or a redirect) is retried for about 24 hours with growing gaps. The same event can arrive twice: use PB-Event-Id to skip repeats. After 5 events in a row that never got through, the endpoint is turned off; turn it back on in Settings once it’s fixed.
MCP server
Ask your AI assistant about your AI visibility. The Prompted MCP server gives Claude, ChatGPT, Claude Code, Cursor, Codex and any other client that supports remote MCP servers the same data as the API: sign in with your Prompted login, or use your API key.
https://mcp.promptedbrand.com/mcpMCP docsclaude mcp add --transport http prompted https://mcp.promptedbrand.com/mcp \
--header "Authorization: Bearer $PB_API_KEY"Coming soon
- Reports
- Official Node.js and Python SDKs
Changelog
/v1: https://api.promptedbrand.com/brands, https://api.promptedbrand.com/openapi.json. Old /v1/… addresses keep working, so nothing breaks.get_portfolio tool. Nothing existing changed.402 out_of_credits. The MCP server gets every new endpoint as a tool; a Read only key still sees only the read tools. Nothing existing changed.scan.completed, competitor.overtook, opportunity.created). Keys can now allow changes. Nothing existing changed.