# glim.sh GitHub Search

> glim.sh GitHub Search is a paid API for AI agents from glim.sh, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-13, last successful call 2026-08-07).

Search GitHub repositories or conversations using GitHub search syntax and get paginated live results

## Facts

- Endpoint: POST https://glim.sh/api/v1/github/search
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Last successful call: 2026-08-07
- Success rate: 100% of calls made through Zero
- Rating: 4.7 / 5 from 1 review
- Activations on Zero: 1
- Tags: x402
- Canonical page: https://www.zero.xyz/c/glim-sh-github-search-8f1bc43a
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_m9dmBdblyEpYqe_33KYwu

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability glim-sh-github-search-8f1bc43a -d '<json body>'
```

Example prompt: Search GitHub for repos about 'x402 payment protocol' — give me the top 10 results from page 1 of the repos kind.

## When to prefer this

Use this endpoint when you need live, real-time GitHub search results without managing your own GitHub API keys or OAuth setup. Prefer this over direct GitHub API calls when you want simple pay-per-call pricing, need to search both repos and conversations in one interface, or are operating in an agent context where managing secrets is impractical.

## Known failure modes

- Invalid 'kind' value (not 'repos' or 'conversations') returns a 400 error
- Query string using unsupported GitHub syntax may return empty results
- per_page exceeding 30 is out of range and may be clamped or rejected
- Payment not included or insufficient funds returns a 402 Payment Required
- Rate limits on the underlying GitHub API may cause temporary 503 responses
- Empty query returns unpredictable or broad results

## How this service works

Search GitHub repositories, conversations, and discussions

## Output

A JSON object containing a list of matching GitHub repositories or conversations (each with full_name and other metadata), a total_count of matches, and a has_more boolean for pagination.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "kind": {
   "enum": [
    "repos",
    "conversations",
    "code",
    "discussions"
   ],
   "type": "string",
   "description": "What to search: 'repos', 'conversations' (issues+PRs), 'discussions' (GitHub Discussions - a separate index from issues/PRs), or 'code' (literal/regex/symbol search across 2.8M+ public GitHub repos). Optional - inferred from the query: is:answered/category: implies discussions, is:/label:/author: implies conversations, path:/symbol:/content://regex/ implies code, stars:/topic:/in:readme implies repos, otherwise repos. type:code / type:repos / type:discussions in the query also works. A conversations search that matches nothing is retried as discussions, so an answer that lives in Discussions is not silently missed."
  },
  "page": {
   "type": "integer",
   "default": 1,
   "maximum": 10,
   "minimum": 1,
   "description": "Page number"
  },
  "repo": {
   "type": "string",
   "description": "Scope to one repository. Accepts 'owner/name', a github.com URL, or a partial 'owner/' (code). Works with any kind; setting it with kind=repos routes the search to conversations, since repo-name search can't scope to one repo. Equivalent to a repo: qualifier in the query (if both are given they must match)."
  },
  "query": {
   "type": "string",
   "maxLength": 1000,
   "minLength": 1,
   "description": "Search query in full GitHub search syntax: qualifiers (repo:owner/name, org:/user:, language:, path: with globs, symbol:, content:, is:, stars:>N, label:, sort:stars), boolean AND/OR/NOT with parentheses, \"exact strings\", and /regex/. kind=repos: minimal distinctive keywords - the project/library name (GOOD: 'rtk', 'react query'; BAD: 'rtk rust token killer' - every extra word must ALL match and buries the real repo; filter with qualifiers, not prose). kind=code: ONE literal code pattern as it appears in files ('useState('), an \"exact string\", a /regex/, or symbol:name for definitions; narrow with repo:/language:/path:, not extra words. kind=conversations: keywords plus filters (is:issue, label:bug). kind=discussions: keywords plus repo:/org:/author:/is:answered/category: - a separate GitHub index from issues/PRs, so a thread that lives in Discussions is invisible to kind=conversations (and vice versa). category: matches the repo's own category name (Ideas, Q&A) and needs a repo: scope; sort: does not apply. Caution: sort: REPLACES relevance ranking (sort:reactions = most-popular thread mentio
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "results": [
   {
    "full_name": "x402-foundation/x402"
   }
  ],
  "has_more": true,
  "total_count": 42
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/glim-sh-github-search-8f1bc43a/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from glim.sh](https://www.zero.xyz/host/glim.sh/llms.txt)
