Yext Answers API icon

Yext Answers API

Interact with Yext Answers API

Vertical Query

AI-generated

Summary

Execute a vertical search query on the Yext Answers API to retrieve entities matching specified search criteria within a particular vertical of a search experience.

Inputs

  • Account Id (required) — Your Yext account identifier to specify which account data to query.
  • V (required) — API version date in YYYYMMDD format to specify the API version to use.
  • Experience Key (required) — Unique string key identifying the search experience.
  • Vertical Key (required) — Unique string key identifying the vertical (category) to query.
  • Locale (required) — Locale code (e.g., en_GB) to filter entities by locale-specific profiles.
  • Input — User's search term to query against the vertical.
  • Version — Label or version number of the experience configuration to use, such as STAGING or PRODUCTION.
  • Location — User's location as a latitude,longitude string (e.g., "40.740957,-73.987565") to influence location-aware results.
  • Location Radius — Radius in meters to apply to location filters without explicit radius.
  • Session Id — UUID to track session state for analytics when cookies are blocked.
  • Limit — Maximum number of results to return (default 10).
  • Offset — Number of results to skip for pagination (default 0).
  • Query Trigger — String logged to analytics denoting query trigger context, e.g., 'suggest' or 'initialize'.
  • Context — URL-encoded JSON object passed to query rules for dynamic filtering or rule triggering.
  • Referrer Page Url — URL of the webpage that referred the query, used for analytics.
  • Skip Spell Check — Boolean to decide if spell checking of the query should be skipped (default true).
  • Filters — URL-encoded JSON object defining one or more filtering conditions to narrow results by fields and matchers.
  • Facet Filters — URL-encoded JSON object representing checked facet options to filter results.
  • Retrieve Facets — Boolean to specify whether to compute facets for the query (default true).
  • Sort Bys — URL-encoded JSON array defining sorting options for results by type (RELEVANCE, ENTITY_DISTANCE, FIELD) and direction.
  • Ignore Query Rules — Boolean to ignore query rules that would otherwise alter results (default true).
  • Query Id — UUID of the query to associate multiple paginated requests.
  • Source — String indicating source of the query for analytics (e.g., 'HOME_HEADER'), defaults to 'STANDARD'.
  • Js Lib Version — Deprecated version of Search UI used for this request.

Output shape

a JSON object containing the vertical search results returned by the Yext Answers API for the provided query parameters.

The response includes matched entities, facets (if requested), and metadata to support pagination and analytics. Results are limited and offset based on inputs, with various optional query customizations available.

Discussion