API URL
POST /api/v1/web-search/search (GET single, POST batch)
Headers
Code
Content-Type: application/jsonBody Parameters
Param
Type
Description
q
required
string
Search query (1-256 chars)
limit
optional
number
Max related topics and results per section 1-10 (default 10)
queries
required
array
Batch queries (1-10 non-empty items max 256 chars each)
Example Request
Code
GET https://datpaq.com/api/v1/web-search/search?q=JavaScript&limit=5&api_key=your-api-keySuccessful Response
Status
HTML
200 OKBody
Code
{
"success": true,
"query": "JavaScript",
"abstract": "JavaScript",
"abstractText": "JavaScript is a high-level, interpreted programming language...",
"abstractUrl": "https://en.wikipedia.org/wiki/JavaScript",
"abstractSource": "Wikipedia",
"relatedTopics": [
{
"text": "ECMAScript",
"url": "https://duckduckgo.com/ECMAScript"
}
],
"results": [],
"fromCache": false,
"provider": "duckduckgo",
"metadata": {
"correlationId": "req_abc123",
"timestamp": "2026-10-14T12:00:00.000Z",
"processingTime": "42ms",
"api_token_name": null,
"rate_limit": {
"limit": null,
"remaining": null,
"reset": null
}
},
"updatedAt": "2026-10-14T12:00:00.000Z"
}Field
Type
success
boolean
query
string
abstract
string
abstractText
string
abstractUrl
string
abstractSource
string
relatedTopics
array
results
array
summary
object
fromCache
boolean
provider
string
metadata
object
metadata_correlationId
string
metadata_timestamp
string
metadata_processingTime
string
metadata_api_token_name
string
metadata_rate_limit
object
status
string
service
string
version
string
offlineTests
boolean
error
object
updatedAt
string
Error Response
Example
Code
HTTP 400 ValidationError: Missing/invalid q queries or limit — Request rejected before upstream call; HTTP 401 AuthenticationError: Gateway authentication failure — Request rejected due to missing or invalid API credentials; HTTP 404 NotFound: Unknown endpoint path — Request path does not map to available web-search routes; HTTP 429 RateLimitError: More than 120 API requests per client in 15 minutes — Request rejected by service rate limiter; HTTP 429 LookupBudgetExceeded: More than 120 upstream lookup units per identity in 15 minutes (one unit per query including cache hits) — Request rejected before upstream lookups; HTTP 502 UpstreamUnavailable: DuckDuckGo API failed or timed out — Search provider unavailable; HTTP 500 InternalError: Unexpected search failure — Search could not completeLast Updated: May 4, 2026