# BYOK AI Visibility Tracker: ChatGPT, Perplexity, Gemini (`rationalistic_canoe/ai-visibility-audit`) Actor

Bring your own OpenAI, Perplexity or Gemini API key. Ask AI your buyers' questions through official APIs and track share of voice vs competitors, rank, citations and the pages AI cites instead of you. White-label HTML report and score card.

- **URL**: https://apify.com/rationalistic_canoe/ai-visibility-audit.md
- **Developed by:** [Oarsman AI](https://apify.com/rationalistic_canoe) (community)
- **Categories:** SEO tools, AI, Marketing
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 85.7% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $20.00 / 1,000 engine answer analyseds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## BYOK AI Visibility Tracker: ChatGPT, Perplexity, Gemini

![BYOK AI Visibility Tracker](https://api.apify.com/v2/key-value-stores/oVyHagRECuIrMkC2H/records/ai-visibility-banner)

> **Bring your own API keys (BYOK).** This Actor does not include any AI usage. You supply your own OpenAI, Perplexity and/or Google Gemini API key, and each provider bills you directly for the calls made with it. Without a key, the run is a free preview: a sample report with fictional brands plus a real AI-readiness check of your own website, $0 charged. Google AI Overviews are optional and also need your own Apify API token.

Your buyers now ask ChatGPT, Perplexity, Gemini and Google's AI Overviews which product to choose. With your keys, this Actor asks those engines your buyers' real questions and shows you, in one run:

- **whether each engine names you**, and in what position next to your competitors
- **your share of voice** and a 0–100 **AI visibility score** for each engine
- **the exact pages AI cites instead of you**: review sites, Reddit threads, blogs and competitor pages
- **a prioritised fix list** built from that evidence, plus a free AI-readiness check of your own site
- a **white-label HTML report** your client can open on any phone, and a **shareable "Does ChatGPT recommend you?" score card** (PNG)

Every answer comes from each provider's **official API**: OpenAI's Responses API with web search, Perplexity's Agent API with web search, and the Gemini API with Grounding with Google Search. Google AI Overviews (optional) come through Apify's own maintained [Google AI Overviews Scraper](https://apify.com/apify/google-ai-overviews-scraper), started with your Apify token so it bills to your account. Nothing logs into or scrapes the ChatGPT, Perplexity or Gemini apps.

This is an independent tool. It is not affiliated with, sponsored or endorsed by OpenAI, Perplexity, Google or any other provider; product names are used only to say which API is called.

**Try it free first:** run it with no keys (or turn on **Demo mode**) to get a full sample report for fictional brands plus a real AI-readiness check of your site, with no charge.

### What you get

| Output | Where | What it is |
|---|---|---|
| `REPORT.html` | Key-value store | The client-ready report: verdict, score per engine, competitor leaderboard, question-by-question matrix, pages cited instead of you, AI-readiness of your site, ranked fixes, change since last run, method notes, answer excerpts. Self-contained (no external files), responsive, prints cleanly. Dark or light theme, your agency name, logo and colour. |
| `SCORECARD.png` | Key-value store | 1200×675 score card sized for X and LinkedIn. |
| Dataset | One row per engine × question × run | Answer text, whether you were named, your position, whether your site was cited, tone, competitors named, every cited URL and domain, search queries the engine ran, and the estimated API cost of that answer. |
| `OUTPUT` | Key-value store | All scores, the leaderboard, fixes, citation gaps, discovered brands and links to the report and card, for Zapier, Make, n8n or your own dashboard. |

### How it compares

| | **BYOK AI Visibility Tracker** | Typical Store tracker | SaaS (Otterly, Semrush AI toolkit, Ahrefs Brand Radar) |
|---|---|---|---|
| Engines | ChatGPT (OpenAI web search), Perplexity, Gemini (Google Search grounding), Google AI Overviews | 2–5, often through a model router or scrapers | Varies by plan |
| How answers are collected | Official provider APIs with your own keys; AI Overviews via Apify's own actor on your token | Varies; some scrape the consumer apps | Proprietary |
| Pages AI cites instead of you, by type | Yes: review site, forum, video, publisher, competitor | Cited domains list | Yes, on higher plans |
| Prioritised fix list with evidence | Yes, each fix shows why and how | Rare | Some |
| Your site's AI-readiness | Yes: AI crawler access in robots.txt, bot-challenge detection, structured data, meta, sitemap | No | Partial |
| White-label HTML report + share card | Yes, both, every run | JSON/CSV; one offers a Markdown report | Yes, on agency plans |
| Run-to-run consistency | 1–3 runs per question, shown as k of n | Rare | Rare |
| Price | **$0.02 per analysed answer + $0.79 per report**; you pay the AI providers directly, usually about a cent per answer | $0.05–$0.35 per answer | $29–$299 a month |

### Quick start

1. Add at least one of **your own** API keys: **OpenAI**, **Perplexity** or **Gemini**. You need an account with that provider; this Actor cannot run engines without your key. Each key is a secret input: Apify stores it encrypted, and the Actor never writes it to the dataset, the report or the log.
2. Enter your **brand name** and **website**, up to 10 **competitors** (`Name | domain.com`), and either your buyers' questions or a **category** (the Actor writes buyer-intent questions for you).
3. Set **Max API spend on your keys**. The Actor stops asking new questions before it would pass it.
4. Run. Open `REPORT.html` from the Storage tab or `OUTPUT.reportUrl`.

```json
{
  "brandName": "Acme CRM",
  "brandDomain": "acmecrm.com",
  "competitors": ["HubSpot | hubspot.com", "Pipedrive | pipedrive.com", "Zoho CRM | zoho.com"],
  "category": "CRM",
  "audience": "small agencies",
  "market": "UK",
  "maxPrompts": 10,
  "openaiApiKey": "<secret>",
  "perplexityApiKey": "<secret>",
  "geminiApiKey": "<secret>",
  "includeGoogleAiOverviews": true,
  "apifyTokenForAio": "<secret, your own Apify token>",
  "samplesPerPrompt": 2,
  "maxApiSpendUsd": 1,
  "trackingName": "acme-weekly",
  "agencyName": "Brightline Growth",
  "reportTheme": "light"
}
```

**Track it weekly:** set the same `trackingName` on a weekly schedule. Each report then shows the change in score and share of voice since the previous run.

### How the score works

- **AI visibility score (0–100)** = 50% how often you are named + 25% how early you are named (1 ÷ position among tracked brands) + 25% how often your own site is cited. It is calculated per engine, and the overall score is the average across engines.
- **Share of voice** = answers naming you ÷ all answers naming any tracked brand.
- **Tone** is a transparent keyword score of the sentences that name each brand, including negation ("not expensive"). It is deterministic and costs nothing.
- **Brands you did not list** that AI keeps recommending are surfaced so you can add them as competitors.

### AI answers vary. This audit tells you by how much.

AI answers change between runs, days, locations and accounts, and API answers can differ from the consumer apps. This audit is a measured sample, not a promise of what every user sees. Set **Runs per question** to 2 or 3 to see how consistent each engine is (shown as "named in k of n runs"), and track the trend with weekly runs rather than judging any single answer.

### Costs

**This Actor (pay per event):**

- $0.02 per engine answer that is analysed
- $0.79 per audit report (HTML report, score card and fix list), charged once per run
- Demo mode, failed calls, skipped questions and empty AI Overviews are free
- The Actor keeps room for the report inside your run's maximum charge, so a capped run still delivers a report

**Your own API keys** are billed by each provider. The run's estimated spend is shown in `OUTPUT.estimatedApiSpendUsd`, and `maxApiSpendUsd` caps it.

- **OpenAI:** web search is $10 per 1,000 calls, plus tokens. With the default `gpt-6-luna` that is about $0.011 per answer.
- **Perplexity:** the Agent API at `fast` effort, billed per token plus search.
- **Gemini:** Grounding with Google Search has 5,000 free requests a month on a paid-tier key, then $14 per 1,000.
- **Google AI Overviews (optional):** runs Apify's actor with the Apify API token you paste, so it is billed to your own Apify account at that actor's Store price, capped by `aioMaxChargeUsd`. Without the token it is skipped.

A typical 10-question audit on 3 engines costs about $1.39 here plus about $0.35 on your keys.

### FAQ

**Is this scraping ChatGPT?** No. It calls OpenAI's, Perplexity's and Google's official APIs with your keys. Google AI Overviews are optional and come from Apify's own maintained actor.

**Why bring my own keys?** You pay the providers' list price with no markup, your usage stays on your accounts, and you can pick the model. This Actor never pays for or resells AI usage.

**Do I need keys for all engines?** No. One key is enough; engines without a key are skipped and listed in `OUTPUT.missingKeys`.

**Are my keys safe?** They are secret inputs, encrypted by Apify. The Actor sends each key only to its own provider's API and never writes it to the dataset, report, score card or log (this is covered by an automated test).

**Does it work for local businesses or other countries?** Yes. Set `market` ("Pune", "London") and `country` (IN, GB).

**Can I white-label it for clients?** Yes. Set `agencyName`, `logoUrl` and `accentColor`. `hideOarsmanBranding` removes the "Built with" footer.

**What if a key is wrong?** That engine stops after its first rejected call, the other engines finish, and `OUTPUT.engineErrors` says why. Rate limits and server errors are retried with backoff.

### Limits

- Consumer apps can personalise answers, so API answers are a close, repeatable proxy for them, not an identical copy.
- Gemini returns cited sources as Google redirect links. The Actor reads the source domain from each link's title.
- The site check reads public pages only and respects bot challenges: if your site challenges our checker, the report says so instead of guessing.

*Built by Oarsman AI with the help of AI coding agents. Every engine's parser is tested against fixtures in each API's documented response shape; results come only from the APIs you call with your keys.*

# Actor input Schema

## `brandName` (type: `string`):

The brand to audit, as people write it (e.g. "Notion").

## `brandDomain` (type: `string`):

Your domain (e.g. notion.so). Used to detect when AI cites your own pages and for the free AI-readiness check of your site.

## `brandAliases` (type: `array`):

Spellings, product names or old names that should count as your brand.

## `competitors` (type: `array`):

One per line as "Name | domain.com" (domain optional). Up to 10.

## `prompts` (type: `array`):

The questions your buyers ask AI, e.g. "best CRM for small agencies". Leave empty and fill Category to auto-generate them. Do not name your brand if you want an unbiased answer.

## `category` (type: `string`):

What you sell, e.g. "GST invoicing software". Used to generate buyer-intent questions when you give fewer than the maximum.

## `audience` (type: `string`):

Who buys it, e.g. "freelancers".

## `market` (type: `string`):

Where, e.g. "India" or "London".

## `maxPrompts` (type: `integer`):

Each question is asked once per engine (times the runs per question).

## `includeCompetitorPrompts` (type: `boolean`):

Captures buyers who are about to switch.

## `openaiApiKey` (type: `string`):

Your own OpenAI API key (bring your own key). Used only for the Responses API with web search; OpenAI bills you directly. Stored encrypted by Apify; never written to the dataset, report or logs.

## `perplexityApiKey` (type: `string`):

Your own Perplexity API key (bring your own key), for the Agent API with web search. Perplexity bills you directly.

## `geminiApiKey` (type: `string`):

Your own Google AI Studio key (bring your own key), Google bills you directly; for Gemini with Grounding with Google Search (needs a paid-tier key; 5,000 grounded requests a month are free on paid tier per Google's pricing page).

## `includeGoogleAiOverviews` (type: `boolean`):

Optional. Runs Apify's own Google AI Overviews Scraper (apify/google-ai-overviews-scraper) with the Apify API token you paste below, so that run is billed to your own Apify account at its Store price. Off unless you add the token.

## `apifyTokenForAio` (type: `string`):

Only needed for Google AI Overviews. Copy it from Apify Console → Settings → API & Integrations. Used only to start apify/google-ai-overviews-scraper on your account; stored encrypted and never written to the dataset, report or logs.

## `aioMaxChargeUsd` (type: `number`):

Hard cap passed to Apify for that actor's run.

## `engines` (type: `array`):

Leave empty to use every engine you gave a key for.

## `maxApiSpendUsd` (type: `number`):

Estimated spend cap across OpenAI, Perplexity and Gemini for this run. The audit stops asking new questions before it would pass this.

## `samplesPerPrompt` (type: `integer`):

AI answers vary between runs. 2–3 runs per question show how consistent each engine is (k of n).

## `country` (type: `string`):

Approximate searcher location, e.g. IN, US, GB. Passed to engines that support it.

## `trackingName` (type: `string`):

Give the same name on every run (e.g. "acme-weekly") to show the change since the previous run. Schedule it weekly.

## `runSiteCheck` (type: `boolean`):

Free check of robots.txt for AI search crawlers, homepage structured data, meta description, sitemap and llms.txt.

## `agencyName` (type: `string`):

White-label: your name replaces ours in the report header and score card.

## `logoUrl` (type: `string`):

Shown in the report header.

## `accentColor` (type: `string`):

Hex, e.g. #2563eb.

## `reportTheme` (type: `string`):

Dark matches the score card; light prints well.

## `hideOarsmanBranding` (type: `boolean`):

Only applies when an agency name is set.

## `demoMode` (type: `boolean`):

Builds a sample report from bundled answers for fictional brands, so you can see the output before adding keys. Nothing is charged.

## `openaiModel` (type: `string`):

Any Responses API model that supports the web_search tool.

## `geminiModel` (type: `string`):

Any Gemini model that supports the google_search tool.

## `perplexityEffort` (type: `string`):

Perplexity's preset; fast is closest to a normal Perplexity answer and cheapest.

## `perplexityModel` (type: `string`):

Overrides the effort preset with a specific Agent API model.

## `concurrency` (type: `integer`):

How many engine requests run at the same time.

## `maxRetries` (type: `integer`):

Retries on rate limits, timeouts and server errors, with backoff.

## `requestTimeoutSecs` (type: `integer`):

Timeout per request (s).

## `apiPricing` (type: `object`):

Optional, for the spend estimate: {"chatgpt":{"inputPerM":0.1,"outputPerM":0.5,"perSearch":0.01}}.

## Actor input object example

```json
{
  "brandName": "Invoxa",
  "brandDomain": "invoxa.example",
  "brandAliases": [],
  "competitors": [
    "Billora | billora.example",
    "LedgerLeaf | ledgerleaf.example"
  ],
  "prompts": [],
  "category": "GST invoicing software",
  "maxPrompts": 10,
  "includeCompetitorPrompts": true,
  "includeGoogleAiOverviews": false,
  "aioMaxChargeUsd": 0.25,
  "engines": [],
  "maxApiSpendUsd": 1,
  "samplesPerPrompt": 1,
  "runSiteCheck": true,
  "accentColor": "#60a5fa",
  "reportTheme": "dark",
  "hideOarsmanBranding": false,
  "demoMode": false,
  "openaiModel": "gpt-6-luna",
  "geminiModel": "gemini-3.8-flash",
  "perplexityEffort": "fast",
  "concurrency": 3,
  "maxRetries": 3,
  "requestTimeoutSecs": 120,
  "apiPricing": {}
}
```

# Actor output Schema

## `report` (type: `string`):

White-label HTML report: score, share of voice, per-engine results, competitor leaderboard, pages AI cites instead of you and a prioritised fix list.

## `scorecard` (type: `string`):

Shareable 1200×675 score card image.

## `results` (type: `string`):

One item per engine answer in the default dataset, overview table view.

## `summary` (type: `string`):

Overall score, share of voice, per-engine stats, leaderboard, fixes, site check, week-over-week delta and charges, stored as the OUTPUT record.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "brandName": "Invoxa",
    "brandDomain": "invoxa.example",
    "competitors": [
        "Billora | billora.example",
        "LedgerLeaf | ledgerleaf.example"
    ],
    "category": "GST invoicing software"
};

// Run the Actor and wait for it to finish
const run = await client.actor("rationalistic_canoe/ai-visibility-audit").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "brandName": "Invoxa",
    "brandDomain": "invoxa.example",
    "competitors": [
        "Billora | billora.example",
        "LedgerLeaf | ledgerleaf.example",
    ],
    "category": "GST invoicing software",
}

# Run the Actor and wait for it to finish
run = client.actor("rationalistic_canoe/ai-visibility-audit").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "brandName": "Invoxa",
  "brandDomain": "invoxa.example",
  "competitors": [
    "Billora | billora.example",
    "LedgerLeaf | ledgerleaf.example"
  ],
  "category": "GST invoicing software"
}' |
apify call rationalistic_canoe/ai-visibility-audit --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,rationalistic_canoe/ai-visibility-audit"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/eRwdOKzXeEijgvF5J/builds/TtY0DiARbrdc6XtJE/openapi.json
