---
title: "Unified search"
method: POST
path: "/search"
tags: ["search"]
---

# Unified search

`POST /search`

Search items using both Elasticsearch (text) and Vertex AI (semantic) in parallel, merged and deduplicated by item

## Request body

- ModelsUnifiedSearchRequest
  - `limit` integer
  - `query` string

## Response `200`

OK

- ModelsSearchResponse
  - `alternatives_found` integer
  - `boms` ModelsBomResult[] — Unified search: BOMs / ERP files whose contained part numbers match the query. The frontend renders these in a grouped layout alongside the item results. Empty when Elasticsearch isn't configured or returns no hits.
    - `bom_id` string
    - `business_node_id` string
    - `matched_part_numbers` string[]
    - `name` string
    - `similarity_score` number
    - `status` string
    - `text_snippet` string
    - `total_lines` integer
    - `version` string
  - `business_id` string
  - `duplicates_found` integer
  - `erps` ModelsErpFileResult[]
    - `business_node_id` string
    - `erp_file_id` string
    - `filename` string
    - `matched_identifiers` string[]
    - `row_count` integer
    - `similarity_score` number
    - `source_erp` string
    - `text_snippet` string
  - `query` string
  - `results` ModelsItemResult[]
    - `category` string
    - `image_signed_url` string — Time-limited signed HTTPS URL for frontend access
    - `image_url` string — Original GCS URI (gs://...) to item image (from source document)
    - `is_alternative` boolean
    - `is_potential_duplicate` boolean
    - `is_preferred` boolean — Item is flagged as a preferred part
    - `item_id` string
    - `manufacturer` string
    - `part_number` string
    - `similarity_score` number
    - `source_filename` string — Filename of the source document
    - `text_snippet` string — Snippet from specs or OCR text
    - `title` string
  - `results_count` integer
  - `search_mode` string

## Other responses

- `400` — Invalid request
- `401` — Unauthorized
- `503` — Search service not available

---

[API](https://skmtc.net/resourcly/apis/resourcly-api.md) · [All operations](https://skmtc.net/resourcly/apis/resourcly-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/resourcly/resourcly-api/revisions/7f97d8cd0f1e/schema)
