# AI Brand Visibility Monitor (`nxv107/ai-brand-visibility-monitor`) Actor

Track whether your brand appears in AI answers, which competitors get mentioned, and which sources are cited.

- **URL**: https://apify.com/nxv107/ai-brand-visibility-monitor.md
- **Developed by:** [Navpreet Singh](https://apify.com/nxv107) (community)
- **Categories:** AI, Marketing, SEO tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

$10.00 / 1,000 brand visibility checks

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## AI Brand Visibility Monitor

Track how a brand and its competitors appear in AI answers and cited sources.

This Actor is built for SaaS founders, SEO agencies, content teams, and product marketers who want repeatable "AI answer visibility" checks without scraping consumer AI accounts.

### What It Does

- Runs brand-neutral prompts against a configured AI/search provider.
- Measures whether the tracked brand appears.
- Counts competitor mentions.
- Calculates share of voice across tracked entities.
- Captures first mention rank, citations, citation domains, and search results when the provider returns them.
- Flags gaps such as competitors appearing while the tracked brand is absent.

### Providers

`demo` is the default so the Actor can run without secrets for Apify Store testing.

For real checks, use:

- `perplexity`: calls Perplexity Sonar API at `https://api.perplexity.ai/v1/sonar`.
- `openai-compatible`: calls a configurable OpenAI-compatible `/chat/completions` endpoint.

API keys can be supplied in the `apiKey` input field or through `PERPLEXITY_API_KEY` / `AI_PROVIDER_API_KEY`.

### Input

- `brand`: tracked brand or product.
- `website`: optional brand website.
- `brandAliases`: extra names that count as brand mentions.
- `competitors`: competitor names to compare.
- `prompts`: questions to ask the provider.
- `provider`: `demo`, `perplexity`, or `openai-compatible`.
- `model`: provider model, default `sonar`.

Keep prompts brand-neutral when measuring visibility. For example, prefer "What are the best web data extraction platforms for AI agents?" over "Is Apify a good web data extraction platform?"

### Output

Each dataset row represents one prompt/provider visibility check:

- brand mention status and mention count;
- competitor mention counts;
- first mention rank;
- share of voice;
- simple sentiment near the brand mention;
- citations and citation domains;
- source search results when available;
- raw answer when enabled.

### Pricing Hypothesis

Pay-per-event: `$0.005-$0.02` per completed prompt/provider visibility check.

Suggested first public price: `$0.01` per completed check, then adjust based on run cost and usage.

### Run Locally

```bash
pnpm install
pnpm test
pnpm smoke
pnpm start
````

# Actor input Schema

## `brand` (type: `string`):

Brand, product, or company name to track in AI answers.

## `website` (type: `string`):

Optional website for the tracked brand.

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

Optional alternate names to count as the tracked brand.

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

Competitor names to compare against the tracked brand.

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

Market questions to ask the provider. Keep these brand-neutral for cleaner visibility measurement.

## `provider` (type: `string`):

Use demo for the sample run. Use perplexity or openai-compatible for real checks.

## `apiKey` (type: `string`):

Required for perplexity or openai-compatible provider. You can also set PERPLEXITY\_API\_KEY or AI\_PROVIDER\_API\_KEY as an environment variable.

## `apiBaseUrl` (type: `string`):

Only used for openai-compatible provider.

## `apiEndpointPath` (type: `string`):

Only used for openai-compatible provider.

## `model` (type: `string`):

Provider model. Perplexity's default is sonar.

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

Maximum prompts to check in one run.

## `maxTokens` (type: `integer`):

Maximum tokens the provider should use for each answer.

## `temperature` (type: `number`):

Sampling temperature passed to the provider.

## `includeRawAnswer` (type: `boolean`):

Include the full provider answer in each dataset row.

## Actor input object example

```json
{
  "brand": "Apify",
  "website": "https://apify.com",
  "brandAliases": [
    "Apify Store",
    "Apify Actors"
  ],
  "competitors": [
    "Browse AI",
    "PhantomBuster",
    "Bright Data"
  ],
  "prompts": [
    "What are the best web data extraction platforms for AI agents?",
    "Which tools should a growth team use to monitor web data and competitors?",
    "What are reliable alternatives for building web automation and scraping workflows?"
  ],
  "provider": "demo",
  "apiBaseUrl": "https://api.perplexity.ai",
  "apiEndpointPath": "/chat/completions",
  "model": "sonar",
  "maxPrompts": 10,
  "maxTokens": 1200,
  "temperature": 0.2,
  "includeRawAnswer": true
}
```

# 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 = {
    "brandAliases": [
        "Apify Store",
        "Apify Actors"
    ],
    "competitors": [
        "Browse AI",
        "PhantomBuster",
        "Bright Data"
    ],
    "prompts": [
        "What are the best web data extraction platforms for AI agents?",
        "Which tools should a growth team use to monitor web data and competitors?",
        "What are reliable alternatives for building web automation and scraping workflows?"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("nxv107/ai-brand-visibility-monitor").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 = {
    "brandAliases": [
        "Apify Store",
        "Apify Actors",
    ],
    "competitors": [
        "Browse AI",
        "PhantomBuster",
        "Bright Data",
    ],
    "prompts": [
        "What are the best web data extraction platforms for AI agents?",
        "Which tools should a growth team use to monitor web data and competitors?",
        "What are reliable alternatives for building web automation and scraping workflows?",
    ],
}

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

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

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

```

## CLI example

```bash
echo '{
  "brandAliases": [
    "Apify Store",
    "Apify Actors"
  ],
  "competitors": [
    "Browse AI",
    "PhantomBuster",
    "Bright Data"
  ],
  "prompts": [
    "What are the best web data extraction platforms for AI agents?",
    "Which tools should a growth team use to monitor web data and competitors?",
    "What are reliable alternatives for building web automation and scraping workflows?"
  ]
}' |
apify call nxv107/ai-brand-visibility-monitor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=nxv107/ai-brand-visibility-monitor",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "AI Brand Visibility Monitor",
        "description": "Track whether your brand appears in AI answers, which competitors get mentioned, and which sources are cited.",
        "version": "0.1",
        "x-build-id": "wi02GiuPQdrx8mmnd"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/nxv107~ai-brand-visibility-monitor/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-nxv107-ai-brand-visibility-monitor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/nxv107~ai-brand-visibility-monitor/runs": {
            "post": {
                "operationId": "runs-sync-nxv107-ai-brand-visibility-monitor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/nxv107~ai-brand-visibility-monitor/run-sync": {
            "post": {
                "operationId": "run-sync-nxv107-ai-brand-visibility-monitor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "brand"
                ],
                "properties": {
                    "brand": {
                        "title": "Brand",
                        "type": "string",
                        "description": "Brand, product, or company name to track in AI answers.",
                        "default": "Apify"
                    },
                    "website": {
                        "title": "Website",
                        "type": "string",
                        "description": "Optional website for the tracked brand.",
                        "default": "https://apify.com"
                    },
                    "brandAliases": {
                        "title": "Brand aliases",
                        "type": "array",
                        "description": "Optional alternate names to count as the tracked brand.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "competitors": {
                        "title": "Competitors",
                        "type": "array",
                        "description": "Competitor names to compare against the tracked brand.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "prompts": {
                        "title": "Prompts",
                        "type": "array",
                        "description": "Market questions to ask the provider. Keep these brand-neutral for cleaner visibility measurement.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "provider": {
                        "title": "Provider",
                        "enum": [
                            "demo",
                            "perplexity",
                            "openai-compatible"
                        ],
                        "type": "string",
                        "description": "Use demo for the sample run. Use perplexity or openai-compatible for real checks.",
                        "default": "demo"
                    },
                    "apiKey": {
                        "title": "API key",
                        "type": "string",
                        "description": "Required for perplexity or openai-compatible provider. You can also set PERPLEXITY_API_KEY or AI_PROVIDER_API_KEY as an environment variable."
                    },
                    "apiBaseUrl": {
                        "title": "OpenAI-compatible base URL",
                        "type": "string",
                        "description": "Only used for openai-compatible provider.",
                        "default": "https://api.perplexity.ai"
                    },
                    "apiEndpointPath": {
                        "title": "OpenAI-compatible endpoint path",
                        "type": "string",
                        "description": "Only used for openai-compatible provider.",
                        "default": "/chat/completions"
                    },
                    "model": {
                        "title": "Model",
                        "type": "string",
                        "description": "Provider model. Perplexity's default is sonar.",
                        "default": "sonar"
                    },
                    "maxPrompts": {
                        "title": "Maximum prompts",
                        "minimum": 1,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Maximum prompts to check in one run.",
                        "default": 10
                    },
                    "maxTokens": {
                        "title": "Maximum answer tokens",
                        "minimum": 200,
                        "maximum": 4000,
                        "type": "integer",
                        "description": "Maximum tokens the provider should use for each answer.",
                        "default": 1200
                    },
                    "temperature": {
                        "title": "Temperature",
                        "minimum": 0,
                        "maximum": 2,
                        "type": "number",
                        "description": "Sampling temperature passed to the provider.",
                        "default": 0.2
                    },
                    "includeRawAnswer": {
                        "title": "Include raw answer",
                        "type": "boolean",
                        "description": "Include the full provider answer in each dataset row.",
                        "default": true
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
