Search and Distill
Run a Google web search for the supplied query and Distill each result with the requested formats. Each result reports its own success flag.
Authorization
YOUR_API_KEY Enter your API key from the Thunderbit Dashboard. The header format will be: Authorization: Bearer YOUR_API_KEY
In: header
Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Search query (max 500 characters).
best web scraping tools 20265Number of results to return (1–10, default 5).
5Restrict the search to a single domain.
techcrunch.comOutput formats applied to each result page (same shape as the Distill formats array).
[
"markdown",
{
"type": "summary"
}
]30000Per-result Distill timeout in milliseconds (default 30000, max 60000).
Response
application/jsonSearch succeeded. Per-result Distill outcomes are reported individually in `data.results[].success`.
trueShow child attributes
Echo of the input query.
Number of results returned.
Number of results whose Distill stage succeeded.
Total credits charged for this request.
Show child attributes
Result URL.
Search result title.
Search result snippet from Google.
1-based rank in the search results.
Whether per-result Distill succeeded.
Distilled Markdown for this result (when requested).
Result summary (when requested).
Answer to the question format (when requested).
Highlighted passages (when requested).
Links extracted from the result page (when requested).
Show child attributes
Visible link text.
Read moreResolved absolute URL.
https://example.com/articleImages extracted from the result page (when requested).
Show child attributes
Image source URL.
https://example.com/hero.pngImage alt text.
Hero bannerImage width in pixels.
Image height in pixels.
Distill error message for this result (only when success=false).
Invalid request parameters
falseShow child attributes
Canonical error codes returned in the error.code field (LEGACY) or error.status field (GOOGLE_RPC). Codes are grouped by HTTP status:
400 Bad Request
INVALID_URL— URL format is invalidINVALID_SCHEMA— JSON Schema is invalidINVALID_PARAMETER— One or more request parameters failed validationSCHEMA_OR_PROMPT_REQUIRED—schema(orprompt) is required for extractionSCHEMA_AND_PROMPT_EXCLUSIVE—schemaandpromptcannot both be providedBATCH_SIZE_EXCEEDED— Batch request exceeds the 100-URL limitMALFORMED_REQUEST_BODY— Request body is not valid JSON
401 Unauthorized
API_KEY_MISSING—Authorizationheader missingAPI_KEY_INVALID_FORMAT— API key format is invalidAPI_KEY_NOT_FOUND— API key not found in the systemAPI_KEY_REVOKED— API key has been revokedAPI_KEY_DISABLED— API key has been disabledAPI_KEY_EXPIRED— API key has expiredINVALID_API_KEY— (deprecated, use the specific API_KEY_ codes above)*
402 Payment Required
INSUFFICIENT_CREDITS— Not enough credits on the account
404 Not Found
JOB_NOT_FOUND— Batch job not foundRESOURCE_NOT_FOUND— Generic resource not found
408 Request Timeout
REQUEST_TIMEOUT— The API request timed outSCRAPE_TIMEOUT— The target page took too long to respond
422 Unprocessable Entity
SCRAPE_SSL_ERROR— Target site has SSL/TLS problemsSCRAPE_DNS_RESOLUTION_ERROR— Cannot resolve target hostnameSCRAPE_SITE_ERROR— Target site returned an errorSCRAPE_EMPTY_CONTENT— Target page returned empty contentSCRAPE_CONTENT_TOO_LARGE— Target page exceeds size limitsSCRAPE_TARGET_FORBIDDEN— Target site refused access (403)SCRAPE_TARGET_NOT_FOUND— Target URL returned 404SCRAPE_UNSUPPORTED_FILE— Target file type is not supported
429 Too Many Requests
RATE_LIMIT_EXCEEDED— Account rate limit triggeredSCRAPE_TARGET_RATE_LIMITED— Target site rate-limited our request
500 Internal Server Error
INTERNAL_ERROR— Generic internal errorDISTILL_FAILED— Distillation pipeline failedEXTRACT_FAILED— Extraction pipeline failedPIPELINE_ERROR— Pipeline step reported a failureAI_EXTRACTION_FAILED— AI extraction step failedMARKDOWN_CONVERSION_FAILED— HTML-to-Markdown conversion failed
502 Bad Gateway
SCRAPE_ALL_PROVIDERS_FAILED— All scraping providers failedUPSTREAM_BAD_GATEWAY— Upstream returned an invalid response
503 Service Unavailable
SCRAPE_PROVIDER_UNAVAILABLE— Scraping provider is unavailableAI_SERVICE_UNAVAILABLE— AI service is unavailableDOWNSTREAM_SERVICE_UNAVAILABLE— A downstream service is temporarily unavailable
504 Gateway Timeout
UPSTREAM_TIMEOUT— Upstream gateway timed outAI_TIMEOUT— AI service call timed out
HTTP status code (LEGACY format) or canonical error code (GOOGLE_RPC format). See the API_ERROR_FORMAT note in the Error schema description
Human-readable error message
Optional structured details — for example, field-level validation errors as { field: message } pairs
Authentication failed, invalid API Key
falseShow child attributes
Canonical error codes returned in the error.code field (LEGACY) or error.status field (GOOGLE_RPC). Codes are grouped by HTTP status:
400 Bad Request
INVALID_URL— URL format is invalidINVALID_SCHEMA— JSON Schema is invalidINVALID_PARAMETER— One or more request parameters failed validationSCHEMA_OR_PROMPT_REQUIRED—schema(orprompt) is required for extractionSCHEMA_AND_PROMPT_EXCLUSIVE—schemaandpromptcannot both be providedBATCH_SIZE_EXCEEDED— Batch request exceeds the 100-URL limitMALFORMED_REQUEST_BODY— Request body is not valid JSON
401 Unauthorized
API_KEY_MISSING—Authorizationheader missingAPI_KEY_INVALID_FORMAT— API key format is invalidAPI_KEY_NOT_FOUND— API key not found in the systemAPI_KEY_REVOKED— API key has been revokedAPI_KEY_DISABLED— API key has been disabledAPI_KEY_EXPIRED— API key has expiredINVALID_API_KEY— (deprecated, use the specific API_KEY_ codes above)*
402 Payment Required
INSUFFICIENT_CREDITS— Not enough credits on the account
404 Not Found
JOB_NOT_FOUND— Batch job not foundRESOURCE_NOT_FOUND— Generic resource not found
408 Request Timeout
REQUEST_TIMEOUT— The API request timed outSCRAPE_TIMEOUT— The target page took too long to respond
422 Unprocessable Entity
SCRAPE_SSL_ERROR— Target site has SSL/TLS problemsSCRAPE_DNS_RESOLUTION_ERROR— Cannot resolve target hostnameSCRAPE_SITE_ERROR— Target site returned an errorSCRAPE_EMPTY_CONTENT— Target page returned empty contentSCRAPE_CONTENT_TOO_LARGE— Target page exceeds size limitsSCRAPE_TARGET_FORBIDDEN— Target site refused access (403)SCRAPE_TARGET_NOT_FOUND— Target URL returned 404SCRAPE_UNSUPPORTED_FILE— Target file type is not supported
429 Too Many Requests
RATE_LIMIT_EXCEEDED— Account rate limit triggeredSCRAPE_TARGET_RATE_LIMITED— Target site rate-limited our request
500 Internal Server Error
INTERNAL_ERROR— Generic internal errorDISTILL_FAILED— Distillation pipeline failedEXTRACT_FAILED— Extraction pipeline failedPIPELINE_ERROR— Pipeline step reported a failureAI_EXTRACTION_FAILED— AI extraction step failedMARKDOWN_CONVERSION_FAILED— HTML-to-Markdown conversion failed
502 Bad Gateway
SCRAPE_ALL_PROVIDERS_FAILED— All scraping providers failedUPSTREAM_BAD_GATEWAY— Upstream returned an invalid response
503 Service Unavailable
SCRAPE_PROVIDER_UNAVAILABLE— Scraping provider is unavailableAI_SERVICE_UNAVAILABLE— AI service is unavailableDOWNSTREAM_SERVICE_UNAVAILABLE— A downstream service is temporarily unavailable
504 Gateway Timeout
UPSTREAM_TIMEOUT— Upstream gateway timed outAI_TIMEOUT— AI service call timed out
HTTP status code (LEGACY format) or canonical error code (GOOGLE_RPC format). See the API_ERROR_FORMAT note in the Error schema description
Human-readable error message
Optional structured details — for example, field-level validation errors as { field: message } pairs
Insufficient credits
falseShow child attributes
Canonical error codes returned in the error.code field (LEGACY) or error.status field (GOOGLE_RPC). Codes are grouped by HTTP status:
400 Bad Request
INVALID_URL— URL format is invalidINVALID_SCHEMA— JSON Schema is invalidINVALID_PARAMETER— One or more request parameters failed validationSCHEMA_OR_PROMPT_REQUIRED—schema(orprompt) is required for extractionSCHEMA_AND_PROMPT_EXCLUSIVE—schemaandpromptcannot both be providedBATCH_SIZE_EXCEEDED— Batch request exceeds the 100-URL limitMALFORMED_REQUEST_BODY— Request body is not valid JSON
401 Unauthorized
API_KEY_MISSING—Authorizationheader missingAPI_KEY_INVALID_FORMAT— API key format is invalidAPI_KEY_NOT_FOUND— API key not found in the systemAPI_KEY_REVOKED— API key has been revokedAPI_KEY_DISABLED— API key has been disabledAPI_KEY_EXPIRED— API key has expiredINVALID_API_KEY— (deprecated, use the specific API_KEY_ codes above)*
402 Payment Required
INSUFFICIENT_CREDITS— Not enough credits on the account
404 Not Found
JOB_NOT_FOUND— Batch job not foundRESOURCE_NOT_FOUND— Generic resource not found
408 Request Timeout
REQUEST_TIMEOUT— The API request timed outSCRAPE_TIMEOUT— The target page took too long to respond
422 Unprocessable Entity
SCRAPE_SSL_ERROR— Target site has SSL/TLS problemsSCRAPE_DNS_RESOLUTION_ERROR— Cannot resolve target hostnameSCRAPE_SITE_ERROR— Target site returned an errorSCRAPE_EMPTY_CONTENT— Target page returned empty contentSCRAPE_CONTENT_TOO_LARGE— Target page exceeds size limitsSCRAPE_TARGET_FORBIDDEN— Target site refused access (403)SCRAPE_TARGET_NOT_FOUND— Target URL returned 404SCRAPE_UNSUPPORTED_FILE— Target file type is not supported
429 Too Many Requests
RATE_LIMIT_EXCEEDED— Account rate limit triggeredSCRAPE_TARGET_RATE_LIMITED— Target site rate-limited our request
500 Internal Server Error
INTERNAL_ERROR— Generic internal errorDISTILL_FAILED— Distillation pipeline failedEXTRACT_FAILED— Extraction pipeline failedPIPELINE_ERROR— Pipeline step reported a failureAI_EXTRACTION_FAILED— AI extraction step failedMARKDOWN_CONVERSION_FAILED— HTML-to-Markdown conversion failed
502 Bad Gateway
SCRAPE_ALL_PROVIDERS_FAILED— All scraping providers failedUPSTREAM_BAD_GATEWAY— Upstream returned an invalid response
503 Service Unavailable
SCRAPE_PROVIDER_UNAVAILABLE— Scraping provider is unavailableAI_SERVICE_UNAVAILABLE— AI service is unavailableDOWNSTREAM_SERVICE_UNAVAILABLE— A downstream service is temporarily unavailable
504 Gateway Timeout
UPSTREAM_TIMEOUT— Upstream gateway timed outAI_TIMEOUT— AI service call timed out
HTTP status code (LEGACY format) or canonical error code (GOOGLE_RPC format). See the API_ERROR_FORMAT note in the Error schema description
Human-readable error message
Optional structured details — for example, field-level validation errors as { field: message } pairs
Too many requests, rate limit triggered
falseShow child attributes
Canonical error codes returned in the error.code field (LEGACY) or error.status field (GOOGLE_RPC). Codes are grouped by HTTP status:
400 Bad Request
INVALID_URL— URL format is invalidINVALID_SCHEMA— JSON Schema is invalidINVALID_PARAMETER— One or more request parameters failed validationSCHEMA_OR_PROMPT_REQUIRED—schema(orprompt) is required for extractionSCHEMA_AND_PROMPT_EXCLUSIVE—schemaandpromptcannot both be providedBATCH_SIZE_EXCEEDED— Batch request exceeds the 100-URL limitMALFORMED_REQUEST_BODY— Request body is not valid JSON
401 Unauthorized
API_KEY_MISSING—Authorizationheader missingAPI_KEY_INVALID_FORMAT— API key format is invalidAPI_KEY_NOT_FOUND— API key not found in the systemAPI_KEY_REVOKED— API key has been revokedAPI_KEY_DISABLED— API key has been disabledAPI_KEY_EXPIRED— API key has expiredINVALID_API_KEY— (deprecated, use the specific API_KEY_ codes above)*
402 Payment Required
INSUFFICIENT_CREDITS— Not enough credits on the account
404 Not Found
JOB_NOT_FOUND— Batch job not foundRESOURCE_NOT_FOUND— Generic resource not found
408 Request Timeout
REQUEST_TIMEOUT— The API request timed outSCRAPE_TIMEOUT— The target page took too long to respond
422 Unprocessable Entity
SCRAPE_SSL_ERROR— Target site has SSL/TLS problemsSCRAPE_DNS_RESOLUTION_ERROR— Cannot resolve target hostnameSCRAPE_SITE_ERROR— Target site returned an errorSCRAPE_EMPTY_CONTENT— Target page returned empty contentSCRAPE_CONTENT_TOO_LARGE— Target page exceeds size limitsSCRAPE_TARGET_FORBIDDEN— Target site refused access (403)SCRAPE_TARGET_NOT_FOUND— Target URL returned 404SCRAPE_UNSUPPORTED_FILE— Target file type is not supported
429 Too Many Requests
RATE_LIMIT_EXCEEDED— Account rate limit triggeredSCRAPE_TARGET_RATE_LIMITED— Target site rate-limited our request
500 Internal Server Error
INTERNAL_ERROR— Generic internal errorDISTILL_FAILED— Distillation pipeline failedEXTRACT_FAILED— Extraction pipeline failedPIPELINE_ERROR— Pipeline step reported a failureAI_EXTRACTION_FAILED— AI extraction step failedMARKDOWN_CONVERSION_FAILED— HTML-to-Markdown conversion failed
502 Bad Gateway
SCRAPE_ALL_PROVIDERS_FAILED— All scraping providers failedUPSTREAM_BAD_GATEWAY— Upstream returned an invalid response
503 Service Unavailable
SCRAPE_PROVIDER_UNAVAILABLE— Scraping provider is unavailableAI_SERVICE_UNAVAILABLE— AI service is unavailableDOWNSTREAM_SERVICE_UNAVAILABLE— A downstream service is temporarily unavailable
504 Gateway Timeout
UPSTREAM_TIMEOUT— Upstream gateway timed outAI_TIMEOUT— AI service call timed out
HTTP status code (LEGACY format) or canonical error code (GOOGLE_RPC format). See the API_ERROR_FORMAT note in the Error schema description
Human-readable error message
Optional structured details — for example, field-level validation errors as { field: message } pairs
Internal server error
falseShow child attributes
Canonical error codes returned in the error.code field (LEGACY) or error.status field (GOOGLE_RPC). Codes are grouped by HTTP status:
400 Bad Request
INVALID_URL— URL format is invalidINVALID_SCHEMA— JSON Schema is invalidINVALID_PARAMETER— One or more request parameters failed validationSCHEMA_OR_PROMPT_REQUIRED—schema(orprompt) is required for extractionSCHEMA_AND_PROMPT_EXCLUSIVE—schemaandpromptcannot both be providedBATCH_SIZE_EXCEEDED— Batch request exceeds the 100-URL limitMALFORMED_REQUEST_BODY— Request body is not valid JSON
401 Unauthorized
API_KEY_MISSING—Authorizationheader missingAPI_KEY_INVALID_FORMAT— API key format is invalidAPI_KEY_NOT_FOUND— API key not found in the systemAPI_KEY_REVOKED— API key has been revokedAPI_KEY_DISABLED— API key has been disabledAPI_KEY_EXPIRED— API key has expiredINVALID_API_KEY— (deprecated, use the specific API_KEY_ codes above)*
402 Payment Required
INSUFFICIENT_CREDITS— Not enough credits on the account
404 Not Found
JOB_NOT_FOUND— Batch job not foundRESOURCE_NOT_FOUND— Generic resource not found
408 Request Timeout
REQUEST_TIMEOUT— The API request timed outSCRAPE_TIMEOUT— The target page took too long to respond
422 Unprocessable Entity
SCRAPE_SSL_ERROR— Target site has SSL/TLS problemsSCRAPE_DNS_RESOLUTION_ERROR— Cannot resolve target hostnameSCRAPE_SITE_ERROR— Target site returned an errorSCRAPE_EMPTY_CONTENT— Target page returned empty contentSCRAPE_CONTENT_TOO_LARGE— Target page exceeds size limitsSCRAPE_TARGET_FORBIDDEN— Target site refused access (403)SCRAPE_TARGET_NOT_FOUND— Target URL returned 404SCRAPE_UNSUPPORTED_FILE— Target file type is not supported
429 Too Many Requests
RATE_LIMIT_EXCEEDED— Account rate limit triggeredSCRAPE_TARGET_RATE_LIMITED— Target site rate-limited our request
500 Internal Server Error
INTERNAL_ERROR— Generic internal errorDISTILL_FAILED— Distillation pipeline failedEXTRACT_FAILED— Extraction pipeline failedPIPELINE_ERROR— Pipeline step reported a failureAI_EXTRACTION_FAILED— AI extraction step failedMARKDOWN_CONVERSION_FAILED— HTML-to-Markdown conversion failed
502 Bad Gateway
SCRAPE_ALL_PROVIDERS_FAILED— All scraping providers failedUPSTREAM_BAD_GATEWAY— Upstream returned an invalid response
503 Service Unavailable
SCRAPE_PROVIDER_UNAVAILABLE— Scraping provider is unavailableAI_SERVICE_UNAVAILABLE— AI service is unavailableDOWNSTREAM_SERVICE_UNAVAILABLE— A downstream service is temporarily unavailable
504 Gateway Timeout
UPSTREAM_TIMEOUT— Upstream gateway timed outAI_TIMEOUT— AI service call timed out
HTTP status code (LEGACY format) or canonical error code (GOOGLE_RPC format). See the API_ERROR_FORMAT note in the Error schema description
Human-readable error message
Optional structured details — for example, field-level validation errors as { field: message } pairs
Downstream service temporarily unavailable
falseShow child attributes
Canonical error codes returned in the error.code field (LEGACY) or error.status field (GOOGLE_RPC). Codes are grouped by HTTP status:
400 Bad Request
INVALID_URL— URL format is invalidINVALID_SCHEMA— JSON Schema is invalidINVALID_PARAMETER— One or more request parameters failed validationSCHEMA_OR_PROMPT_REQUIRED—schema(orprompt) is required for extractionSCHEMA_AND_PROMPT_EXCLUSIVE—schemaandpromptcannot both be providedBATCH_SIZE_EXCEEDED— Batch request exceeds the 100-URL limitMALFORMED_REQUEST_BODY— Request body is not valid JSON
401 Unauthorized
API_KEY_MISSING—Authorizationheader missingAPI_KEY_INVALID_FORMAT— API key format is invalidAPI_KEY_NOT_FOUND— API key not found in the systemAPI_KEY_REVOKED— API key has been revokedAPI_KEY_DISABLED— API key has been disabledAPI_KEY_EXPIRED— API key has expiredINVALID_API_KEY— (deprecated, use the specific API_KEY_ codes above)*
402 Payment Required
INSUFFICIENT_CREDITS— Not enough credits on the account
404 Not Found
JOB_NOT_FOUND— Batch job not foundRESOURCE_NOT_FOUND— Generic resource not found
408 Request Timeout
REQUEST_TIMEOUT— The API request timed outSCRAPE_TIMEOUT— The target page took too long to respond
422 Unprocessable Entity
SCRAPE_SSL_ERROR— Target site has SSL/TLS problemsSCRAPE_DNS_RESOLUTION_ERROR— Cannot resolve target hostnameSCRAPE_SITE_ERROR— Target site returned an errorSCRAPE_EMPTY_CONTENT— Target page returned empty contentSCRAPE_CONTENT_TOO_LARGE— Target page exceeds size limitsSCRAPE_TARGET_FORBIDDEN— Target site refused access (403)SCRAPE_TARGET_NOT_FOUND— Target URL returned 404SCRAPE_UNSUPPORTED_FILE— Target file type is not supported
429 Too Many Requests
RATE_LIMIT_EXCEEDED— Account rate limit triggeredSCRAPE_TARGET_RATE_LIMITED— Target site rate-limited our request
500 Internal Server Error
INTERNAL_ERROR— Generic internal errorDISTILL_FAILED— Distillation pipeline failedEXTRACT_FAILED— Extraction pipeline failedPIPELINE_ERROR— Pipeline step reported a failureAI_EXTRACTION_FAILED— AI extraction step failedMARKDOWN_CONVERSION_FAILED— HTML-to-Markdown conversion failed
502 Bad Gateway
SCRAPE_ALL_PROVIDERS_FAILED— All scraping providers failedUPSTREAM_BAD_GATEWAY— Upstream returned an invalid response
503 Service Unavailable
SCRAPE_PROVIDER_UNAVAILABLE— Scraping provider is unavailableAI_SERVICE_UNAVAILABLE— AI service is unavailableDOWNSTREAM_SERVICE_UNAVAILABLE— A downstream service is temporarily unavailable
504 Gateway Timeout
UPSTREAM_TIMEOUT— Upstream gateway timed outAI_TIMEOUT— AI service call timed out
HTTP status code (LEGACY format) or canonical error code (GOOGLE_RPC format). See the API_ERROR_FORMAT note in the Error schema description
Human-readable error message
Optional structured details — for example, field-level validation errors as { field: message } pairs