GitHub · Capability

GitHub v3 REST API — Search

GitHub v3 REST API — Search. 7 operations. Lead operation: GitHub Search Code. Self-contained Naftiko capability covering one Github business surface.

Run with Naftiko GithubSearch

What You Can Do

GET
Searchcode — GitHub Search Code
/v1/search/code
GET
Searchcommits — GitHub Search Commits
/v1/search/commits
GET
Searchissuesandpullrequests — GitHub Search Issues and Pull Requests
/v1/search/issues
GET
Searchlabels — GitHub Search Labels
/v1/search/labels
GET
Searchrepos — GitHub Search Repositories
/v1/search/repositories
GET
Searchtopics — GitHub Search Topics
/v1/search/topics
GET
Searchusers — GitHub Search Users
/v1/search/users

MCP Tools

github-search-code

GitHub Search Code

read-only idempotent
github-search-commits

GitHub Search Commits

read-only idempotent
github-search-issues-and-pull

GitHub Search Issues and Pull Requests

read-only idempotent
github-search-labels

GitHub Search Labels

read-only idempotent
github-search-repositories

GitHub Search Repositories

read-only idempotent
github-search-topics

GitHub Search Topics

read-only idempotent
github-search-users

GitHub Search Users

read-only idempotent

Capability Spec

