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

# Developer search

> Search READMEs, issues, pull requests, releases and docs with passages you can cite. Filter by repo, language and stars. $1 per 1,000 searches of up to 10.

`POST /v1/search/developer` finds READMEs, issues, pull requests, releases, API operations and docs for a query, each with the passage that matches. It needs an API key.

## Search issues of a repo

Get an API key in the [Quickstart](https://docs.stophy.dev/quickstart). This request looks for issues and pull requests about SQLite transactions in one repo.

```bash cURL theme={null}
curl -X POST https://api.stophy.dev/v1/search/developer \
  -H "Authorization: Bearer $STOPHY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "sqlite transactions",
    "k": 3,
    "types": ["issue", "pull_request"],
    "repos": ["oven-sh/bun"],
    "language": "Rust"
  }'
```

```typescript TypeScript theme={null}
const response = await fetch("https://api.stophy.dev/v1/search/developer", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.STOPHY_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    query: "sqlite transactions",
    k: 3,
    types: ["issue", "pull_request"],
    repos: ["oven-sh/bun"],
    language: "Rust",
  }),
});
const { results } = await response.json();
for (const result of results) {
  console.log(result.type, result.state, result.title, result.url);
}
```

```python Python theme={null}
import os

import requests

response = requests.post(
    "https://api.stophy.dev/v1/search/developer",
    headers={"Authorization": f"Bearer {os.environ['STOPHY_API_KEY']}"},
    json={
        "query": "sqlite transactions",
        "k": 3,
        "types": ["issue", "pull_request"],
        "repos": ["oven-sh/bun"],
        "language": "Rust",
    },
)
for result in response.json()["results"]:
    print(result["type"], result["state"], result["title"], result["url"])
```

## Read the response

`results` holds the matches, best first. This real response is cut to one of the three results and to the start of its passage.

```json theme={null}
{
  "success": true,
  "partial": false,
  "results": [
    {
      "id": "b564588afcdd8e50",
      "url": "https://github.com/oven-sh/bun/issues/26044",
      "title": "Incorrect example for `bun:sqlite` transaction",
      "passages": [
        {
          "text": "oven-sh/bun issue #26044 · open · labels: docs\n\n## What is the type of issue?\n\n_No response_\n\n## What is the issue?\n\nThe example for sqlite transaction should use spread operator instead of a single a…",
          "citation_url": "https://github.com/oven-sh/bun/issues/26044",
          "truncated": false
        }
      ],
      "type": "issue",
      "repo": "oven-sh/bun",
      "stars": 96579,
      "language": "Rust",
      "date": "2026-01-13T21:42:02Z",
      "state": "open"
    }
  ],
  "repos": [
    {
      "repo": "oven-sh/bun",
      "canonicalRepo": "oven-sh/bun",
      "indexed": true,
      "types": { "issue": 26600, "pullRequest": 5780, "readme": 15 }
    }
  ],
  "costUsd": 0.001,
  "requestId": "51a442c6-cfe4-46dc-9a35-ddbe5d674bf0"
}
```

Each result has an `id`, the `url` and `title` of the item, its `type`, and the `repo`, `stars`, `language`, `date` and `state` (such as `open` or `closed`) when it has them, or `null`. `passages` holds the text that matched, and each passage names the `citation_url` to cite. `repos` has one entry for each repo you sent, and `indexed` says whether Stophy holds items of that repo.

## Search one repo without passages

Send `passages` as `false` when you only need the items. This request searches the READMEs, issues, pull requests and releases of one repo.

```bash theme={null}
curl -X POST https://api.stophy.dev/v1/search/developer \
  -H "Authorization: Bearer $STOPHY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "memory leak",
    "k": 2,
    "types": ["readme", "issue", "pull_request", "release"],
    "repos": ["oven-sh/bun"],
    "passages": false
  }'
```

This real response is cut to its first result. `passages` is an empty list, and `repos` says how much of the repo Stophy holds.

```json theme={null}
{
  "success": true,
  "partial": false,
  "results": [
    {
      "id": "ac7ce69f8173e1c1",
      "url": "https://github.com/oven-sh/bun/issues/28343",
      "title": "Tracking: JavaScriptCore GC Memory Leaks - Upstream WebKit Issue",
      "passages": [],
      "type": "issue",
      "repo": "oven-sh/bun",
      "stars": 96579,
      "language": "Rust",
      "date": "2026-03-24T09:17:51Z",
      "state": "closed"
    }
  ],
  "repos": [
    {
      "repo": "oven-sh/bun",
      "canonicalRepo": "oven-sh/bun",
      "indexed": true,
      "types": { "issue": 26600, "pullRequest": 5780, "readme": 15 }
    }
  ],
  "costUsd": 0.001,
  "requestId": "b15883f1-bfc9-4329-8c57-a1dec908b12e"
}
```

## Send a GET request

`GET /v1/search/developer` takes the same fields as query parameters, with a list as comma-separated values, such as `?query=memory+leak&types=issue,pull_request&repos=oven-sh/bun`.

## Options

| Field | Type | Default | Effect |
| - | - | - | - |
| `query` | `string` | none | What to search for. Required. |
| `k` | `number` | 10 | How many results, 1 to 100. |
| `types` | `array of string` | all types | Keep only these types: `readme`, `issue`, `pull_request`, `release`, `operation` or `doc`. |
| `repos` | `array of string` | none | Search only these repos, up to 5, as `owner/name`. Each one gets an entry in `repos`. |
| `language` | `string` | none | Keep only items of repos written in this language, such as `Rust`. |
| `min_stars` | `number` | none | Keep only items of repos with at least this many stars. |
| `max_stars` | `number` | none | Keep only items of repos with at most this many stars. |
| `passages` | `boolean` | `true` | Send `false` to get results without their passages. `passages` is then an empty list. |

## Limits and errors

* Without an API key, the call returns `401 apiKeyRequired`.
* `min_stars` above `max_stars` returns `400 invalidRequest` with `min_stars: must not be greater than max_stars.`
* `operation` and `doc` results have no stars, so they are left out when you send `min_stars` or `max_stars`.
* A `repos` entry that is not `owner/name`, or more than 5 repos, returns `400 invalidRequest`. A repo Stophy holds nothing of comes back with `indexed: false`.
* `partial` is `false` on every answer.

## Price

$1 per 1,000 searches of up to 10 results: $0.001 for each 10 results. A search with no results costs nothing. See [Pricing](https://docs.stophy.dev/account/pricing.md).

## Related

* [Papers](https://docs.stophy.dev/search/papers.md) searches research papers.
* [Sources](https://docs.stophy.dev/search/sources.md) searches the web, news, images and videos.
* [Search overview](https://docs.stophy.dev/search/overview) lists every search field.


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