# Discussions

Forum threads and community conversations in one search.

```text
"sources": ["discussions"]
```

The `discussions` source searches conversations: forum threads, public chat communities and technology discussion threads, together. It is a shortcut for asking what people say about something without choosing where they say it.

## Good for

- Questions that start with "what do people think of" or "has anyone tried".
- Finding where a subject is discussed, before you narrow to `hn` or `communities`.
- Recommendations and comparisons from people who use the thing.

## Not the place for

- Facts you will quote as authoritative. A thread is a lead, not a source of record.
- Sorting by date: most results here carry no date. For dated threads, ask `hn` or `social`.

## What a result carries

Every result has the same fields whatever the source; the [Search reference](https://millionshort.com/docs/search/parameters#a-result) lists them. What differs is which of them are filled in:

| Field | In this source |
|---|---|
| `published_date` | Usually `null`. |
| `page_type`, `topic` | Set on forum results, `null` on the others. |
| `popularity` | Set for forum sites; `unknown` for the rest. |
| `signals` (with `explain`) | Set for forum results only. |
| `extra` | `kind` says what the result is: `forum`, `chat` or `tech-news`. A `chat` result adds `members` and `online`; a `tech-news` result may add `points`, `comments` and `links_to`. |

The `extra` keys are what this source returns today. Treat every one of them as optional: read it if it is there.

## Example queries

- `home espresso setup`
- `learning piano as an adult`
- `mechanical keyboard switches`

Ten conversations, with the kind of each:

```bash
curl https://api.millionshort.com/v1/search \
  -H "Authorization: Bearer $MILLIONSHORT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "home espresso setup",
    "sources": ["discussions"],
    "num_results": 10
  }'
```

```python
import os

from millionshort import MillionShort

client = MillionShort(api_key=os.environ["MILLIONSHORT_API_KEY"])

r = client.search(
    "home espresso setup",
    sources=["discussions"],
    num_results=10,
)
for hit in r.results:
    print(hit["extra"].get("kind"), hit["site"], hit["title"])
print(r.usage.credits, "credit(s)")
```

```ts
import { MillionShort } from 'millionshort';

const client = new MillionShort({ apiKey: process.env.MILLIONSHORT_API_KEY });

const r = await client.search('home espresso setup', {
  sources: ['discussions'],
  numResults: 10,
});
for (const hit of r.results) {
  console.log(hit.extra.kind, hit.site, hit.title);
}
console.log(r.usage?.credits, 'credit(s)');
```

The same call as a tool of the MCP server:

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "search",
    "arguments": {
      "query": "home espresso setup",
      "sources": [
        "discussions"
      ],
      "num_results": 10
    }
  }
}
```

## Combine it with

`web` or `smallweb` for the long-form answer the thread points at. One call can ask up to five sources and returns one merged list; each result says which source it came from in `source`. See [Mixture of Experts](https://millionshort.com/docs/search/mixture-of-experts).

## Cost and limits

A search of this source costs 1 credit, like every source, and covers the first 10 results of the call. It is one of the **heavy** sources: each plan has a lower per-minute limit for searches that include it. [Credits and limits](https://millionshort.com/docs/credits-and-limits) has the numbers.

With [Monitor](https://millionshort.com/docs/monitor/parameters), query monitors are not offered on this source; watch a page with a URL monitor instead.
