{
  "openapi": "3.0.1",
  "info": {
    "title": "AI Visibility Tracker: ChatGPT, Perplexity, Gemini, Claude,Grok",
    "description": "Track whether ChatGPT, Perplexity, Gemini, Claude and Grok recommend your brand or your competitors. Live web search, visibility score, share of voice, sentiment, cited sources, new competitors and week-over-week changes.",
    "version": "0.1",
    "x-build-id": "qA4Ws3kKtlfHGxGIu"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/agrawals~ai-search-visibility-tracker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-agrawals-ai-search-visibility-tracker",
        "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/agrawals~ai-search-visibility-tracker/runs": {
      "post": {
        "operationId": "runs-sync-agrawals-ai-search-visibility-tracker",
        "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/agrawals~ai-search-visibility-tracker/run-sync": {
      "post": {
        "operationId": "run-sync-agrawals-ai-search-visibility-tracker",
        "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": "Your brand",
            "type": "string",
            "description": "The brand or product to track, exactly as buyers would write it."
          },
          "brandAliases": {
            "title": "Brand aliases",
            "type": "array",
            "description": "Other names AI might use for your brand, such as a product line or short name. Matching is case-insensitive and whole-word.",
            "items": {
              "type": "string"
            }
          },
          "brandDomain": {
            "title": "Brand website domain",
            "type": "string",
            "description": "Your domain, e.g. example.com. Used to check whether AI cites your own site as a source."
          },
          "category": {
            "title": "What you sell (category)",
            "type": "string",
            "description": "A few words describing your product category, e.g. 'maintenance management software (CMMS)' or 'project management tool for agencies'. Used to generate buyer questions and to spot new competitors."
          },
          "competitors": {
            "title": "Competitors",
            "type": "array",
            "description": "One competitor per line. Optional aliases and domain with this format: Name | alias 1, alias 2 | domain.com",
            "items": {
              "type": "string"
            }
          },
          "prompts": {
            "title": "Buyer questions (prompts)",
            "type": "array",
            "description": "The questions your buyers ask AI assistants, one per line. Up to 25 in total, including any generated ones. Leave empty and set 'Generate buyer questions' to have them written for you.",
            "items": {
              "type": "string"
            }
          },
          "autoGeneratePrompts": {
            "title": "Generate buyer questions",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "Number of extra buyer-intent questions to write automatically from your category and competitors. Free. Generated questions are listed in the report.",
            "default": 0
          },
          "engines": {
            "title": "AI engines",
            "type": "array",
            "description": "Which AI assistants to test. Each answers with live web search, the way buyers use them.",
            "items": {
              "type": "string",
              "enum": [
                "chatgpt",
                "gemini",
                "perplexity",
                "claude",
                "grok"
              ],
              "enumTitles": [
                "ChatGPT (OpenAI)",
                "Gemini (Google)",
                "Perplexity",
                "Claude (Anthropic)",
                "Grok (xAI)"
              ]
            },
            "default": [
              "chatgpt",
              "gemini",
              "perplexity",
              "claude"
            ]
          },
          "runsPerPrompt": {
            "title": "Runs per prompt",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "AI answers change from run to run, so each prompt is asked several times; the report shows a 95% range. 3-5 is a good balance. Total answers = prompts x engines x runs.",
            "default": 3
          },
          "country": {
            "title": "Buyer country",
            "type": "string",
            "description": "Two-letter country code for where your buyers are (e.g. US, CA, GB, IN). Passed to each engine as the user's approximate location.",
            "default": "US"
          },
          "includeFullAnswers": {
            "title": "Include full answer text",
            "type": "boolean",
            "description": "Store the full AI answer in each result row. Turn off for smaller datasets; a short excerpt is always kept.",
            "default": true
          },
          "aiAnalysis": {
            "title": "AI analysis (sentiment, recommendations, new competitors)",
            "type": "boolean",
            "description": "For each answer, record whether each brand is recommended or just mentioned, its sentiment, other brands the AI suggests that you didn't list, and claims made about your brand. Free.",
            "default": true
          },
          "trackChanges": {
            "title": "Compare with my previous run",
            "type": "boolean",
            "description": "Saves a summary of each run in your Apify account and shows what changed since the last run with the same tracking ID: score, mentions per engine, new competitors, new or lost sources.",
            "default": true
          },
          "trackingId": {
            "title": "Tracking ID",
            "type": "string",
            "description": "Name for the history this run is compared against. Defaults to brand + country. Use a different ID per client or market."
          },
          "openaiApiKey": {
            "title": "Your OpenAI API key (optional)",
            "type": "string",
            "description": "Bring your own key to pay the AI provider directly and get the lower per-answer price. Leave empty to use the built-in key."
          },
          "geminiApiKey": {
            "title": "Your Google Gemini API key (optional)",
            "type": "string",
            "description": "Leave empty to use the built-in key."
          },
          "perplexityApiKey": {
            "title": "Your Perplexity API key (optional)",
            "type": "string",
            "description": "Leave empty to use the built-in key."
          },
          "anthropicApiKey": {
            "title": "Your Anthropic API key (optional)",
            "type": "string",
            "description": "Leave empty to use the built-in key."
          },
          "xaiApiKey": {
            "title": "Your xAI (Grok) API key (optional)",
            "type": "string",
            "description": "Leave empty to use the built-in key."
          }
        }
      },
      "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}