Google Services API
Access Google services including Scholar profiles, author information, citation data, Google Trends, News, and Images through a unified API powered by ScrapingDog.
POST
/v1/google/*学者档案搜索
POST
/v1/google/scholar/profiles按作者姓名或标签搜索 Google Scholar 学者档案。返回档案信息,包括所属机构、引用数和研究兴趣。
参数
| 参数 | 类型 | 必填 | 描述 |
|---|---|---|---|
query | string | 必填 | 作者姓名或研究标签 |
country | string | 可选 | 国家过滤 |
Google Trends
POST
/v1/google/trends获取最多 5 个搜索词的 Google Trends 数据,支持地理、时间和类别过滤。返回时间趋势和地理分布数据。
参数
| 参数 | 类型 | 必填 | 描述 |
|---|---|---|---|
queries | string[] | 必填 | 搜索词列表(最多 5 个) |
geo | string | 可选 | 地理定位(如 'US'、'GB') |
timeframe | string | 可选 | 时间段过滤 |
category | integer | 可选 | 类别过滤(整数 ID) |
Google 新闻
POST
/v1/google/news搜索 Google 新闻,支持地理定位、时间过滤、语言限制和分页。
参数
| 参数 | 类型 | 必填 | 描述 |
|---|---|---|---|
q | string | 必填 | 搜索关键词 |
location | string | 可选 | 地理位置过滤 |
language | string | 可选 | 语言过滤 |
page | integer | 可选 (默认: 0) | 分页页码 |
Google 图片
POST
/v1/google/images搜索 Google 图片,支持丰富的过滤条件,包括尺寸、颜色、类型、宽高比、版权、日期范围和地理定位。
参数
| 参数 | 类型 | 必填 | 描述 |
|---|---|---|---|
q | string | 必填 | 搜索关键词 |
size | string | 可选 | 图片尺寸:'icon'、'small'、'medium'、'large'、'xlarge'、'xxlarge' |
color | string | 可选 | 颜色过滤 |
type | string | 可选 | 图片类型过滤 |
license | string | 可选 | 版权许可过滤 |
aspect_ratio | string | 可选 | 宽高比过滤 |
location | string | 可选 | 地理定位 |
响应
Response
{
"success": true,
"message": "Google Scholar profiles search completed",
"data": {
"profiles": [
{
"name": "Geoffrey Hinton",
"affiliation": "University of Toronto",
"cited_by": 740000,
"interests": [
"machine learning",
"neural networks",
"deep learning"
],
"author_id": "JicYPdAAAAAJ"
}
]
}
}示例
import requests
API_KEY = "your_api_key_here"
BASE_URL = "https://api.qinyanai.com"
# Search scholar profiles
response = requests.post(
f"{BASE_URL}/v1/google/scholar/profiles",
headers={"Authorization": f"Bearer {API_KEY}"},
json={"query": "Geoffrey Hinton"}
)
# Get author details
response = requests.post(
f"{BASE_URL}/v1/google/scholar/author",
headers={"Authorization": f"Bearer {API_KEY}"},
json={"author_id": "JicYPdAAAAAJ"}
)
# Google Trends
response = requests.post(
f"{BASE_URL}/v1/google/trends",
headers={"Authorization": f"Bearer {API_KEY}"},
json={"queries": ["ChatGPT", "Claude", "Gemini"], "geo": "US"}
)
# Google News
response = requests.post(
f"{BASE_URL}/v1/google/news",
headers={"Authorization": f"Bearer {API_KEY}"},
json={"q": "artificial intelligence breakthroughs"}
)
# Google Images
response = requests.post(
f"{BASE_URL}/v1/google/images",
headers={"Authorization": f"Bearer {API_KEY}"},
json={"q": "neural network architecture diagram", "size": "large"}
)