github-search.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: GitHub v3 REST API — Search
  description: 'GitHub v3 REST API — Search. 7 operations. Lead operation: GitHub Search Code. Self-contained Naftiko capability
    covering one Github business surface.'
  tags:
  - Github
  - Search
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    GITHUB_API_KEY: GITHUB_API_KEY
capability:
  consumes:
  - type: http
    namespace: github-search
    baseUri: ''
    description: GitHub v3 REST API — Search business capability. Self-contained, no shared references.
    resources:
    - name: search-code
      path: /search/code
      operations:
      - name: searchcode
        method: GET
        description: GitHub Search Code
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: q
          in: query
          type: string
          description: The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search
            to specific areas of GitHub Enterprise Server. The REST
          required: true
        - name: sort
          in: query
          type: string
          description: Sorts the results of your query. Can only be `indexed`, which indicates how recently a file has been
            indexed by the GitHub Enterprise Server search infrastructu
        - name: order
          in: query
          type: string
          description: Determines whether the first search result returned is the highest number of matches (`desc`) or lowest
            number of matches (`asc`). This parameter is ignored unl
    - name: search-commits
      path: /search/commits
      operations:
      - name: searchcommits
        method: GET
        description: GitHub Search Commits
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: q
          in: query
          type: string
          description: The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search
            to specific areas of GitHub Enterprise Server. The REST
          required: true
        - name: sort
          in: query
          type: string
          description: 'Sorts the results of your query by `author-date` or `committer-date`. Default: [best match](https://docs.github.com/[email protected]/rest/search/search#ran'
    - name: search-issues
      path: /search/issues
      operations:
      - name: searchissuesandpullrequests
        method: GET
        description: GitHub Search Issues and Pull Requests
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: q
          in: query
          type: string
          description: The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search
            to specific areas of GitHub Enterprise Server. The REST
          required: true
        - name: sort
          in: query
          type: string
          description: Sorts the results of your query by the number of `comments`, `reactions`, `reactions-+1`, `reactions--1`,
            `reactions-smile`, `reactions-thinking_face`, `reactio
    - name: search-labels
      path: /search/labels
      operations:
      - name: searchlabels
        method: GET
        description: GitHub Search Labels
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: repository_id
          in: query
          type: integer
          description: The id of the repository.
          required: true
        - name: q
          in: query
          type: string
          description: The search keywords. This endpoint does not accept qualifiers in the query. To learn more about the
            format of the query, see [Constructing a search query](https
          required: true
        - name: sort
          in: query
          type: string
          description: 'Sorts the results of your query by when the label was `created` or `updated`. Default: [best match](https://docs.github.com/[email protected]/rest/search/se'
    - name: search-repositories
      path: /search/repositories
      operations:
      - name: searchrepos
        method: GET
        description: GitHub Search Repositories
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: q
          in: query
          type: string
          description: The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search
            to specific areas of GitHub Enterprise Server. The REST
          required: true
        - name: sort
          in: query
          type: string
          description: 'Sorts the results of your query by number of `stars`, `forks`, or `help-wanted-issues` or how recently
            the items were `updated`. Default: [best match](https://d'
    - name: search-topics
      path: /search/topics
      operations:
      - name: searchtopics
        method: GET
        description: GitHub Search Topics
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: q
          in: query
          type: string
          description: The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search
            to specific areas of GitHub Enterprise Server. The REST
          required: true
    - name: search-users
      path: /search/users
      operations:
      - name: searchusers
        method: GET
        description: GitHub Search Users
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: q
          in: query
          type: string
          description: The query contains one or more search keywords and qualifiers. Qualifiers allow you to limit your search
            to specific areas of GitHub Enterprise Server. The REST
          required: true
        - name: sort
          in: query
          type: string
          description: 'Sorts the results of your query by number of `followers` or `repositories`, or when the person `joined`
            GitHub Enterprise Server. Default: [best match](https://'
  exposes:
  - type: rest
    namespace: github-search-rest
    port: 8080
    description: REST adapter for GitHub v3 REST API — Search. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/search/code
      name: search-code
      description: REST surface for search-code.
      operations:
      - method: GET
        name: searchcode
        description: GitHub Search Code
        call: github-search.searchcode
        with:
          q: rest.q
          sort: rest.sort
          order: rest.order
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/search/commits
      name: search-commits
      description: REST surface for search-commits.
      operations:
      - method: GET
        name: searchcommits
        description: GitHub Search Commits
        call: github-search.searchcommits
        with:
          q: rest.q
          sort: rest.sort
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/search/issues
      name: search-issues
      description: REST surface for search-issues.
      operations:
      - method: GET
        name: searchissuesandpullrequests
        description: GitHub Search Issues and Pull Requests
        call: github-search.searchissuesandpullrequests
        with:
          q: rest.q
          sort: rest.sort
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/search/labels
      name: search-labels
      description: REST surface for search-labels.
      operations:
      - method: GET
        name: searchlabels
        description: GitHub Search Labels
        call: github-search.searchlabels
        with:
          repository_id: rest.repository_id
          q: rest.q
          sort: rest.sort
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/search/repositories
      name: search-repositories
      description: REST surface for search-repositories.
      operations:
      - method: GET
        name: searchrepos
        description: GitHub Search Repositories
        call: github-search.searchrepos
        with:
          q: rest.q
          sort: rest.sort
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/search/topics
      name: search-topics
      description: REST surface for search-topics.
      operations:
      - method: GET
        name: searchtopics
        description: GitHub Search Topics
        call: github-search.searchtopics
        with:
          q: rest.q
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/search/users
      name: search-users
      description: REST surface for search-users.
      operations:
      - method: GET
        name: searchusers
        description: GitHub Search Users
        call: github-search.searchusers
        with:
          q: rest.q
          sort: rest.sort
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: github-search-mcp
    port: 9090
    transport: http
    description: MCP adapter for GitHub v3 REST API — Search. One tool per consumed operation, routed inline through this
      capability's consumes block.
    tools:
    - name: github-search-code
      description: GitHub Search Code
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: github-search.searchcode
      with:
        q: tools.q
        sort: tools.sort
        order: tools.order
      outputParameters:
      - type: object
        mapping: $.
    - name: github-search-commits
      description: GitHub Search Commits
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: github-search.searchcommits
      with:
        q: tools.q
        sort: tools.sort
      outputParameters:
      - type: object
        mapping: $.
    - name: github-search-issues-and-pull
      description: GitHub Search Issues and Pull Requests
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: github-search.searchissuesandpullrequests
      with:
        q: tools.q
        sort: tools.sort
      outputParameters:
      - type: object
        mapping: $.
    - name: github-search-labels
      description: GitHub Search Labels
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: github-search.searchlabels
      with:
        repository_id: tools.repository_id
        q: tools.q
        sort: tools.sort
      outputParameters:
      - type: object
        mapping: $.
    - name: github-search-repositories
      description: GitHub Search Repositories
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: github-search.searchrepos
      with:
        q: tools.q
        sort: tools.sort
      outputParameters:
      - type: object
        mapping: $.
    - name: github-search-topics
      description: GitHub Search Topics
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: github-search.searchtopics
      with:
        q: tools.q
      outputParameters:
      - type: object
        mapping: $.
    - name: github-search-users
      description: GitHub Search Users
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: github-search.searchusers
      with:
        q: tools.q
        sort: tools.sort
      outputParameters:
      - type: object
        mapping: $.