Google AI Mode
Query Google AI Mode via API. JSON with text_blocks, references, and shopping_results.
Credit cost: 3 credits per call
ApiKeyAuthx-api-key<token>Your API key. Include it in the x-api-key header for every request.
query*stringThe question or search query you want Google AI Mode to answer (supports advanced operators like site:, inurl:, intitle:).
location?stringHuman-readable location to originate the search from (e.g. New York, NY, Paris, France). If several locations match, the most popular one is used. Note: location and uule cannot be used together.
uule?stringGoogle encoded location parameter. Use for precise geo targeting. Note: uule and location cannot be used together.
google_domain?stringGoogle domain to use for the search. Defaults to google.com.
Examples:
google.comgoogle.co.ukgoogle.fr
Example:
google.com"google.com"gl?stringCountry to use for the Google search. Two-letter country code (e.g. us for the United States, uk for United Kingdom, or fr for France).
Example:
ushl?stringLanguage to use for the Google search. Two or three-letter language code (e.g. en, es, fr), optionally followed by a region code (e.g. en-gb, es-419).
Example:
encr?stringLimit results to one or more countries. Use country{XX} with | as delimiter (e.g. countryFR|countryDE).
Example:
countryUSlr?stringLimit results to one or more languages. Use lang_{xx} with | as delimiter (e.g. lang_fr|lang_de).
Example:
lang_enfields?stringComma-separated list of response fields to return, with dot notation for nested fields (e.g. name,location.city).
is_async?booleanRun the request as a background job: the API answers 202 with a job_id to poll on GET /v1/jobs/{id}.
falsesoft_fail?booleanReturn HTTP 200 even when the request fails; the error is in the error field of the body.
falseSuccessful response
application/json- response
references?array<>text_blocks?array<>shopping_results?array<unknown>search_parameters?reconstructed_markdown?stringcurl -X GET 'https://api.autom.dev/v1/google/search/ai?query=string'{ "references": [ { "link": "https://www.mozilla.org/firefox/", "index": 0, "title": "Firefox Browser", "source": "mozilla.org", "snippet": "Official Firefox download and overview.", "thumbnail": "https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcFirefoxThumb", "source_icon": "https://www.google.com/s2/favicons?domain=mozilla.org&sz=128" }, { "link": "https://en.wikipedia.org/wiki/Firefox", "index": 1, "title": "Firefox - Wikipedia", "source": "en.wikipedia.org" } ], "text_blocks": [ { "type": "paragraph", "snippet": "Mozilla Firefox is a free, open-source web browser developed by the Mozilla Foundation. It is available on desktop and mobile, supports extensions, and focuses on privacy controls such as Enhanced Tracking Protection." }, { "type": "heading", "level": 3, "snippet": "Key features" }, { "list": [ { "title": "Open source", "snippet": "Free and open-source, maintained by the Mozilla Foundation.", "snippet_links": [ { "link": "https://www.mozilla.org/", "text": "Mozilla Foundation" } ], "reference_indexes": [ 0 ] }, { "snippet": "Available on desktop and mobile platforms." }, { "snippet": "Enhanced Tracking Protection to limit cross-site tracking." } ], "type": "list" } ], "shopping_results": [], "search_parameters": { "q": "what is mozilla firefox", "gl": "us", "hl": "en", "engine": "google_ai_mode" }, "reconstructed_markdown": "Mozilla Firefox is a free, open-source web browser developed by the Mozilla Foundation. It is available on desktop and mobile, supports extensions, and focuses on privacy controls such as Enhanced Tracking Protection.\n\n### Key features\n\n- Free and open-source, maintained by the Mozilla Foundation.\n- Available on desktop and mobile platforms.\n- Enhanced Tracking Protection to limit cross-site tracking."}