@@ -164,19 +164,22 @@ For a more detailed guide, checkout [the docs](https://docs.sourcebot.dev/docs/f
164164
165165### search_code
166166
167- Fetches code that matches the provided regex pattern in `query` .
167+ Searches for code that matches the provided search query as a substring by default, or as a regular expression if `useRegex` is true .
168168
169169<details>
170170<summary>Parameters</summary>
171171
172172| Name | Required | Description |
173173|:----------------------|:---------|:----------------------------------------------------------------------------------------------------------------------------------|
174- | `query` | yes | Regex pattern to search for. Escape special characters and spaces with a single backslash (e.g., 'console\.log', 'console\ log'). |
175- | `filterByRepoIds` | no | Restrict search to specific repository IDs (from 'list_repos'). Leave empty to search all. |
176- | `filterByLanguages` | no | Restrict search to specific languages (GitHub linguist format, e.g., Python, JavaScript). |
177- | `caseSensitive` | no | Case sensitive search (default: false). |
178- | `includeCodeSnippets` | no | Include code snippets in results (default: false). |
179- | `maxTokens` | no | Max tokens to return (default: env.DEFAULT_MINIMUM_TOKENS). |
174+ | `query` | yes | The search pattern to match against code contents. Do not escape quotes in your query. |
175+ | `useRegex` | no | Whether to use regular expression matching. When false, substring matching is used (default: false). |
176+ | `filterByRepos` | no | Scope the search to specific repositories. |
177+ | `filterByLanguages` | no | Scope the search to specific languages. |
178+ | `filterByFilepaths` | no | Scope the search to specific filepaths. |
179+ | `caseSensitive` | no | Whether the search should be case sensitive (default: false). |
180+ | `includeCodeSnippets` | no | Whether to include code snippets in the response (default: false). |
181+ | `ref` | no | Commit SHA, branch or tag name to search on. If not provided, defaults to the default branch. |
182+ | `maxTokens` | no | The maximum number of tokens to return (default: 10000). Higher values provide more context but consume more tokens. |
180183</details>
181184
182185
@@ -187,42 +190,47 @@ Lists repositories indexed by Sourcebot with optional filtering and pagination.
187190<details>
188191<summary>Parameters</summary>
189192
190- | Name | Required | Description |
191- |:-------------|:---------|:--------------------------------------------------------------------|
192- | `query` | no | Filter repositories by name (case-insensitive). |
193- | `pageNumber` | no | Page number (1-indexed, default: 1). |
194- | `limit` | no | Number of repositories per page (default: 50). |
193+ | Name | Required | Description |
194+ |:------------|:---------|:--------------------------------------------------------------------------------|
195+ | `query` | no | Filter repositories by name (case-insensitive). |
196+ | `page` | no | Page number for pagination (min 1, default: 1). |
197+ | `perPage` | no | Results per page for pagination (min 1, max 100, default: 30). |
198+ | `sort` | no | Sort repositories by 'name' or 'pushed' (most recent commit). Default: 'name'. |
199+ | `direction` | no | Sort direction: 'asc' or 'desc' (default: 'asc'). |
195200
196201</details>
197202
198- ### get_file_source
203+ ### read_file
199204
200- Fetches the source code for a given file.
205+ Reads the source code for a given file.
201206
202207<details>
203208<summary>Parameters</summary>
204209
205- | Name | Required | Description |
206- |:-------------|:---------|:-----------------------------------------------------------------|
207- | `fileName` | yes | The file to fetch the source code for. |
208- | `repoId` | yes | The Sourcebot repository ID. |
210+ | Name | Required | Description |
211+ |:-------|:---------|:---------------------------------------------------------------------------------------------------------------|
212+ | `repo` | yes | The repository name. |
213+ | `path` | yes | The path to the file. |
214+ | `ref` | no | Commit SHA, branch or tag name to fetch the source code for. If not provided, uses the default branch. |
209215</details>
210216
211- ### search_commits
217+ ### list_commits
212218
213- Searches for commits in a specific repository based on actual commit time .
219+ Get a list of commits for a given repository .
214220
215221<details>
216222<summary>Parameters</summary>
217223
218- | Name | Required | Description |
219- |:-----------|:---------|:-----------------------------------------------------------------------------------------------|
220- | `repoId` | yes | Repository identifier: either numeric database ID (e.g., 123) or full repository name (e.g., "github.com/owner/repo") as returned by `list_repos`. |
221- | `query` | no | Search query to filter commits by message (case-insensitive). |
222- | `since` | no | Show commits after this date (by commit time). Supports ISO 8601 or relative formats. |
223- | `until` | no | Show commits before this date (by commit time). Supports ISO 8601 or relative formats. |
224- | `author` | no | Filter by author name or email (supports partial matches). |
225- | `maxCount` | no | Maximum number of commits to return (default: 50). |
224+ | Name | Required | Description |
225+ |:----------|:---------|:--------------------------------------------------------------------------------------------------------------------------------------|
226+ | `repo` | yes | The name of the repository to list commits for. |
227+ | `query` | no | Search query to filter commits by message content (case-insensitive). |
228+ | `since` | no | Show commits more recent than this date. Supports ISO 8601 (e.g., '2024-01-01') or relative formats (e.g., '30 days ago'). |
229+ | `until` | no | Show commits older than this date. Supports ISO 8601 (e.g., '2024-12-31') or relative formats (e.g., 'yesterday'). |
230+ | `author` | no | Filter commits by author name or email (case-insensitive). |
231+ | `ref` | no | Commit SHA, branch or tag name to list commits of. If not provided, uses the default branch. |
232+ | `page` | no | Page number for pagination (min 1, default: 1). |
233+ | `perPage` | no | Results per page for pagination (min 1, max 100, default: 50). |
226234
227235</details>
228236
0 commit comments