{
  "openapi": "3.0.1",
  "info": {
    "title": "AI Brand Visibility & Citation Audit API",
    "description": "Audit how your brand and competitors appear in OpenAI and Claude web-search API answers. Capture mentions, citations, competitor gaps, cited domains, answer coverage, and inspectable evidence. BYOK. Only completed provider observations are billed",
    "version": "0.0",
    "x-build-id": "xfQWSHYIK7fzruvNb"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/overbifrost~ai-brand-visibility-citation-audit-api/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-overbifrost-ai-brand-visibility-citation-audit-api",
        "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/overbifrost~ai-brand-visibility-citation-audit-api/runs": {
      "post": {
        "operationId": "runs-sync-overbifrost-ai-brand-visibility-citation-audit-api",
        "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/overbifrost~ai-brand-visibility-citation-audit-api/run-sync": {
      "post": {
        "operationId": "run-sync-overbifrost-ai-brand-visibility-citation-audit-api",
        "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": [
          "prompts",
          "target",
          "surfaces"
        ],
        "properties": {
          "prompts": {
            "title": "Prompts to audit",
            "minItems": 1,
            "maxItems": 500,
            "type": "array",
            "description": "Exact questions to send to the selected AI answer surfaces. CiteGap never generates, rewrites, or expands your prompts.",
            "items": {
              "type": "string"
            }
          },
          "target": {
            "title": "Target brand",
            "required": [
              "id",
              "canonicalName"
            ],
            "type": "object",
            "description": "Explicit identity of the brand or domain you want to audit. Matching is deterministic; CiteGap does not guess aliases or ownership.",
            "properties": {
              "id": {
                "title": "Target ID",
                "type": "string",
                "description": "Stable machine-readable ID used in output.",
                "editor": "textfield",
                "minLength": 1,
                "maxLength": 120
              },
              "canonicalName": {
                "title": "Brand name",
                "type": "string",
                "description": "Primary brand or entity name used for exact normalized matching.",
                "editor": "textfield",
                "minLength": 1,
                "maxLength": 300
              },
              "aliases": {
                "title": "Aliases",
                "type": "array",
                "description": "Optional explicit alternate names. No fuzzy aliases are inferred.",
                "editor": "stringList",
                "maxItems": 50
              },
              "domains": {
                "title": "Owned domains",
                "type": "array",
                "description": "Domains that count as target citations, for example example.com.",
                "editor": "stringList",
                "maxItems": 50
              }
            },
            "additionalProperties": false
          },
          "competitors": {
            "title": "Competitors",
            "maxItems": 100,
            "type": "array",
            "description": "Optional explicit competitors for mention/citation gap findings. CiteGap does not discover competitors automatically.",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "title": "Competitor ID",
                  "type": "string",
                  "description": "Stable competitor ID.",
                  "editor": "textfield",
                  "minLength": 1,
                  "maxLength": 120
                },
                "canonicalName": {
                  "title": "Competitor name",
                  "type": "string",
                  "description": "Primary competitor name.",
                  "editor": "textfield",
                  "minLength": 1,
                  "maxLength": 300
                },
                "aliases": {
                  "title": "Aliases",
                  "type": "array",
                  "description": "Optional explicit alternate names.",
                  "editor": "stringList",
                  "maxItems": 50
                },
                "domains": {
                  "title": "Competitor domains",
                  "type": "array",
                  "description": "Domains that count as competitor citations.",
                  "editor": "stringList",
                  "maxItems": 50
                }
              },
              "required": [
                "id",
                "canonicalName"
              ],
              "additionalProperties": false
            }
          },
          "surfaces": {
            "title": "AI answer surfaces",
            "minItems": 1,
            "uniqueItems": true,
            "type": "array",
            "description": "Choose one or more supported provider API surfaces. Each selected surface needs its own BYOK credential for live acquisition; without it, that observation is returned as NOT_RUN and is not charged.",
            "items": {
              "type": "string",
              "enum": [
                "OPENAI_SEARCH_API",
                "GEMINI_GROUNDED_API",
                "PERPLEXITY_AGENT_API",
                "ANTHROPIC_WEB_SEARCH_API"
              ],
              "enumTitles": [
                "OpenAI Responses API (web search)",
                "Gemini grounded API (Google Search)",
                "Perplexity Agent API",
                "Anthropic Claude API (web search)"
              ]
            }
          },
          "scopes": {
            "title": "Requested scopes",
            "minItems": 1,
            "maxItems": 50,
            "type": "array",
            "description": "Optional requested country, region, city, language, or locale. A requested value is reported as applied only when the provider response supports that claim.",
            "items": {
              "type": "object",
              "properties": {
                "scopeId": {
                  "title": "Scope ID",
                  "type": "string",
                  "description": "Stable ID for this requested scope.",
                  "editor": "textfield",
                  "minLength": 1,
                  "maxLength": 120
                },
                "country": {
                  "title": "Country",
                  "type": "string",
                  "description": "Optional country code or name where supported by the provider.",
                  "editor": "textfield",
                  "maxLength": 120
                },
                "region": {
                  "title": "Region",
                  "type": "string",
                  "description": "Optional region where supported by the provider.",
                  "editor": "textfield",
                  "maxLength": 120
                },
                "city": {
                  "title": "City",
                  "type": "string",
                  "description": "Optional city where supported by the provider.",
                  "editor": "textfield",
                  "maxLength": 120
                },
                "language": {
                  "title": "Language",
                  "type": "string",
                  "description": "Optional requested language.",
                  "editor": "textfield",
                  "maxLength": 50
                },
                "locale": {
                  "title": "Locale",
                  "type": "string",
                  "description": "Optional requested locale.",
                  "editor": "textfield",
                  "maxLength": 50
                }
              },
              "required": [
                "scopeId"
              ],
              "additionalProperties": false
            }
          },
          "samplesPerObservation": {
            "title": "Samples per prompt / surface / scope",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Repeat the exact same observation up to five times. Observed frequency is not converted into a model-preference probability.",
            "default": 1
          },
          "maxRequestedObservations": {
            "title": "Maximum requested observations",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Hard safety cap across prompts × surfaces × scopes × samples.",
            "default": 5000
          },
          "openaiApiKey": {
            "title": "OpenAI API key",
            "type": "string",
            "description": "Needed only for OpenAI Search API observations. Stored by Apify as encrypted secret input and never persisted in CiteGap output."
          },
          "geminiApiKey": {
            "title": "Gemini API key",
            "type": "string",
            "description": "Needed only for Gemini grounded API observations. Stored by Apify as encrypted secret input and never persisted in CiteGap output."
          },
          "perplexityApiKey": {
            "title": "Perplexity API key",
            "type": "string",
            "description": "Needed only for Perplexity Agent API observations. Stored by Apify as encrypted secret input and never persisted in CiteGap output."
          },
          "anthropicApiKey": {
            "title": "Anthropic API key",
            "type": "string",
            "description": "Needed only for Anthropic Claude API web-search observations. Stored by Apify as encrypted secret input and never persisted in CiteGap output."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}