bitbucket_get_file_content
Retrieve file content and metadata from a Bitbucket repository given workspace, repo, file path, and branch. Optionally limit to top N lines.
Instructions
Get the content of a specific file from a repository.
Args: workspace: Workspace name or project key. repository: Repository name. file_path: Path to the file in the repository. branch: Branch name to read from (default: main).
Returns: JSON string containing file content and metadata.
Raises: ValueError: If the Bitbucket client is not configured or available.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| branch | No | Branch name to read from | main |
| sample | No | Read top N lines of a file. -1 for full file content. | |
| file_path | Yes | Path to the file in the repository | |
| workspace | Yes | Workspace name (Cloud) or project key (Server/DC) | |
| repository | Yes | Repository name |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |