GET
/
search
curl --request GET \
  --url https://api.ydc-index.io/search \
  --header 'X-API-Key: <api-key>'
{
  "hits": [
    {
      "url": "https://you.com",
      "title": "The World's Greatest Search Engine!",
      "description": "Search on YDC",
      "thumbnail_url": "https://www.somethumbnailsite.com/thumbnail.jpg",
      "snippets": [
        "I'm an AI assistant that helps you get more done. What can I help you with?"
      ]
    }
  ],
  "latency": 1
}

Authorizations

X-API-Key
string
headerrequired

Query Parameters

query
string
required

Query string for searching index

num_web_results
integer

The max number of web results to return, must be under 20

offset
integer

The offset, in multiples of num_web_results. I.e if num_web_results = 5, and offset=1, the API will return results 5-10. The maximum value for offset is 9.

country
string

Country Code, one of ['AR', 'AU', 'AT', 'BE', 'BR', 'CA', 'CL', 'DK', 'FI', 'FR', 'DE', 'HK', 'IN', 'ID', 'IT', 'JP', 'KR', 'MY', 'MX', 'NL', 'NZ', 'NO', 'CN', 'PL', 'PT', 'PH', 'RU', 'SA', 'ZA', 'ES', 'SE', 'CH', 'TW', 'TR', 'GB', 'US']

safesearch
string

Safesearch settings, one of off, moderate, strict, defaults to moderate

Response

200 - application/json
hits
object[]
latency
number