/ Blog
Blog Contact Buddy Ads Builder Audit Engine GitHub

Tutorial 13: SearchAPI & Competitive Intelligence — Monitor Competitors in Real Time

John Williams · Senior Paid Media Specialist · $48M+ Managed · Feb 2026

How do I get started with tutorial 13: searchapi & competitive intelligence?
This covers everything you need to know about tutorial 13: searchapi & competitive intelligence.

What you’ll learn: How to set up SearchAPI for SERP monitoring, build automated competitive intelligence, track competitor ad copy changes, and feed search data into AI for strategic analysis.

The What: Real-Time Search Data Changes Everything

SearchAPI provides programmatic access to search engine results pages. Instead of manually Googling your competitors, you can systematically monitor every keyword, track ad copy changes, identify new competitors entering your market, and feed all of this data to AI for strategic interpretation. GoogleAdsAgent.ai’s Competitive Monitoring sub-agent is built on exactly this capability.

The How: Build a Competitive Monitor

Step 1: Set Up SearchAPI

# 1. Go to: https://www.searchapi.io
# 2. Create account > Dashboard > API Key
# 3. Store your key:
export SEARCHAPI_KEY='your-key-here'

pip install requests
Step 2: Pull SERP Data for Your Keywords

Step 2: Pull SERP Data for Your Keywords

import requests
import os
import json

def get_serp(keyword, location='United States'):
'''Pull Google search results for a keyword.'''
params = {
'engine': 'google',
'q': keyword,
'location': location,
'api_key': os.environ['SEARCHAPI_KEY'],
'num': 10
}
response = requests.get('https://www.searchapi.io/api/v1/search', params=params)
return response.json()

# Monitor your top keywords
keywords = ['running shoes online', 'best marathon shoes', 'trail running gear']
results = {}

for kw in keywords:
serp = get_serp(kw)
results[kw] = {
'ads': serp.get('ads', []),
'organic': serp.get('organic_results', [])[:5],
'ai_overview': serp.get('ai_overview', None)
}
print(f'{kw}: {len(results[kw]["ads"])} ads, {len(results[kw]["organic"])} organic')

Step 3: Extract Competitor Ad Intelligence

def extract_competitor_ads(serp_data):
'''Extract competitor ad copy for analysis.'''
competitors = []
for kw, data in serp_data.items():
for ad in data['ads']:
competitors.append({
'keyword': kw,
'advertiser': ad.get('displayed_link', 'Unknown'),
'title': ad.get('title', ''),
'description': ad.get('description', ''),
'position': ad.get('position', 0)
})
return competitors

comp_ads = extract_competitor_ads(results)
for ad in comp_ads[:5]:
print(f'[{ad["keyword"]}] {ad["advertiser"]}: {ad["title"]}')

Step 4: Feed to AI for Strategic Analysis

import anthropic

client = anthropic.Anthropic()

analysis = client.messages.create(
model='claude-sonnet-4-20250514',
max_tokens=2000,
messages=[{
'role': 'user',
'content': f'''Analyze these competitor ads and identify:
1. Common value propositions (what everyone says)
2. Gaps in messaging (what nobody says)
3. Opportunities for differentiation
4. Recommended ad copy angles to test

Competitor Ads:\n{json.dumps(comp_ads, indent=2)}'''
}]
)
print(analysis.content[0].text)

AUTOMATION: Schedule this script to run daily. Compare today’s results to yesterday’s to detect when competitors change ad copy, launch new campaigns, or exit keywords. GoogleAdsAgent.ai’s Competitive Monitoring sub-agent does exactly this—continuously.

Website: googleadsagent.ai | GitHub: https://github.com/itallstartedwithaidea | Tools: googleadsagent.ai/tools

John Williams | Senior Paid Media Specialist, Seer Interactive | $48M+ managed spend | Creator, GoogleAdsAgent.ai | Hero Conf Speaker | github.com/itallstartedwithaidea

© 2026 It All Started With A Idea. All rights reserved.

Ready to Put This Into Practice?

Get a free 30-day audit of your advertising accounts. John will personally review your setup and provide actionable recommendations.

No credit card · No contract · John will personally reach out within 24 hours

Thank You!

John will review your account and reach out within 24 hours.