We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/jliocsar/bitbucket-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
list-pull-request-commits.civet•1.58 kB
{ z } from zod
{ BitbucketToolDeclaration } from ../bitbucket.civet
export listPullRequestCommitsTool := new BitbucketToolDeclaration {
name: "list-pull-request-commits",
config: {
title: "List pull request commits",
description: "List all commits in a pull request. Essential for understanding the changes and history within a PR.",
inputSchema: {
workspace: z.string().describe("The Bitbucket workspace name or UUID where the repository is located"),
repository: z.string().describe("The repository name or UUID containing the pull request"),
pullRequestId: z.number().describe("The unique identifier of the pull request to list commits from"),
fields: z.string().optional().describe("Comma-separated list of fields to include in the response"),
page: z.string().optional().describe("Page token for pagination"),
pagelen: z.number().optional().describe("Number of items to return per page (default: 10, max: 100)"),
q: z.string().optional().describe("Query string to filter commits"),
sort: z.string().optional().describe("Field to sort results by (e.g., \"date\", \"-date\")"),
},
},
run({ workspace, repository, pullRequestId, fields, page, pagelen, q, sort }) {
// Get PR commits
commits := @bitbucket.repositories
|> .listPullRequestCommits {
repo_slug: repository,
workspace,
pull_request_id: pullRequestId,
fields,
page,
pagelen,
q,
sort
}
|> await
|> .data
// Return the commits
commits
}
}