API reference
Search the web index
/v1/search Returns ranked web results in the same envelope as POST /api/v1/search, projected to url, title, description, and language. The result cap is 50 and the API does not paginate.
- Authentication
- Send an API key or a service-account access token as a Bearer token.
- Billing
- Billing or an account spend limit can reject this request with 402.
- Rate limits
- A 429 response carries Retry-After; wait that long, then retry with backoff.
Parameters
querystringqueryRequiredThe search text.
Minimum length1
Maximum length512
limitintegerqueryOptionalThe maximum number of results.
Default20
Minimum1
Maximum50
langstringqueryOptionalA two-letter lowercase language code that results must match.
Pattern^[a-z]{2}$
rankingSearchRankingqueryOptionalWhat the ranking favors. The default is balanced.
Allowedprecisionbalancedauthoritycontent_gap
Responses
- 200
Ranked projected search results
SearchPostResponseX-RateLimit-LimitX-RateLimit-RemainingX-RateLimit-ResetX-Request-ID - 400
The query violated the public contract
SearchV1ErrorX-Request-ID - 401
A valid API key is required
SearchV1ErrorX-Request-ID - 402
Billing or a spend limit rejected execution
SearchV1ErrorX-Request-ID - 403
The API key lacks search permission
SearchV1ErrorX-Request-ID - 429
A rate limit rejected execution
SearchV1ErrorRetry-AfterX-RateLimit-LimitX-RateLimit-RemainingX-RateLimit-ResetX-Request-ID - 500
The service could not safely complete the request
SearchV1ErrorX-Request-ID - 502
The search request could not be completed
SearchV1ErrorX-Request-ID - 503
Search is temporarily unavailable
SearchV1ErrorX-Request-ID
SearchPostResponse
Public POST search response.
duration_msintegerRequiredThe time taken to answer, in milliseconds.
Minimum0
request_idstringRequiredThe reference of the request, to quote when contacting support.
resultsProjectedPageResult[]RequiredThe results, best first.
selectSearchResultField[]RequiredThe fields each result returns, after the default is applied.
Schemas
ErrorCode
Machine-readable product API failure.
unauthenticatedforbiddeninvalid_requestnot_foundconflictpayment_requiredtoo_many_requestsupstreaminternal
ErrorRecovery
Browser-safe recovery action selected by the authoritative product boundary.
| Variant | Type |
|---|---|
| 1 | object |
| 2 | object |
PageResultFields
Optional nullable projected fields. Each property is omitted when not selected, `null` when selected but unavailable, or carries its typed value.
anchornull | stringOptionalAggregated inbound anchor text.
authornull | stringOptionalPage author.
categoriesnull | object[]OptionalScored taxonomy categories.
content_anglenull | stringOptionalClassified content angle.
descriptionnull | stringOptionalResult description.
document_intentnull | stringOptionalClassified document intent.
domainnull | stringOptionalRegistrable or host domain.
domain_refdomainsnull | integerOptionalDomain referring-domain count.
first_seennull | stringOptionalFirst-seen timestamp.
highlightsnull | string[]OptionalUp to three query-relevant passages.
languagenull | stringOptionalDocument language.
locationnull | stringOptionalGeographic location code.
page_typenull | stringOptionalPage content type.
publish_timenull | stringOptionalPublished timestamp.
refdomainsnull | integerOptionalReferring-domain count.
republishednull | booleanOptionalWhether the document was republished.
rule_typenull | stringOptionalApplied rule type.
site_namenull | stringOptionalSite display name.
titlenull | stringOptionalPage title.
urlnull | stringOptionalCanonical page URL.
word_countnull | integerOptionalVisible word count.
ProjectedPageResult
One ranked projected result.
fieldsPageResultFieldsRequiredExactly the requested fields.
rankintegerRequiredOne-based result rank.
Minimum1
SearchRanking
What the results should prioritize.
precisionbalancedauthoritycontent_gap
SearchResultField
Public fields that may be selected in a search response.
urltitledescriptionanchorsite_nameauthorlanguagedomaincategorieslocationpage_typepublish_timefirst_seenrefdomainsdomain_refdomainsword_countrule_typedocument_intentcontent_anglerepublishedhighlights
SearchV1Error
Search v1's original closed error envelope.
codeErrorCodeRequiredClosed status category.
Allowedunauthenticatedforbiddeninvalid_requestnot_foundconflictpayment_requiredtoo_many_requestsupstreaminternal
messagestringRequiredSafe operator diagnostic.
reasonSearchV1ErrorReasonRequiredClosed Search v1 reason.
Allowedmalformed_requestauthentication_requiredpermission_deniedapi_key_name_invalidspend_policy_invalidrate_policy_invalidresource_not_foundstate_conflictinsufficient_fundsspend_limit_exceededrate_limit_exceededdependency_unavailableinternal_failure
recoverynull | ErrorRecoveryOptionalrequest_idstring | nullOptionalThe request reference, equal to the response's `X-Request-ID`; quote it to support.
validationnull | ValidationReportOptional
SearchV1ErrorReason
Closed failure-reason vocabulary retained for the published Search v1 contract.
malformed_requestauthentication_requiredpermission_deniedapi_key_name_invalidspend_policy_invalidrate_policy_invalidresource_not_foundstate_conflictinsufficient_fundsspend_limit_exceededrate_limit_exceededdependency_unavailableinternal_failure
ValidationIssue
One actionable, privacy-safe contract violation.
allowed_valuesarray | nullOptionalMaximum items16
codestringRequiredStable, extensible machine-readable category.
Maximum length64
pathstringRequiredRFC 6901 pointer to the rejected location; empty means the root value.
Maximum length1024
suggestionstringRequiredCode-owned instruction for correcting the request.
Maximum length512
ValidationReport
Bounded validation feedback shared by model, REST, and MCP boundaries.
contractstringRequiredStable contract name, normally the published schema component name.
Maximum length128
issuesValidationIssue[]RequiredAt most eight deterministic violations. Correct every issue before retrying.
Maximum items8
truncatedbooleanRequiredWhether more violations were omitted; retry after correcting the listed issues.
Use this request as an agent skill
Give your agent a reusable Yep Search API call.
Place the file at .agents/skills/yep-search/SKILL.md.
---
name: yep-search
description: Search the web with the Yep Search API when a task needs current external sources or ranked web results.
---
# Search with Yep
Use the Yep Search API for requests that need web search results.
1. Read `YEP_API_KEY` from the environment. If it is missing, explain that it must be set and stop. Never ask the user to paste the key into chat, print it, or write it to source control.
2. Send the request with cURL, replacing the example query with the user's search terms:
```sh
curl --get 'https://platform.yep.com/api/v1/search' \
--header "Authorization: Bearer $YEP_API_KEY" \
--data-urlencode 'query=carbon border tax 2026' \ curl --get "https://platform.yep.com/api/v1/search" \
--header "Authorization: Bearer $YEP_API_KEY" \
--data-urlencode 'query=carbon border tax 2026' {
"duration_ms": 0,
"request_id": "string",
"results": [
{
"fields": {},
"rank": 1
}
],
"select": [
"url"
]
}