justserpapi 3.0.0__tar.gz → 3.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- justserpapi-3.1.0/PKG-INFO +242 -0
- justserpapi-3.1.0/README.md +208 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/_version.py +1 -1
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/api/google_api_api.py +265 -255
- justserpapi-3.1.0/justserpapi/client.py +569 -0
- justserpapi-3.1.0/justserpapi.egg-info/PKG-INFO +242 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/test/test_google_api_api.py +17 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/tests/test_client.py +39 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/tests/test_sdkctl.py +26 -4
- justserpapi-3.0.0/PKG-INFO +0 -154
- justserpapi-3.0.0/README.md +0 -120
- justserpapi-3.0.0/justserpapi/client.py +0 -151
- justserpapi-3.0.0/justserpapi.egg-info/PKG-INFO +0 -154
- {justserpapi-3.0.0 → justserpapi-3.1.0}/LICENSE +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/__init__.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/api/__init__.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/api_client.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/api_response.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/configuration.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/exceptions.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/models/__init__.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/models/responses.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/py.typed +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi/rest.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi.egg-info/SOURCES.txt +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi.egg-info/dependency_links.txt +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi.egg-info/requires.txt +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/justserpapi.egg-info/top_level.txt +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/pyproject.toml +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/setup.cfg +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/setup.py +0 -0
- {justserpapi-3.0.0 → justserpapi-3.1.0}/tests/test_examples.py +0 -0
|
@@ -0,0 +1,242 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: justserpapi
|
|
3
|
+
Version: 3.1.0
|
|
4
|
+
Summary: Professional Python SDK for JustSerpAPI
|
|
5
|
+
Home-page: https://api.justserpapi.com
|
|
6
|
+
Author: JustSerpAPI Team
|
|
7
|
+
Author-email: JustSerpAPI Team <support@justserpapi.com>
|
|
8
|
+
License: MIT
|
|
9
|
+
Project-URL: Homepage, https://api.justserpapi.com
|
|
10
|
+
Project-URL: Documentation, https://docs.justserpapi.com
|
|
11
|
+
Project-URL: Repository, https://github.com/justserpapi/justserpapi-python
|
|
12
|
+
Keywords: OpenAPI,OpenAPI-Generator,JustSerpAPI,SERP
|
|
13
|
+
Classifier: Programming Language :: Python :: 3
|
|
14
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
19
|
+
Classifier: Intended Audience :: Developers
|
|
20
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
21
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
22
|
+
Classifier: Operating System :: OS Independent
|
|
23
|
+
Requires-Python: >= 3.9
|
|
24
|
+
Description-Content-Type: text/markdown
|
|
25
|
+
License-File: LICENSE
|
|
26
|
+
Requires-Dist: urllib3<3.0.0,>=2.1.0
|
|
27
|
+
Requires-Dist: python-dateutil>=2.8.2
|
|
28
|
+
Requires-Dist: pydantic>=2
|
|
29
|
+
Requires-Dist: typing-extensions>=4.7.1
|
|
30
|
+
Dynamic: author
|
|
31
|
+
Dynamic: home-page
|
|
32
|
+
Dynamic: license-file
|
|
33
|
+
Dynamic: requires-python
|
|
34
|
+
|
|
35
|
+
<p align="center">
|
|
36
|
+
<a href="https://justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_logo">
|
|
37
|
+
<img src="https://justserpapi.com/logo/whiteBgColor.webp" alt="JustSerpAPI Logo" width="200">
|
|
38
|
+
</a>
|
|
39
|
+
</p>
|
|
40
|
+
|
|
41
|
+
<h1 align="center">JustSerpAPI Python SDK</h1>
|
|
42
|
+
|
|
43
|
+
<p align="center">
|
|
44
|
+
<a href="https://pypi.org/project/justserpapi/">
|
|
45
|
+
<img src="https://img.shields.io/pypi/v/justserpapi?color=blue&style=flat-square" alt="PyPI version">
|
|
46
|
+
</a>
|
|
47
|
+
<a href="https://pypi.org/project/justserpapi/">
|
|
48
|
+
<img src="https://img.shields.io/pypi/pyversions/justserpapi?style=flat-square" alt="Python Versions">
|
|
49
|
+
</a>
|
|
50
|
+
<a href="https://docs.justserpapi.com">
|
|
51
|
+
<img src="https://img.shields.io/badge/docs-latest-brightgreen?style=flat-square" alt="Documentation">
|
|
52
|
+
</a>
|
|
53
|
+
<a href="LICENSE">
|
|
54
|
+
<img src="https://img.shields.io/badge/license-MIT-orange?style=flat-square" alt="License">
|
|
55
|
+
</a>
|
|
56
|
+
</p>
|
|
57
|
+
|
|
58
|
+
OpenAPI-driven Python SDK for [JustSerpAPI](https://justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme) with a stable high-level `Client` as the public entrypoint.
|
|
59
|
+
|
|
60
|
+
## Platform Overview
|
|
61
|
+
|
|
62
|
+
The documentation center helps you browse endpoint health, versioned API paths, request parameters, and SERP-specific usage notes.
|
|
63
|
+
|
|
64
|
+
[](https://docs.justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_docs_image)
|
|
65
|
+
|
|
66
|
+
The console provides API key management, subscription status, credit visibility, request logs, usage trends, and credit consumption analytics.
|
|
67
|
+
|
|
68
|
+
[](https://dashboard.justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_dashboard_image)
|
|
69
|
+
|
|
70
|
+
## Installation
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
pip install justserpapi
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
## Quick Start
|
|
77
|
+
|
|
78
|
+
```python
|
|
79
|
+
from justserpapi import Client
|
|
80
|
+
|
|
81
|
+
with Client(api_key="YOUR_API_KEY") as client:
|
|
82
|
+
response = client.google.search(
|
|
83
|
+
query="coffee shops in New York",
|
|
84
|
+
location="New York, NY",
|
|
85
|
+
language="en",
|
|
86
|
+
)
|
|
87
|
+
print(response)
|
|
88
|
+
print(response["data"])
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
## Generated High-Level API
|
|
92
|
+
|
|
93
|
+
The high-level surface is generated from OpenAPI and designed to be the default entrypoint:
|
|
94
|
+
|
|
95
|
+
```python
|
|
96
|
+
from justserpapi import Client
|
|
97
|
+
|
|
98
|
+
client = Client(api_key="YOUR_API_KEY", timeout=20.0)
|
|
99
|
+
|
|
100
|
+
search = client.google.search(query="best espresso beans", language="en")
|
|
101
|
+
light = client.google.search.light(query="best espresso beans", language="en")
|
|
102
|
+
maps = client.google.maps.search(query="espresso bars", location="Shanghai")
|
|
103
|
+
news = client.google.news.search(query="OpenAI", language="en")
|
|
104
|
+
images = client.google.images.search(query="espresso machine")
|
|
105
|
+
shopping = client.google.shopping.search(query="espresso tamper")
|
|
106
|
+
finance = client.google.finance.search(query="NASDAQ:GOOGL")
|
|
107
|
+
scholar = client.google.scholar.search(query="machine learning", language="en")
|
|
108
|
+
overview = client.google.ai.overview(url="https://example.com/ai-overview")
|
|
109
|
+
|
|
110
|
+
print(search["data"])
|
|
111
|
+
|
|
112
|
+
client.close()
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
High-level responses are plain Python dictionaries that mirror the API's JSON response envelope. The SDK does not auto-unpack `data`.
|
|
116
|
+
|
|
117
|
+
## Configuration
|
|
118
|
+
|
|
119
|
+
The public client exposes the common knobs directly:
|
|
120
|
+
|
|
121
|
+
```python
|
|
122
|
+
from justserpapi import Client
|
|
123
|
+
from urllib3.util.retry import Retry
|
|
124
|
+
|
|
125
|
+
client = Client(
|
|
126
|
+
api_key="YOUR_API_KEY",
|
|
127
|
+
base_url="https://api.justserpapi.com",
|
|
128
|
+
timeout=(5.0, 30.0),
|
|
129
|
+
retries=Retry(total=5, backoff_factor=0.5),
|
|
130
|
+
)
|
|
131
|
+
client.close()
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
- `api_key`: value sent in the `X-API-Key` header
|
|
135
|
+
- `base_url`: API host, defaults to `https://api.justserpapi.com`
|
|
136
|
+
- `timeout`: default request timeout injected into high-level methods
|
|
137
|
+
- `retries`: `urllib3` retry configuration; defaults to a conservative retry strategy for the high-level client
|
|
138
|
+
|
|
139
|
+
## Service Overview
|
|
140
|
+
|
|
141
|
+
The API list below is generated from OpenAPI and shows the current public API categories and endpoint names. See the [online API documentation](https://docs.justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list) for full request and response details.
|
|
142
|
+
|
|
143
|
+
<!-- API_LIST_START -->
|
|
144
|
+
|
|
145
|
+
### Google Search API
|
|
146
|
+
|
|
147
|
+
- [Search API](https://docs.justserpapi.com/api/v1/google/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
148
|
+
- [Light Search API](https://docs.justserpapi.com/api/v1/google/search/light?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
149
|
+
- [Mobile Search API](https://docs.justserpapi.com/api/v1/google/search/mobile?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
150
|
+
|
|
151
|
+
### Google AI Mode API
|
|
152
|
+
|
|
153
|
+
- [AI Mode API](https://docs.justserpapi.com/api/v1/google/ai-mode?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
154
|
+
|
|
155
|
+
### Google AI Overview API
|
|
156
|
+
|
|
157
|
+
- [AI Overview API](https://docs.justserpapi.com/api/v1/google/ai-overview?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
158
|
+
|
|
159
|
+
### Google Maps API
|
|
160
|
+
|
|
161
|
+
- [Maps Search API](https://docs.justserpapi.com/api/v1/google/maps/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
162
|
+
- [Maps Posts API](https://docs.justserpapi.com/api/v1/google/maps/posts?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
163
|
+
- [Maps Photos API](https://docs.justserpapi.com/api/v1/google/maps/photos?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
164
|
+
- [Maps Reviews API](https://docs.justserpapi.com/api/v1/google/maps/reviews?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
165
|
+
- [Maps Place Details API](https://docs.justserpapi.com/api/v1/google/maps/places?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
166
|
+
|
|
167
|
+
### Google Images API
|
|
168
|
+
|
|
169
|
+
- [Images Search API](https://docs.justserpapi.com/api/v1/google/images/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
170
|
+
|
|
171
|
+
### Google News API
|
|
172
|
+
|
|
173
|
+
- [News Search API](https://docs.justserpapi.com/api/v1/google/news/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
174
|
+
|
|
175
|
+
### Google Videos API
|
|
176
|
+
|
|
177
|
+
- [Videos Search API](https://docs.justserpapi.com/api/v1/google/videos/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
178
|
+
|
|
179
|
+
### Google Shorts API
|
|
180
|
+
|
|
181
|
+
- [Shorts Search API](https://docs.justserpapi.com/api/v1/google/shorts/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
182
|
+
|
|
183
|
+
### Google Finance API
|
|
184
|
+
|
|
185
|
+
- [Finance Search API](https://docs.justserpapi.com/api/v1/google/finance/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
186
|
+
|
|
187
|
+
### Google Trends API
|
|
188
|
+
|
|
189
|
+
- [Google Trends Search API](https://docs.justserpapi.com/api/v1/google/trends/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
190
|
+
- [Google Trends Autocomplete API](https://docs.justserpapi.com/api/v1/google/trends/autocomplete?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
191
|
+
- [Google Trends Trending Now API](https://docs.justserpapi.com/api/v1/google/trends/trending-now?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
192
|
+
|
|
193
|
+
### Google Shopping API
|
|
194
|
+
|
|
195
|
+
- [Shopping Search API](https://docs.justserpapi.com/api/v1/google/shopping/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
196
|
+
|
|
197
|
+
### Google Immersive Product API
|
|
198
|
+
|
|
199
|
+
- [Immersive Product API](https://docs.justserpapi.com/api/v1/google/immersive/product?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
200
|
+
|
|
201
|
+
### Google Autocomplete API
|
|
202
|
+
|
|
203
|
+
- [Autocomplete API](https://docs.justserpapi.com/api/v1/google/autocomplete?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
204
|
+
|
|
205
|
+
### Google Scholar API
|
|
206
|
+
|
|
207
|
+
- [Google Scholar Search API](https://docs.justserpapi.com/api/v1/google/scholar/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
208
|
+
- [Google Scholar Author API](https://docs.justserpapi.com/api/v1/google/scholar/author?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
209
|
+
- [Google Scholar Cite API](https://docs.justserpapi.com/api/v1/google/scholar/cite/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
210
|
+
|
|
211
|
+
### Google Lens API
|
|
212
|
+
|
|
213
|
+
- [Lens API](https://docs.justserpapi.com/api/v1/google/lens?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
214
|
+
|
|
215
|
+
### Google Jobs API
|
|
216
|
+
|
|
217
|
+
- [Jobs Search API](https://docs.justserpapi.com/api/v1/google/jobs/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
218
|
+
|
|
219
|
+
### Google Local API
|
|
220
|
+
|
|
221
|
+
- [Local Search API](https://docs.justserpapi.com/api/v1/google/local/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
222
|
+
|
|
223
|
+
### Google Patents API
|
|
224
|
+
|
|
225
|
+
- [Google Patents Search API](https://docs.justserpapi.com/api/v1/google/patents/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
226
|
+
- [Google Patents Details API](https://docs.justserpapi.com/api/v1/google/patents/details?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
227
|
+
|
|
228
|
+
### Google Hotels API
|
|
229
|
+
|
|
230
|
+
- [Hotels Search API](https://docs.justserpapi.com/api/v1/google/hotels/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
231
|
+
|
|
232
|
+
### Web API
|
|
233
|
+
|
|
234
|
+
- [Crawl Webpage (HTML)](https://docs.justserpapi.com/api/v1/web/html?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
235
|
+
- [Crawl Webpage (Rendered HTML)](https://docs.justserpapi.com/api/v1/web/rendered-html?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
236
|
+
- [Crawl Webpage (Markdown)](https://docs.justserpapi.com/api/v1/web/markdown?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
237
|
+
|
|
238
|
+
<!-- API_LIST_END -->
|
|
239
|
+
|
|
240
|
+
## License
|
|
241
|
+
|
|
242
|
+
Distributed under the MIT License. See `LICENSE` for more information.
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
<p align="center">
|
|
2
|
+
<a href="https://justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_logo">
|
|
3
|
+
<img src="https://justserpapi.com/logo/whiteBgColor.webp" alt="JustSerpAPI Logo" width="200">
|
|
4
|
+
</a>
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
<h1 align="center">JustSerpAPI Python SDK</h1>
|
|
8
|
+
|
|
9
|
+
<p align="center">
|
|
10
|
+
<a href="https://pypi.org/project/justserpapi/">
|
|
11
|
+
<img src="https://img.shields.io/pypi/v/justserpapi?color=blue&style=flat-square" alt="PyPI version">
|
|
12
|
+
</a>
|
|
13
|
+
<a href="https://pypi.org/project/justserpapi/">
|
|
14
|
+
<img src="https://img.shields.io/pypi/pyversions/justserpapi?style=flat-square" alt="Python Versions">
|
|
15
|
+
</a>
|
|
16
|
+
<a href="https://docs.justserpapi.com">
|
|
17
|
+
<img src="https://img.shields.io/badge/docs-latest-brightgreen?style=flat-square" alt="Documentation">
|
|
18
|
+
</a>
|
|
19
|
+
<a href="LICENSE">
|
|
20
|
+
<img src="https://img.shields.io/badge/license-MIT-orange?style=flat-square" alt="License">
|
|
21
|
+
</a>
|
|
22
|
+
</p>
|
|
23
|
+
|
|
24
|
+
OpenAPI-driven Python SDK for [JustSerpAPI](https://justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme) with a stable high-level `Client` as the public entrypoint.
|
|
25
|
+
|
|
26
|
+
## Platform Overview
|
|
27
|
+
|
|
28
|
+
The documentation center helps you browse endpoint health, versioned API paths, request parameters, and SERP-specific usage notes.
|
|
29
|
+
|
|
30
|
+
[](https://docs.justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_docs_image)
|
|
31
|
+
|
|
32
|
+
The console provides API key management, subscription status, credit visibility, request logs, usage trends, and credit consumption analytics.
|
|
33
|
+
|
|
34
|
+
[](https://dashboard.justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_dashboard_image)
|
|
35
|
+
|
|
36
|
+
## Installation
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
pip install justserpapi
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Quick Start
|
|
43
|
+
|
|
44
|
+
```python
|
|
45
|
+
from justserpapi import Client
|
|
46
|
+
|
|
47
|
+
with Client(api_key="YOUR_API_KEY") as client:
|
|
48
|
+
response = client.google.search(
|
|
49
|
+
query="coffee shops in New York",
|
|
50
|
+
location="New York, NY",
|
|
51
|
+
language="en",
|
|
52
|
+
)
|
|
53
|
+
print(response)
|
|
54
|
+
print(response["data"])
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Generated High-Level API
|
|
58
|
+
|
|
59
|
+
The high-level surface is generated from OpenAPI and designed to be the default entrypoint:
|
|
60
|
+
|
|
61
|
+
```python
|
|
62
|
+
from justserpapi import Client
|
|
63
|
+
|
|
64
|
+
client = Client(api_key="YOUR_API_KEY", timeout=20.0)
|
|
65
|
+
|
|
66
|
+
search = client.google.search(query="best espresso beans", language="en")
|
|
67
|
+
light = client.google.search.light(query="best espresso beans", language="en")
|
|
68
|
+
maps = client.google.maps.search(query="espresso bars", location="Shanghai")
|
|
69
|
+
news = client.google.news.search(query="OpenAI", language="en")
|
|
70
|
+
images = client.google.images.search(query="espresso machine")
|
|
71
|
+
shopping = client.google.shopping.search(query="espresso tamper")
|
|
72
|
+
finance = client.google.finance.search(query="NASDAQ:GOOGL")
|
|
73
|
+
scholar = client.google.scholar.search(query="machine learning", language="en")
|
|
74
|
+
overview = client.google.ai.overview(url="https://example.com/ai-overview")
|
|
75
|
+
|
|
76
|
+
print(search["data"])
|
|
77
|
+
|
|
78
|
+
client.close()
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
High-level responses are plain Python dictionaries that mirror the API's JSON response envelope. The SDK does not auto-unpack `data`.
|
|
82
|
+
|
|
83
|
+
## Configuration
|
|
84
|
+
|
|
85
|
+
The public client exposes the common knobs directly:
|
|
86
|
+
|
|
87
|
+
```python
|
|
88
|
+
from justserpapi import Client
|
|
89
|
+
from urllib3.util.retry import Retry
|
|
90
|
+
|
|
91
|
+
client = Client(
|
|
92
|
+
api_key="YOUR_API_KEY",
|
|
93
|
+
base_url="https://api.justserpapi.com",
|
|
94
|
+
timeout=(5.0, 30.0),
|
|
95
|
+
retries=Retry(total=5, backoff_factor=0.5),
|
|
96
|
+
)
|
|
97
|
+
client.close()
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
- `api_key`: value sent in the `X-API-Key` header
|
|
101
|
+
- `base_url`: API host, defaults to `https://api.justserpapi.com`
|
|
102
|
+
- `timeout`: default request timeout injected into high-level methods
|
|
103
|
+
- `retries`: `urllib3` retry configuration; defaults to a conservative retry strategy for the high-level client
|
|
104
|
+
|
|
105
|
+
## Service Overview
|
|
106
|
+
|
|
107
|
+
The API list below is generated from OpenAPI and shows the current public API categories and endpoint names. See the [online API documentation](https://docs.justserpapi.com/?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list) for full request and response details.
|
|
108
|
+
|
|
109
|
+
<!-- API_LIST_START -->
|
|
110
|
+
|
|
111
|
+
### Google Search API
|
|
112
|
+
|
|
113
|
+
- [Search API](https://docs.justserpapi.com/api/v1/google/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
114
|
+
- [Light Search API](https://docs.justserpapi.com/api/v1/google/search/light?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
115
|
+
- [Mobile Search API](https://docs.justserpapi.com/api/v1/google/search/mobile?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
116
|
+
|
|
117
|
+
### Google AI Mode API
|
|
118
|
+
|
|
119
|
+
- [AI Mode API](https://docs.justserpapi.com/api/v1/google/ai-mode?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
120
|
+
|
|
121
|
+
### Google AI Overview API
|
|
122
|
+
|
|
123
|
+
- [AI Overview API](https://docs.justserpapi.com/api/v1/google/ai-overview?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
124
|
+
|
|
125
|
+
### Google Maps API
|
|
126
|
+
|
|
127
|
+
- [Maps Search API](https://docs.justserpapi.com/api/v1/google/maps/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
128
|
+
- [Maps Posts API](https://docs.justserpapi.com/api/v1/google/maps/posts?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
129
|
+
- [Maps Photos API](https://docs.justserpapi.com/api/v1/google/maps/photos?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
130
|
+
- [Maps Reviews API](https://docs.justserpapi.com/api/v1/google/maps/reviews?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
131
|
+
- [Maps Place Details API](https://docs.justserpapi.com/api/v1/google/maps/places?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
132
|
+
|
|
133
|
+
### Google Images API
|
|
134
|
+
|
|
135
|
+
- [Images Search API](https://docs.justserpapi.com/api/v1/google/images/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
136
|
+
|
|
137
|
+
### Google News API
|
|
138
|
+
|
|
139
|
+
- [News Search API](https://docs.justserpapi.com/api/v1/google/news/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
140
|
+
|
|
141
|
+
### Google Videos API
|
|
142
|
+
|
|
143
|
+
- [Videos Search API](https://docs.justserpapi.com/api/v1/google/videos/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
144
|
+
|
|
145
|
+
### Google Shorts API
|
|
146
|
+
|
|
147
|
+
- [Shorts Search API](https://docs.justserpapi.com/api/v1/google/shorts/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
148
|
+
|
|
149
|
+
### Google Finance API
|
|
150
|
+
|
|
151
|
+
- [Finance Search API](https://docs.justserpapi.com/api/v1/google/finance/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
152
|
+
|
|
153
|
+
### Google Trends API
|
|
154
|
+
|
|
155
|
+
- [Google Trends Search API](https://docs.justserpapi.com/api/v1/google/trends/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
156
|
+
- [Google Trends Autocomplete API](https://docs.justserpapi.com/api/v1/google/trends/autocomplete?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
157
|
+
- [Google Trends Trending Now API](https://docs.justserpapi.com/api/v1/google/trends/trending-now?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
158
|
+
|
|
159
|
+
### Google Shopping API
|
|
160
|
+
|
|
161
|
+
- [Shopping Search API](https://docs.justserpapi.com/api/v1/google/shopping/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
162
|
+
|
|
163
|
+
### Google Immersive Product API
|
|
164
|
+
|
|
165
|
+
- [Immersive Product API](https://docs.justserpapi.com/api/v1/google/immersive/product?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
166
|
+
|
|
167
|
+
### Google Autocomplete API
|
|
168
|
+
|
|
169
|
+
- [Autocomplete API](https://docs.justserpapi.com/api/v1/google/autocomplete?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
170
|
+
|
|
171
|
+
### Google Scholar API
|
|
172
|
+
|
|
173
|
+
- [Google Scholar Search API](https://docs.justserpapi.com/api/v1/google/scholar/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
174
|
+
- [Google Scholar Author API](https://docs.justserpapi.com/api/v1/google/scholar/author?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
175
|
+
- [Google Scholar Cite API](https://docs.justserpapi.com/api/v1/google/scholar/cite/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
176
|
+
|
|
177
|
+
### Google Lens API
|
|
178
|
+
|
|
179
|
+
- [Lens API](https://docs.justserpapi.com/api/v1/google/lens?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
180
|
+
|
|
181
|
+
### Google Jobs API
|
|
182
|
+
|
|
183
|
+
- [Jobs Search API](https://docs.justserpapi.com/api/v1/google/jobs/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
184
|
+
|
|
185
|
+
### Google Local API
|
|
186
|
+
|
|
187
|
+
- [Local Search API](https://docs.justserpapi.com/api/v1/google/local/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
188
|
+
|
|
189
|
+
### Google Patents API
|
|
190
|
+
|
|
191
|
+
- [Google Patents Search API](https://docs.justserpapi.com/api/v1/google/patents/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
192
|
+
- [Google Patents Details API](https://docs.justserpapi.com/api/v1/google/patents/details?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
193
|
+
|
|
194
|
+
### Google Hotels API
|
|
195
|
+
|
|
196
|
+
- [Hotels Search API](https://docs.justserpapi.com/api/v1/google/hotels/search?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
197
|
+
|
|
198
|
+
### Web API
|
|
199
|
+
|
|
200
|
+
- [Crawl Webpage (HTML)](https://docs.justserpapi.com/api/v1/web/html?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
201
|
+
- [Crawl Webpage (Rendered HTML)](https://docs.justserpapi.com/api/v1/web/rendered-html?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
202
|
+
- [Crawl Webpage (Markdown)](https://docs.justserpapi.com/api/v1/web/markdown?utm_source=github.com&utm_medium=referral&utm_campaign=justserpapi_justserpapi_python&utm_content=repo_readme_api_list)
|
|
203
|
+
|
|
204
|
+
<!-- API_LIST_END -->
|
|
205
|
+
|
|
206
|
+
## License
|
|
207
|
+
|
|
208
|
+
Distributed under the MIT License. See `LICENSE` for more information.
|