n8n SerpAPI Beginner Failing: Switch to Structured API
Common SerpAPI errors in n8n: auth format, engine parameter, rate limits. Why structured search APIs with header auth fit n8n's mental model better.
Most n8n beginners who try SerpAPI hit authentication errors, malformed query parameters, or rate limits within the first hour. The issue is not n8n itself -- it is that SerpAPI expects precise parameter formatting that the HTTP Request node does not enforce, and the error messages are cryptic enough to send you down a rabbit hole.
The three errors everyone hits
After watching dozens of forum threads and r/n8n posts, the failure pattern is almost always one of these three:
- 401 Unauthorized: The API key is passed in the body instead of as a query parameter. SerpAPI expects
api_keyas a URL parameter, not a header or JSON field. n8n beginners default to putting credentials in headers because that is how most APIs work. - Missing or invalid engine parameter: SerpAPI requires an explicit
enginefield set togoogle,bing, etc. Omit it and you get a 400 with no clear explanation. The n8n HTTP Request node does not template this for you. - Rate limit exhaustion: SerpAPI free tier allows 100 searches/month. One misconfigured loop in n8n can burn through that in minutes. There is no built-in rate limiter in the HTTP Request node.
What a working SerpAPI call in n8n looks like
For reference, here is the correct HTTP Request node setup for SerpAPI. Every parameter must be a query parameter, not body or header:
{
"method": "GET",
"url": "https://serpapi.com/search",
"qs": {
"api_key": "your_serpapi_key",
"engine": "google",
"q": "best crm for startups",
"num": "10"
}
}The response is a large nested JSON. Extracting the organic results requires navigating organic_results[].title, organic_results[].link, and organic_results[].snippet. Beginners often try to use the raw response without a Set node to reshape it, which breaks downstream nodes.
Why structured APIs are easier for n8n
A structured search API that uses POST with a JSON body and API key in a header fits n8n's mental model better. Headers for auth, body for parameters -- that is what the HTTP Request node is designed for.
{
"method": "POST",
"url": "https://api.scavio.dev/api/v1/search",
"headers": {
"x-api-key": "your_scavio_key",
"Content-Type": "application/json"
},
"body": {
"query": "best crm for startups",
"num_results": 10
}
}No engine parameter to forget. No query-string authentication. The response schema is flatter, so downstream nodes can reference results[].title directly without nested drilling.
Rate limits: SerpAPI vs pay-per-query
SerpAPI pricing starts at $50/mo for 5,000 searches. The free tier gives 100 searches/month. For an n8n beginner building a keyword monitoring workflow that checks 20 keywords daily, that is 600 searches/month -- already past the free tier and into the $50/mo plan.
At $0.005/credit with Scavio, 600 searches costs $3/month. The free tier includes 250 credits/month, so light testing costs nothing. For n8n users who are still figuring out their workflows and burning credits on debugging, the per-query model means mistakes cost fractions of a penny instead of eating a monthly quota.
Building a keyword tracker in n8n
Here is the Python equivalent of a typical n8n keyword-tracking workflow, useful for testing before you wire it up visually:
import requests, os, json
API_KEY = os.environ["SCAVIO_API_KEY"]
KEYWORDS = ["best crm 2026", "crm for small teams", "hubspot alternatives"]
def check_keyword(keyword):
resp = requests.post(
"https://api.scavio.dev/api/v1/search",
headers={"x-api-key": API_KEY},
json={"query": keyword, "num_results": 10},
)
results = resp.json().get("results", [])
return {
"keyword": keyword,
"top_3": [
{"position": i + 1, "title": r["title"], "url": r["url"]}
for i, r in enumerate(results[:3])
],
}
# 3 keywords x $0.005 = $0.015 total
for kw in KEYWORDS:
data = check_keyword(kw)
print(f"{data['keyword']}:")
for r in data["top_3"]:
print(f" #{r['position']}: {r['title']}")Common n8n mistakes to avoid
- Do not use the
Execute Workflownode to loop over keywords without a Wait node. You will fire all requests simultaneously and hit rate limits. - Always add an IF node after the HTTP Request to check for error status codes. Silent failures corrupt your data downstream.
- Store API keys in n8n credentials, not hardcoded in the node. This is obvious but skipped in most tutorials.
- Use the
SplitInBatchesnode if processing more than 10 keywords at once. Without it, memory usage spikes and n8n can crash on self-hosted instances.
When SerpAPI is the right choice
SerpAPI shines if you need specialized engines: Google Maps, Google Jobs, Google Scholar, Apple App Store. It covers 20+ search engines with dedicated parsers. If your n8n workflow queries niche engines, SerpAPI at $50/mo is worth the complexity. For standard web search in n8n workflows, a simpler API with POST/header auth and flat response shapes saves hours of debugging.