有没有办法从 Google SERP API 一次获得超过 100 个结果?

问题描述 投票:0回答:0

我在这个问题上卡了这么久。基本上我应该爬过搜索结果页面并提取前 10000 个结果的 url。但是对于 API,我一次最多只能获取 100 个。我正在使用 Zenserp。 这是我在 Python 中的代码:

import os
import requests
import csv
import json
import numpy as np
from bs4 import BeautifulSoup

headers = {"apikey": "xxxxxxx"}

params = (
   ("q","cat videos"),
   ("tbm","vid"),
   ("num","100"),
   ("start","100"),
);

response = requests.get('https://app.zenserp.com/api/v2/search', headers=headers, params=params);
output = response.text
print(output)

我只能抓取 100 个链接。我应该为我的用例找到 10000。请帮忙!

python web-scraping google-search-api
© www.soinside.com 2019 - 2024. All rights reserved.