> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nimbleway.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Search



## OpenAPI

````yaml /api-reference/openapi.json post /v2/search
openapi: 3.1.0
info:
  title: Nimble SDK
  version: 1.0.0
  description: The AI-Native SDK for Real-Time Web Data at scale
servers:
  - url: https://sdk.nimbleway.com
security: []
paths:
  /v2/search:
    post:
      tags:
        - Search
      summary: Search
      operationId: search_search_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SearchRequest'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchResponse'
          description: Successful Response
      security:
        - BearerAuth: []
components:
  schemas:
    SearchRequest:
      description: Request body model for the /search endpoint.
      properties:
        query:
          description: Search query string
          minLength: 1
          title: Query
          type: string
        search_depth:
          anyOf:
            - $ref: '#/components/schemas/SearchDepth'
            - type: 'null'
          description: >-
            Content richness: 'lite' (titles, URLs, snippets) or 'standard'
            (rich content, default).
        full_content:
          default: false
          description: >-
            Return full page content for each result, in addition to its title,
            url, and description. Works with either search_depth value. Higher
            recall and cost.
          title: Full Content
          type: boolean
        content_type:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          description: >-
            Filter by content type (only supported with focus=general). Supports
            semantic groups ('documents', 'spreadsheets', 'presentations') and
            specific formats ('pdf', 'docx', 'xlsx', etc.)
          title: Content Type
        country:
          default: US
          description: Country code for geo-targeted results (e.g., 'US', 'GB', 'IL')
          title: Country
          type: string
        end_date:
          anyOf:
            - type: string
            - type: 'null'
          description: 'Filter results before this date (format: YYYY-MM-DD or YYYY)'
          title: End Date
        exclude_domains:
          anyOf:
            - items:
                type: string
              maxItems: 50
              type: array
            - type: 'null'
          description: List of domains to exclude from search results. Maximum 50 domains.
          title: Exclude Domains
        focus:
          anyOf:
            - type: string
            - items:
                type: string
              type: array
          default: general
          description: >-
            Search focus mode (e.g., 'general', 'news', 'shopping') or a list of
            explicit subagent names (e.g., ['amazon_serp', 'target_serp'])
          title: Focus
        include_domains:
          anyOf:
            - items:
                type: string
              maxItems: 50
              type: array
            - type: 'null'
          description: List of domains to include in search results. Maximum 50 domains.
          title: Include Domains
        locale:
          default: en
          description: Language/locale code (e.g., 'en', 'fr', 'de')
          title: Locale
          type: string
        max_results:
          default: 10
          description: >-
            Maximum number of results to return. Actual count may be lower
            depending on availability.
          maximum: 100
          minimum: 1
          title: Max Results
          type: integer
        output_format:
          $ref: '#/components/schemas/ParsingType'
          default: markdown
          description: 'Output format: plain_text, markdown, or simplified_html'
        start_date:
          anyOf:
            - type: string
            - type: 'null'
          description: 'Filter results after this date (format: YYYY-MM-DD or YYYY)'
          title: Start Date
        time_range:
          anyOf:
            - $ref: '#/components/schemas/TimeRange'
            - type: 'null'
          description: >-
            Filter by recency: hour, day, week, month, or year. Cannot be
            combined with start_date/end_date.
      required:
        - query
      title: SearchRequest
      type: object
    SearchResponse:
      description: >-
        Response model from SearchService with results.


        Note: request_id is always a valid UUID generated internally by the
        middleware,

        so no validation is needed.
      properties:
        request_id:
          description: Unique identifier for this request (UUID)
          title: Request Id
          type: string
        results:
          items:
            $ref: '#/components/schemas/ResultModel'
          title: Results
          type: array
        total_results:
          description: Number of results returned
          title: Total Results
          type: integer
      required:
        - total_results
        - results
        - request_id
      title: SearchResponse
      type: object
    SearchDepth:
      description: >-
        Controls content richness and latency of search results.


        - lite: Token-efficient metadata for high-volume pipelines (title, URL,
        description only)

        - standard: Rich content (~2K chars) optimized for AI agents
      enum:
        - lite
        - standard
      title: SearchDepth
      type: string
    ParsingType:
      description: Enum representing the parsing types supported by Nimble
      enum:
        - plain_text
        - markdown
        - simplified_html
      title: ParsingType
      type: string
    TimeRange:
      description: Time range filters passed to Webit SERP API as 'time' parameter.
      enum:
        - hour
        - day
        - week
        - month
        - year
      title: TimeRange
      type: string
    ResultModel:
      description: |-
        Unified result model for all search types (SERP and WSA).

        This model provides a consistent structure for search results,
        with platform-specific data in additional_data and typed metadata.
      properties:
        additional_data:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          description: >-
            Platform-specific fields (e.g., price, rating, publish_date).
            Omitted from response when no extra data.
          title: Additional Data
        content:
          description: >-
            Full scraped page content, when `full_content` was requested. Empty
            string otherwise.
          title: Content
          type: string
        description:
          title: Description
          type: string
        metadata:
          anyOf:
            - $ref: '#/components/schemas/SERPMetadata'
            - $ref: '#/components/schemas/WSAMetadata'
          description: >-
            Shape depends on the focus mode. SERP-backed modes (e.g. general,
            news) return SERPMetadata: position, entity_type, country, locale.
            WSA-backed modes (e.g. shopping, social, geo) return WSAMetadata:
            agent_name only.
          title: Metadata
        title:
          title: Title
          type: string
        url:
          title: Url
          type: string
      required:
        - title
        - description
        - url
        - content
        - metadata
      title: ResultModel
      type: object
    SERPMetadata:
      description: Metadata for SERP-based search results (general, news, location).
      properties:
        country:
          title: Country
          type: string
        driver:
          anyOf:
            - type: string
            - type: 'null'
          title: Driver
        entity_type:
          title: Entity Type
          type: string
        locale:
          title: Locale
          type: string
        position:
          title: Position
          type: integer
      required:
        - position
        - entity_type
        - country
        - locale
      title: SERPMetadata
      type: object
    WSAMetadata:
      description: Metadata for WSA-based search results.
      properties:
        agent_name:
          title: Agent Name
          type: string
      required:
        - agent_name
      title: WSAMetadata
      type: object
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.