# Search

- Method: `GET`
- Path: `/search`
- Tier: Free
- HTML docs: https://docs.hiddensystems.ai/nebula/reference/get-search/
- Interactive docs: https://docs.hiddensystems.ai/nebula/api/#endpoint=get-search

## Description

Search everything Nebula tracks — stocks, commodities, indices, crypto, people, accounts, and topics — with one query, and get ranked results with the exact IDs to query each one.

Send any text: a ticker, a company or coin name, a person, an account, or a topic. Each result says what it is in `kind`. Assets carry the `asset_id` and `asset_class` pair the asset endpoints take. Subjects carry a `subject_id` for /sentiment, /mindshare, and the other subject-aware endpoints. You never need to know in advance whether your text names an asset. An exact ticker match always comes first, and assets otherwise rank ahead of people, accounts, and topics, so a broad word can fill the results with assets; send `kind=subject` to see only people, accounts, and topics. Use /assets or /subjects to browse or to look up a single ID.

## cURL Example

```bash
curl --get \
  --url 'https://nebula-api.hiddensystems.ai/api/v1/public/search' \
  --data-urlencode 'query=NVIDIA' \
  --header 'X-API-Key: YOUR_API_KEY'
```

## Path Parameters

No path parameters for this endpoint.

## Query Parameters

- `query` (string, required): Text to search for: a ticker, a company or coin name, a person, an account, or a topic.
- `kind` (string, optional, allowed: asset, subject): Restricts results to assets (stocks, commodities, indices, and crypto) or subjects (people, accounts, and topics). Omit it to search both.
- `limit` (integer, optional, default: 10): Maximum results returned.

## Response

OK

- `query` (string, required): The free-text string that was resolved, echoed back.
- `results` (array<object>, required): Ranked results, best first.
- `results[].asset_class` (string): The asset's class: equity (stocks and ETFs), commodity, index, or crypto. Send it with asset_id on every asset-scoped request.
- `results[].asset_id` (string): Canonical public asset identifier. Equity identifiers are ticker symbols; crypto identifiers are canonical crypto IDs.
- `results[].kind` (string, required, enum: asset, subject): What the result is: asset (query it with asset_id and asset_class) or subject (query it with subject_id).
- `results[].matched_alias` (string): The name or alias that matched the query, so you can show why a search landed where it did.
- `results[].name` (string, required): Human-readable name.
- `results[].subject_id` (string): Canonical identifier for a non-asset person, account, or topic.
- `results[].symbol` (string): Display ticker or market symbol.

Media type: `application/json`

## JSON Response

```json
{
  "query": "nvidia",
  "results": [
    {
      "asset_class": "equity",
      "asset_id": "NVDA",
      "kind": "asset",
      "name": "NVIDIA Corporation",
      "symbol": "NVDA"
    },
    {
      "kind": "subject",
      "matched_alias": "NVIDIA AI",
      "name": "NVIDIA AI",
      "subject_id": "handle:nvidiaai"
    },
    {
      "kind": "subject",
      "matched_alias": "NVIDIA Vera Rubin NVL72",
      "name": "NVIDIA Vera Rubin NVL72",
      "subject_id": "text:nvidia vera rubin nvl72"
    }
  ]
}
```
