6

I'm trying to figure out how to force google custom search to give me back 20 results per page. I've tried to send this REST request configuring my new Custom Search Engine to: Standard edition: Free, ads are required on results pages.

https://www.googleapis.com/customsearch/v1?key=AIzaSyCgGuZie_Xo-hOECNXOTKp5Yk7deryqro8&cx=015864032944730029962:5ipe0q27hgy&q=test&alt=json&num=20

IT NOT WORKS!

but

https://www.googleapis.com/customsearch/v1?key=AIzaSyCgGuZie_Xo-hOECNXOTKp5Yk7deryqro8&cx=015864032944730029962:5ipe0q27hgy&q=test&alt=json&num=10

IT WORKS!

But reading documentation at

https://developers.google.com/custom-search/docs/xml_results#numsp

it says that:

Optional. The num parameter identifies the number of search results to return.

The default num value is 10, and the maximum value is 20. If you request more than 20 results, only 20 results will be returned.

Note: If the total number of search results is less than the requested number of results, all available search results will be returned.

Someone has experienced this problem?

PS: I've tried also to send that REST request configuring my new Custom Search Engine to: Site Search: Starts at $100 per year, ads are optional on results pages.

But nothing has changed no way to obtain 20 results in a request/page

1 Answer 1

4

This documentation url has descriptions of each parameter. It also says num is restricted to integers between 1 and 10, inclusive.

https://developers.google.com/custom-search/v1/using_rest#query-params

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.