Skip to content

Commit c67bcf4

Browse files
committed
README review
- fix reference to Ruby - fix path
1 parent d4a2aed commit c67bcf4

2 files changed

Lines changed: 28 additions & 34 deletions

File tree

README.md

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@
88
[![serpapi-python](https://github.com/serpapi/serpapi-python/actions/workflows/ci.yml/badge.svg)](https://github.com/serpapi/serpapi-python/actions/workflows/ci.yml)
99
</div>
1010

11-
12-
Integrate search data into your Ruby application. This library is the official wrapper for SerpApi (https://serpapi.com).
11+
Integrate search data into your Python application. This library is the official wrapper for SerpApi (https://serpapi.com).
1312

1413
SerpApi supports Google, Google Maps, Google Shopping, Baidu, Yandex, Yahoo, eBay, App Stores, and more.
1514

@@ -35,7 +34,7 @@ results = client.search({
3534
print(results['organic_results'])
3635
```
3736

38-
This example runs a search for "coffee" on Google. It then returns the results as a regular Ruby Hash. See the [playground](https://serpapi.com/playground) to generate your own code.
37+
This example runs a search for "coffee" on Google. It then returns the results as a dict. See the [playground](https://serpapi.com/playground) to generate your own code.
3938

4039
## Advanced Usage
4140
### Search API
@@ -86,10 +85,8 @@ raw_html = client.html(params)
8685
[Google search documentation](https://serpapi.com/search-api). More hands on examples are available below.
8786

8887
### Documentation
89-
* [API documentation](https://rubydoc.info/github/serpapi/serpapi-ruby/master)
9088
* [Full documentation on SerpApi.com](https://serpapi.com)
9189
* [Library Github page](https://github.com/serpapi/serpapi-ruby)
92-
* [Library GEM page](https://rubygems.org/gems/serpapi/)
9390
* [API health status](https://serpapi.com/status)
9491

9592
### Location API
@@ -697,7 +694,7 @@ The SerpApi.com service (backend)
697694
The class SerpApi::Client (client side / ruby):
698695
- Format the request to SerpApi.com server.
699696
- Execute HTTP Get request.
700-
- Parse JSON into Ruby Hash using a standard JSON library.
697+
- Parse JSON into Python dictionary / dict using a standard JSON module.
701698
Et voila!
702699

703700
## Continuous integration

README.md.erb

Lines changed: 25 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ def snippet(format, path)
55
slice = lines[9..stop]
66
slice.reject! { |l| l.match?(/self.assertIsNone\(/) }
77
buf = slice.map { |l| l.gsub(/(^\s{4})/, '').gsub(/^\s*$/, '') }.join
8-
url = path.gsub(/^.*\/serpapi-python/, 'https://github.com/serpapi/serpapi-python')
8+
url = path.gsub(/tests\//, 'https://github.com/serpapi/serpapi-python/tests/')
99
buf.gsub!('self.assertIsNotNone(', "pp = pprint.PrettyPrinter(indent=2)\npp.pprint(")
1010
%Q(```#{format}\nimport serpapi\nimport pprint\nimport os\n\n#{buf}```\ntest: [#{url}])
1111
end
@@ -20,8 +20,7 @@ end
2020
[![serpapi-python](https://github.com/serpapi/serpapi-python/actions/workflows/ci.yml/badge.svg)](https://github.com/serpapi/serpapi-python/actions/workflows/ci.yml)
2121
</div>
2222

23-
24-
Integrate search data into your Ruby application. This library is the official wrapper for SerpApi (https://serpapi.com).
23+
Integrate search data into your Python application. This library is the official wrapper for SerpApi (https://serpapi.com).
2524

2625
SerpApi supports Google, Google Maps, Google Shopping, Baidu, Yandex, Yahoo, eBay, App Stores, and more.
2726

@@ -47,7 +46,7 @@ results = client.search({
4746
print(results['organic_results'])
4847
```
4948

50-
This example runs a search for "coffee" on Google. It then returns the results as a regular Ruby Hash. See the [playground](https://serpapi.com/playground) to generate your own code.
49+
This example runs a search for "coffee" on Google. It then returns the results as a dict. See the [playground](https://serpapi.com/playground) to generate your own code.
5150

5251
## Advanced Usage
5352
### Search API
@@ -98,10 +97,8 @@ raw_html = client.html(params)
9897
[Google search documentation](https://serpapi.com/search-api). More hands on examples are available below.
9998

10099
### Documentation
101-
* [API documentation](https://rubydoc.info/github/serpapi/serpapi-ruby/master)
102100
* [Full documentation on SerpApi.com](https://serpapi.com)
103101
* [Library Github page](https://github.com/serpapi/serpapi-ruby)
104-
* [Library GEM page](https://rubygems.org/gems/serpapi/)
105102
* [API health status](https://serpapi.com/status)
106103

107104
### Location API
@@ -158,87 +155,87 @@ It prints your account information including plan, credit, montly
158155
## Basic example per search engines
159156

160157
### Search bing
161-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_bing_test.py') %>
158+
<%= snippet('python', 'tests/example_search_bing_test.py') %>
162159
see: [https://serpapi.com/bing-search-api](https://serpapi.com/bing-search-api)
163160

164161
### Search baidu
165-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_baidu_test.py') %>
162+
<%= snippet('python', 'tests/example_search_baidu_test.py') %>
166163
see: [https://serpapi.com/baidu-search-api](https://serpapi.com/baidu-search-api)
167164

168165
### Search yahoo
169-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_yahoo_test.py') %>
166+
<%= snippet('python', 'tests/example_search_yahoo_test.py') %>
170167
see: [https://serpapi.com/yahoo-search-api](https://serpapi.com/yahoo-search-api)
171168

172169
### Search youtube
173-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_youtube_test.py') %>
170+
<%= snippet('python', 'tests/example_search_youtube_test.py') %>
174171
see: [https://serpapi.com/youtube-search-api](https://serpapi.com/youtube-search-api)
175172

176173
### Search walmart
177-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_walmart_test.py') %>
174+
<%= snippet('python', 'tests/example_search_walmart_test.py') %>
178175
see: [https://serpapi.com/walmart-search-api](https://serpapi.com/walmart-search-api)
179176

180177
### Search ebay
181-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_ebay_test.py') %>
178+
<%= snippet('python', 'tests/example_search_ebay_test.py') %>
182179
see: [https://serpapi.com/ebay-search-api](https://serpapi.com/ebay-search-api)
183180

184181
### Search naver
185-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_naver_test.py') %>
182+
<%= snippet('python', 'tests/example_search_naver_test.py') %>
186183
see: [https://serpapi.com/naver-search-api](https://serpapi.com/naver-search-api)
187184

188185
### Search home depot
189-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_home_depot_test.py') %>
186+
<%= snippet('python', 'tests/example_search_home_depot_test.py') %>
190187
see: [https://serpapi.com/home-depot-search-api](https://serpapi.com/home-depot-search-api)
191188

192189
### Search apple app store
193-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_apple_app_store_test.py') %>
190+
<%= snippet('python', 'tests/example_search_apple_app_store_test.py') %>
194191
see: [https://serpapi.com/apple-app-store](https://serpapi.com/apple-app-store)
195192

196193
### Search duckduckgo
197-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_duckduckgo_test.py') %>
194+
<%= snippet('python', 'tests/example_search_duckduckgo_test.py') %>
198195
see: [https://serpapi.com/duckduckgo-search-api](https://serpapi.com/duckduckgo-search-api)
199196

200197
### Search google
201-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_test.py') %>
198+
<%= snippet('python', 'tests/example_search_google_test.py') %>
202199
see: [https://serpapi.com/search-api](https://serpapi.com/search-api)
203200

204201
### Search google scholar
205-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_scholar_test.py') %>
202+
<%= snippet('python', 'tests/example_search_google_scholar_test.py') %>
206203
see: [https://serpapi.com/google-scholar-api](https://serpapi.com/google-scholar-api)
207204

208205
### Search google autocomplete
209-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_autocomplete_test.py') %>
206+
<%= snippet('python', 'tests/example_search_google_autocomplete_test.py') %>
210207
see: [https://serpapi.com/google-autocomplete-api](https://serpapi.com/google-autocomplete-api)
211208

212209
### Search google product
213-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_product_test.py') %>
210+
<%= snippet('python', 'tests/example_search_google_product_test.py') %>
214211
see: [https://serpapi.com/google-product-api](https://serpapi.com/google-product-api)
215212

216213
### Search google reverse image
217-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_reverse_image_test.py') %>
214+
<%= snippet('python', 'tests/example_search_google_reverse_image_test.py') %>
218215
see: [https://serpapi.com/google-reverse-image](https://serpapi.com/google-reverse-image)
219216

220217
### Search google events
221-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_events_test.py') %>
218+
<%= snippet('python', 'tests/example_search_google_events_test.py') %>
222219
see: [https://serpapi.com/google-events-api](https://serpapi.com/google-events-api)
223220

224221
### Search google local services
225-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_local_services_test.py') %>
222+
<%= snippet('python', 'tests/example_search_google_local_services_test.py') %>
226223
see: [https://serpapi.com/google-local-services-api](https://serpapi.com/google-local-services-api)
227224

228225
### Search google maps
229-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_maps_test.py') %>
226+
<%= snippet('python', 'tests/example_search_google_maps_test.py') %>
230227
see: [https://serpapi.com/google-maps-api](https://serpapi.com/google-maps-api)
231228

232229
### Search google jobs
233-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_jobs_test.py') %>
230+
<%= snippet('python', 'tests/example_search_google_jobs_test.py') %>
234231
see: [https://serpapi.com/google-jobs-api](https://serpapi.com/google-jobs-api)
235232

236233
### Search google play
237-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_play_test.py') %>
234+
<%= snippet('python', 'tests/example_search_google_play_test.py') %>
238235
see: [https://serpapi.com/google-play-api](https://serpapi.com/google-play-api)
239236

240237
### Search google images
241-
<%= snippet('python', '/Users/victor/Project/serpapi/serpapi-python/tests/example_search_google_images_test.py') %>
238+
<%= snippet('python', 'tests/example_search_google_images_test.py') %>
242239
see: [https://serpapi.com/images-results](https://serpapi.com/images-results)
243240

244241

@@ -323,7 +320,7 @@ The SerpApi.com service (backend)
323320
The class SerpApi::Client (client side / ruby):
324321
- Format the request to SerpApi.com server.
325322
- Execute HTTP Get request.
326-
- Parse JSON into Ruby Hash using a standard JSON library.
323+
- Parse JSON into Python dictionary / dict using a standard JSON module.
327324
Et voila!
328325

329326
## Continuous integration

0 commit comments

Comments
 (0)