UNPKG

@mseep/mcp-server-atlassian-bitbucket

Version:

Node.js/TypeScript MCP server for Atlassian Bitbucket. Enables AI systems (LLMs) to interact with workspaces, repositories, and pull requests via tools (list, get, comment, search). Connects AI directly to version control workflows through the standard MC

68 lines (67 loc) 3.79 kB
import { ControllerResponse } from '../types/common.types.js'; import { ListPullRequestsOptions, ListPullRequestCommentsOptions, CreatePullRequestCommentOptions, CreatePullRequestOptions, GetPullRequestOptions } from './atlassian.pullrequests.types.js'; /** * List Bitbucket pull requests with optional filtering * @param options - Options for listing pull requests * @param options.workspaceSlug - The workspace slug containing the repository * @param options.repoSlug - The repository slug to list pull requests from * @param options.state - Pull request state filter * @param options.limit - Maximum number of pull requests to return * @param options.cursor - Pagination cursor for retrieving the next set of results * @returns Promise with formatted pull request list content and pagination information */ declare function list(options: ListPullRequestsOptions): Promise<ControllerResponse>; /** * Get details of a specific Bitbucket pull request, including code changes * @param options - Options for retrieving the pull request * @param options.workspaceSlug - The workspace slug containing the repository * @param options.repoSlug - The repository slug containing the pull request * @param options.prId - The pull request ID * @param options.fullDiff - Optional flag to retrieve the full diff * @returns Promise with formatted pull request details content, including code changes * @throws Error if pull request retrieval fails */ declare function get(options: GetPullRequestOptions): Promise<ControllerResponse>; /** * List comments on a specific Bitbucket pull request * @param options - Options for listing pull request comments * @param options.workspaceSlug - The workspace slug containing the repository * @param options.repoSlug - The repository slug containing the pull request * @param options.prId - The pull request ID * @param options.limit - Maximum number of comments to return * @param options.cursor - Pagination cursor for retrieving the next set of results * @returns Promise with formatted pull request comments content and pagination information */ declare function listComments(options: ListPullRequestCommentsOptions): Promise<ControllerResponse>; /** * Create a comment on a specific Bitbucket pull request * @param options - Options for creating a comment on a pull request * @param options.workspaceSlug - The workspace slug containing the repository * @param options.repoSlug - The repository slug containing the pull request * @param options.prId - The pull request ID * @param options.content - The content of the comment * @param options.inline - Optional inline comment location * @returns Promise with the result of adding the comment */ declare function createComment(options: CreatePullRequestCommentOptions): Promise<ControllerResponse>; /** * Create a new pull request * @param options - Options for creating a new pull request * @param options.workspaceSlug - Workspace slug containing the repository * @param options.repoSlug - Repository slug to create the pull request in * @param options.title - Title of the pull request * @param options.sourceBranch - Source branch name * @param options.destinationBranch - Destination branch name (defaults to the repository's main branch) * @param options.description - Optional description for the pull request * @param options.closeSourceBranch - Whether to close the source branch after merge * @returns Promise with formatted pull request details content */ declare function create(options: CreatePullRequestOptions): Promise<ControllerResponse>; declare const _default: { list: typeof list; get: typeof get; listComments: typeof listComments; createComment: typeof createComment; create: typeof create; }; export default _default;