For the complete documentation index, see llms.txt. This page is also available as Markdown.

Examples

Worked discover requests for each search mode.

Worked discover requests for each search mode. Each request body is sent to POST /discover.

Search using keywords or natural language queries. DISCOVR supports both simple keyword matching and natural language understanding — you can search the way your users would ask.

{
  "context": {
    "version": "2.0.0",
    "action": "discover",
    "messageId": "55555555-5555-5555-5555-555555555555",
    "transactionId": "66666666-6666-6666-6666-666666666666",
    "timestamp": "2026-03-26T11:00:00Z",
    "bapId": "bap.myapp.in",
    "bapUri": "https://bap.myapp.in",
    "networkId": "retail-grocery"
  },
  "message": {
    "intent": {
      "textSearch": "Coffee"
    }
  }
}

You can also use natural language queries — the service understands conversational phrasing and extracts the relevant search intent:

The service matches against resource names, descriptions, and domain-specific attributes to find the most relevant results.

Find resources available near a location. Uses spatial queries with CQL2-JSON semantics.

This finds all resources available within 1 km of the specified coordinates (Mysore in this example).

Field
Description

op

Spatial operation — S_DWITHIN (within distance)

targets

JSONPath to the geo field in the resource

geometry

GeoJSON point with [longitude, latitude]

distanceMeters

Search radius in meters

3. JSONPath Filter

Query resources and offers using JSONPath expressions for fine-grained attribute filtering.

This finds all offers with a flat discount where the price is under 100.

4. Combining Search Modes

You can combine text search with spatial or filter queries in a single request:

This finds coffee-related resources available within 5 km of Bengaluru HSR Layout.

5. Retrieving Inactive or Expired Catalogs

By default DISCOVR returns only active and currently-valid catalogs. To retrieve catalogs that are inactive or outside their validity window, pass the active and/or validity query parameters on the request URL. The request body is unchanged.

Returns only catalogs that are provably out of their validity window (expired or not yet valid):

Other combinations:

Request
Returns

POST /discover (no params)

Active, currently-valid catalogs (default)

POST /discover?active=false

Only catalogs explicitly marked inactive

POST /discover?validity=false

Only expired / not-yet-valid catalogs

POST /discover?active=false&validity=false

Only catalogs that are both inactive and out of window

See Usage for the full semantics.

See Usage for the full response format.

Last updated

Was this helpful?