Calling the Google UI API via Python

I am writing a module in Python that will query the Google Custom Search API and return all lists of the domain "example.com"

I read the instructions at https://code.google.com/apis/customsearch/v1/getting_started.html and are a bit deadlocked at the moment.

Are my assumptions listed below correct?

For example, to search for results that have "example.com" in the URL, the query:

* 'https://www.googleapis.com/customsearch/v1 key = my_key & cx = 017576662512468239146: omuauf_lfve & d = site: example.com' *

* key = my_key: * key value given by google

cx = 017576662512468239146: name of the search engine (google)? Is it correct?

* omuauf_lfve: * I have no idea what this is

q = site: example.com: This should return all results using example.com; e.g. www.a.example.com, b.example.com, example .com

+3
source share
1 answer

Although this question is quite old and the author does not seem to be too responsive, Google still appreciates this page and many people can come here, so I am posting my answer.

Google Custom Search is described in this answer to a similar question.

The parameters are as follows:

- , API Google. , , " " " " API " API".

cx - , . , "123456: abcdef", "omuauf_lfve" , .

q - . "site: example.com" Google. . .

+5

Source: https://habr.com/ru/post/1781549/


All Articles